MCPcopy Create free account
hub / github.com/bfbbdecomp/bfbb / SIEnablePolling

Function SIEnablePolling

src/dolphin/src/si/SIBios.c:452–484  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

450}
451
452u32 SIEnablePolling(u32 poll)
453{
454 BOOL enabled;
455 u32 en;
456
457 if (poll == 0)
458 {
459 return Si.poll;
460 }
461
462 enabled = OSDisableInterrupts();
463
464 poll >>= (31 - 7);
465 en = poll & 0xf0;
466
467 poll &= (en >> 4) | 0x03fffff0;
468
469 poll &= ~0x03ffff00;
470
471 Si.poll &= ~(en >> 4);
472
473 Si.poll |= poll;
474
475 poll = Si.poll;
476
477 SITransferCommands();
478
479 __SIRegs[12] = poll;
480
481 OSRestoreInterrupts(enabled);
482
483 return poll;
484}
485
486u32 SIDisablePolling(u32 poll)
487{

Callers 1

PADEnableFunction · 0.85

Calls 2

OSDisableInterruptsFunction · 0.85
SITransferCommandsFunction · 0.85

Tested by

no test coverage detected