|
|
| version 1.4, 2003/12/08 00:55:32 | version 1.6, 2003/12/25 19:26:55 |
|---|---|
| Line 6 | Line 6 |
| #include "fmboard.h" | #include "fmboard.h" |
| // 後で調整 | // 後で調整 |
| #if defined(CPU386) | #if defined(CPUCORE_IA32) |
| DWORD cpumem_addrmask = 0xfffff; | DWORD cpumem_addrmask = 0xfffff; |
| #endif | #endif |
| Line 16 DWORD cpumem_addrmask = 0xfffff; | Line 16 DWORD cpumem_addrmask = 0xfffff; |
| static void IOOUTCALL cpuio_of0(UINT port, REG8 dat) { | static void IOOUTCALL cpuio_of0(UINT port, REG8 dat) { |
| CPU_ADRSMASK = 0x0fffff; | CPU_ADRSMASK = 0x0fffff; |
| #if defined(CPU386) | #if defined(CPUCORE_IA32) |
| cpumem_addrmask = 0xfffff; | cpumem_addrmask = 0xfffff; |
| #endif | #endif |
| CPU_RESETREQ = 1; | CPU_RESETREQ = 1; |
| CPU_INTERRUPT(0x02); | // CPU_INTERRUPT(0x02); |
| nevent_forceexit(); | nevent_forceexit(); |
| (void)port; | (void)port; |
| (void)dat; | (void)dat; |
| Line 28 static void IOOUTCALL cpuio_of0(UINT por | Line 28 static void IOOUTCALL cpuio_of0(UINT por |
| static void IOOUTCALL cpuio_of2(UINT port, REG8 dat) { | static void IOOUTCALL cpuio_of2(UINT port, REG8 dat) { |
| CPU_ADRSMASK = 0x1fffff; | CPU_ADRSMASK = 0xffffffff; |
| #if defined(CPU386) | #if defined(CPUCORE_IA32) |
| cpumem_addrmask = 0xffffffff; | cpumem_addrmask = 0xffffffff; |
| #endif | #endif |
| (void)port; | (void)port; |
| Line 54 static REG8 IOINPCALL cpuio_if2(UINT por | Line 54 static REG8 IOINPCALL cpuio_if2(UINT por |
| REG8 ret; | REG8 ret; |
| #if 1 | |
| ret = 0xff; | ret = 0xff; |
| ret -= (REG8)((CPU_ADRSMASK >> 20) & 1); | ret -= (REG8)((CPU_ADRSMASK >> 20) & 1); |
| #else | |
| ret = 0xfe; | |
| if (CPU_ADRSMASK != 0x1fffff) { | |
| ret++; | |
| } | |
| #endif | |
| (void)port; | (void)port; |
| return(ret); | return(ret); |
| } | } |
| #ifdef CPU386 // defineを変えてね | #if defined(CPUCORE_IA32) |
| static void IOOUTCALL cpuio_of6(UINT port, REG8 dat) { | static void IOOUTCALL cpuio_of6(UINT port, REG8 dat) { |
| switch(dat) { | switch(dat) { |
| case 0x02: | case 0x02: |
| CPU_ADRSMASK = 0x1fffff; | CPU_ADRSMASK = 0xffffffff; |
| #if defined(CPU_386) | #if defined(CPUCORE_IA32) |
| cpumem_addrmask = 0xffffffff; | cpumem_addrmask = 0xffffffff; |
| #endif | #endif |
| break; | break; |
| case 0x03: | case 0x03: |
| CPU_ADRSMASK = 0x0fffff; | CPU_ADRSMASK = 0x0fffff; |
| #if defined(CPU_386) | #if defined(CPUCORE_IA32) |
| cpumem_addrmask = 0xfffff; | cpumem_addrmask = 0xfffff; |
| #endif | #endif |
| break; | break; |
| Line 94 static REG8 IOINPCALL cpuio_if6(UINT por | Line 87 static REG8 IOINPCALL cpuio_if6(UINT por |
| REG8 ret; | REG8 ret; |
| ret = 0x00; | ret = 0x00; |
| if (CPU_ADRSMASK != 0x1fffff) { | if (!(CPU_ADRSMASK & (1 << 20))) { |
| ret |= 0x01; | ret |= 0x01; |
| } | } |
| if (nmiio.enable) { | if (nmiio.enable) { |
| Line 108 static REG8 IOINPCALL cpuio_if6(UINT por | Line 101 static REG8 IOINPCALL cpuio_if6(UINT por |
| // ---- I/F | // ---- I/F |
| #ifndef CPU386 // defineを変えてね | #if !defined(CPUCORE_IA32) |
| static const IOOUT cpuioof0[8] = { | static const IOOUT cpuioof0[8] = { |
| cpuio_of0, cpuio_of2, NULL, NULL, | cpuio_of0, cpuio_of2, NULL, NULL, |
| NULL, NULL, NULL, NULL}; | NULL, NULL, NULL, NULL}; |