diff options
| author | John "Lameguy" Wilbert Villamor <lameguy64@gmail.com> | 2022-09-26 16:49:56 +0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-09-26 16:49:56 +0800 |
| commit | c4a2533d21dfd05cde841ea48c67b05e0e6a853f (patch) | |
| tree | c7ef61653b157b69fb0956709366996ddbc4ecfa /libpsn00b/psxapi/sys.s | |
| parent | a8b404b3400c3ebd8e0b923dcaefcc49ea563e36 (diff) | |
| parent | 86f0064afb8200e60dd80827535cac30d0eab028 (diff) | |
| download | psn00bsdk-c4a2533d21dfd05cde841ea48c67b05e0e6a853f.tar.gz | |
Merge pull request #55 from spicyjpeg/psxmdec
Full MDEC support, C library refactors, cleanups and bugfixes (v0.20)
Diffstat (limited to 'libpsn00b/psxapi/sys.s')
| -rw-r--r-- | libpsn00b/psxapi/sys.s | 114 |
1 files changed, 91 insertions, 23 deletions
diff --git a/libpsn00b/psxapi/sys.s b/libpsn00b/psxapi/sys.s index e54bd98..e2505e1 100644 --- a/libpsn00b/psxapi/sys.s +++ b/libpsn00b/psxapi/sys.s @@ -6,7 +6,7 @@ .set noreorder -## A0 table functions (7) +## A0 table functions (8) .section .text.b_setjmp .global b_setjmp @@ -48,6 +48,14 @@ FlushCache: jr $t2 li $t1, 0x44 +.section .text.SetConf +.global SetConf +.type SetConf, @function +SetConf: + li $t2, 0xa0 + jr $t2 + li $t1, 0x9c + .section .text._boot .global _boot .type _boot, @function @@ -64,7 +72,7 @@ GetSystemInfo: jr $t2 li $t1, 0xb4 -## B0 table functions (19) +## B0 table functions (27) .section .text._kernel_malloc .global _kernel_malloc @@ -122,6 +130,14 @@ ResetRCnt: jr $t2 li $t1, 0x06 +.section .text.DeliverEvent +.global DeliverEvent +.type DeliverEvent, @function +DeliverEvent: + li $t2, 0xb0 + jr $t2 + li $t1, 0x07 + .section .text.OpenEvent .global OpenEvent .type OpenEvent, @function @@ -130,6 +146,30 @@ OpenEvent: jr $t2 li $t1, 0x08 +.section .text.CloseEvent +.global CloseEvent +.type CloseEvent, @function +CloseEvent: + li $t2, 0xb0 + jr $t2 + li $t1, 0x09 + +.section .text.WaitEvent +.global WaitEvent +.type WaitEvent, @function +WaitEvent: + li $t2, 0xb0 + jr $t2 + li $t1, 0x0a + +.section .text.TestEvent +.global TestEvent +.type TestEvent, @function +TestEvent: + li $t2, 0xb0 + jr $t2 + li $t1, 0x0b + .section .text.EnableEvent .global EnableEvent .type EnableEvent, @function @@ -146,6 +186,30 @@ DisableEvent: jr $t2 li $t1, 0x0d +.section .text.OpenTh +.global OpenTh +.type OpenTh, @function +OpenTh: + li $t2, 0xb0 + jr $t2 + li $t1, 0x0e + +.section .text.CloseTh +.global CloseTh +.type CloseTh, @function +CloseTh: + li $t2, 0xb0 + jr $t2 + li $t1, 0x0f + +.section .text.ChangeTh +.global ChangeTh +.type ChangeTh, @function +ChangeTh: + li $t2, 0xb0 + jr $t2 + li $t1, 0x10 + .section .text.InitPAD .global InitPAD .type InitPAD, @function @@ -194,6 +258,14 @@ SetCustomExitFromException: jr $t2 li $t1, 0x19 +.section .text.UnDeliverEvent +.global UnDeliverEvent +.type UnDeliverEvent, @function +UnDeliverEvent: + li $t2, 0xb0 + jr $t2 + li $t1, 0x20 + .section .text.GetC0Table .global GetC0Table .type GetC0Table, @function @@ -218,7 +290,7 @@ ChangeClearPAD: jr $t2 li $t1, 0x5b -## C0 table functions (3) +## C0 table functions (5) .section .text.SysEnqIntRP .global SysEnqIntRP @@ -236,6 +308,22 @@ SysDeqIntRP: jr $t2 li $t1, 0x03 +.section .text.InstallExceptionHandlers +.global InstallExceptionHandlers +.type InstallExceptionHandlers, @function +InstallExceptionHandlers: + li $t2, 0xc0 + jr $t2 + li $t1, 0x07 + +.section .text.SysInitMemory +.global SysInitMemory +.type SysInitMemory, @function +SysInitMemory: + li $t2, 0xc0 + jr $t2 + li $t1, 0x08 + .section .text.ChangeClearRCnt .global ChangeClearRCnt .type ChangeClearRCnt, @function @@ -244,23 +332,3 @@ ChangeClearRCnt: jr $t2 li $t1, 0x0a -## Syscalls (2) - -.section .text.EnterCriticalSection -.global EnterCriticalSection -.type EnterCriticalSection, @function -EnterCriticalSection: - li $a0, 0x01 - syscall 0 - jr $ra - nop - -.section .text.ExitCriticalSection -.global ExitCriticalSection -.type ExitCriticalSection, @function -ExitCriticalSection: - li $a0, 0x02 - syscall 0 - jr $ra - nop - |
