* io/sp OK

* Fixed function prototype

* Made tharo's suggestions
This commit is contained in:
kyleburnette 2021-11-02 14:56:47 -07:00 committed by GitHub
parent 4841a4a0bf
commit 9bae8900f0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 1 deletions

View File

@ -1,3 +1,10 @@
#include "global.h" #include "global.h"
#pragma GLOBAL_ASM("asm/non_matchings/boot/sp/__osSpDeviceBusy.s") s32 __osSpDeviceBusy(void) {
register u32 status = HW_REG(SP_STATUS_REG, u32);
if (status & (SP_STATUS_DMA_BUSY | SP_STATUS_DMA_FULL | SP_STATUS_IO_FULL)) {
return true;
}
return false;
}