*/\r
\r
#include "pico_int.h"\r
+#include "memory.h"\r
\r
int line_base_cycles;\r
extern const unsigned char hcounts_32[];\r
// if we have DmaHook, let it handle ROM because of possible DMA delay\r
if (PicoDmaHook && PicoDmaHook(source, len, &pd, &pdend));\r
else if (source<Pico.romsize) { // Rom\r
- pd=(u16 *)(Pico.rom+(source&~1));\r
+ pd=m68k_dma_source(source);\r
pdend=(u16 *)(Pico.rom+Pico.romsize);\r
}\r
- else {\r
+ if (!pd) {\r
elprintf(EL_VDPDMA|EL_ANOMALY, "DmaSlow[%i] %06x->%04x: invalid src", Pico.video.type, source, a);\r
return;\r
}\r