X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=Pico%2FMemory.c;h=8632c7a731691c468311c6ccfb81c23e28c4335c;hb=e122fae6f47c4ca4fce5a178d6d2055b3cef6423;hp=48c32a6581b6224cdb7ed89fc5ec077cd7a6919e;hpb=f8ef8ff7100baa0ac0ecfcacb47aea3a9e24bc38;p=picodrive.git diff --git a/Pico/Memory.c b/Pico/Memory.c index 48c32a6..8632c7a 100644 --- a/Pico/Memory.c +++ b/Pico/Memory.c @@ -37,6 +37,8 @@ extern unsigned int ppop; #ifdef IO_STATS void log_io(unsigned int addr, int bits, int rw); +#elif defined(_MSC_VER) +#define log_io #else #define log_io(...) #endif @@ -301,19 +303,8 @@ static void OtherWrite8End(u32 a,u32 d,int realsize) #endif elprintf(EL_UIO, "strange w%i: %06x, %08x @%06x", realsize, a&0xffffff, d, SekPc); - if(a >= 0xA13004 && a < 0xA13040) { - // dumb 12-in-1 or 4-in-1 banking support - int len; - a &= 0x3f; a <<= 16; - len = Pico.romsize - a; - if (len <= 0) return; // invalid/missing bank - if (len > 0x200000) len = 0x200000; // 2 megs - memcpy(Pico.rom, Pico.rom+a, len); // code which does this is in RAM so this is safe. - return; - } - // for games with simple protection devices, discovered by Haze - else if ((a>>22) == 1) + if ((a>>22) == 1) Pico.m.prot_bytes[(a>>2)&1] = (u8)d; }