MCPcopy Create free account
hub / github.com/PCSX2/pcsx2 / dmaSIF0

Function dmaSIF0

pcsx2/Sif0.cpp:343–370  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

341}
342
343__fi void dmaSIF0()
344{
345 SIF_LOG("dmaSIF0 %s", sif0ch.cmqt_to_str().c_str());
346
347 if (sif0.fifo.readPos != sif0.fifo.writePos)
348 {
349 SIF_LOG("warning, sif0.fifoReadPos != sif0.fifoWritePos");
350 }
351
352 //if(sif0ch.chcr.MOD == CHAIN_MODE && sif0ch.qwc > 0) DevCon.Warning(L"SIF0 QWC on Chain CHCR " + sif0ch.chcr.desc());
353 psHu32(SBUS_F240) |= 0x2000;
354 sif0.ee.busy = true;
355
356 // Okay, this here is needed currently (r3644).
357 // FFX battles in the thunder plains map die otherwise, Phantasy Star 4 as well
358 // These 2 games could be made playable again by increasing the time the EE or the IOP run,
359 // showing that this is very timing sensible.
360 // Doing this DMA unfortunately brings back an old warning in Legend of Legaia though, but it still works.
361
362 //Updated 23/08/2011: The hangs are caused by the EE suspending SIF1 DMA and restarting it when in the middle
363 //of processing a "REFE" tag, so the hangs can be solved by forcing the ee.end to be false
364 // (as it should always be at the beginning of a DMA). using "if iop is busy" flags breaks Tom Clancy Rainbow Six.
365 // Legend of Legaia doesn't throw a warning either :)
366 sif0.ee.end = false;
367 CPU_SET_DMASTALL(DMAC_SIF0, false);
368 SIF0Dma();
369
370}

Callers

nothing calls this directly

Calls 4

CPU_SET_DMASTALLFunction · 0.85
SIF0DmaFunction · 0.85
cmqt_to_strMethod · 0.80
c_strMethod · 0.45

Tested by

no test coverage detected