44 #define DEV_SGI_IP30_LENGTH 0x80000 74 if (d->
imask0 & ((int64_t)1<<50)) {
77 fatal(
"IP30 legacy interrupt rewrite: TODO\n");
87 uint64_t idata = 0, odata = 0;
92 switch (relative_addr) {
96 odata = 0x80010000ULL;
126 fatal(
"IP30 legacy interrupt rewrite: TODO\n");
134 fatal(
"IP30 legacy interrupt rewrite: TODO\n");
144 fatal(
"IP30 legacy interrupt rewrite: TODO\n");
171 debug(
"[ sgi_ip30: unimplemented write to address " 172 "0x%x, data=0x%02x ]\n", (
int)relative_addr,
175 debug(
"[ sgi_ip30: unimplemented read from address" 176 " 0x%x ]\n", (
int)relative_addr);
190 uint64_t idata = 0, odata = 0;
194 switch (relative_addr) {
199 case 0x114 + 0x40 * (12 - 8):
200 fatal(
"[ IP30: asdvasdvnb ]\n");
221 debug(
"[ sgi_ip30_2: unimplemented write to " 222 "address 0x%x, data=0x%02x ]\n",
223 (
int)relative_addr, (
int)idata);
225 debug(
"[ sgi_ip30_2: unimplemented read from address " 226 "0x%x ]\n", (
int)relative_addr);
240 uint64_t idata = 0, odata = 0;
244 switch (relative_addr) {
248 debug(
"[ sgi_ip30_3: unimplemented write to " 249 "address 0x%x, data=0x%02x ]\n",
250 (
int)relative_addr, (
int)idata);
258 debug(
"[ sgi_ip30_3: unimplemented write to address " 259 "0x%x, data=0x%02x ]\n", (
int)relative_addr,
285 debug(
"[ sgi_ip30_3: unimplemented write to address " 286 "0x%x, data=0x%02x ]\n", (
int)relative_addr,
289 debug(
"[ sgi_ip30_3: unimplemented read from " 290 "address 0x%x ]\n", (
int)relative_addr);
304 uint64_t idata = 0, odata = 0;
308 switch (relative_addr) {
328 debug(
"[ sgi_ip30_4: unimplemented write to address" 329 " 0x%x, data=0x%02x ]\n",
330 (
int)relative_addr, (
int)idata);
332 debug(
"[ sgi_ip30_4: unimplemented read from address" 333 " 0x%x ]\n", (
int)relative_addr);
347 uint64_t idata = 0, odata = 0;
351 switch (relative_addr) {
363 debug(
"[ sgi_ip30_5: unimplemented write to address " 364 "0x%x, data=0x%02x ]\n", (
int)relative_addr,
367 debug(
"[ sgi_ip30_5: unimplemented read from address " 368 "0x%x ]\n", (
int)relative_addr);
390 0x10000000, 0x10000, dev_sgi_ip30_2_access, (
void *)d,
DM_DEFAULT,
393 0x1f000000, 0x10000, dev_sgi_ip30_3_access, (
void *)d,
DM_DEFAULT,
396 0x1f600000, 0x10000, dev_sgi_ip30_4_access, (
void *)d,
DM_DEFAULT,
399 0x1f6c0000, 0x10000, dev_sgi_ip30_5_access, (
void *)d,
DM_DEFAULT,
403 dev_sgi_ip30_tick, d, 16);
uint64_t memory_readmax64(struct cpu *cpu, unsigned char *buf, int len)
void fatal(const char *fmt,...)
#define CHECK_ALLOCATION(ptr)
void memory_writemax64(struct cpu *cpu, unsigned char *buf, int len, uint64_t data)
#define DEV_SGI_IP30_LENGTH
void memory_device_register(struct memory *mem, const char *, uint64_t baseaddr, uint64_t len, int(*f)(struct cpu *, struct memory *, uint64_t, unsigned char *, size_t, int, void *), void *extra, int flags, unsigned char *dyntrans_data)
void machine_add_tickfunction(struct machine *machine, void(*func)(struct cpu *, void *), void *extra, int clockshift)