aboutsummaryrefslogtreecommitdiff
path: root/libpsn00b/psxapi/_initcd.s
diff options
context:
space:
mode:
authorspicyjpeg <thatspicyjpeg@gmail.com>2023-05-21 17:22:00 +0200
committerspicyjpeg <thatspicyjpeg@gmail.com>2023-05-21 17:22:00 +0200
commit1e058d15e29adc482074d7225b4c1ed34e63568d (patch)
tree7167f01bdb3eb0542895ee14e389225dc0eca37b /libpsn00b/psxapi/_initcd.s
parent513a6e99dd1f9cf5531d55f544478bec72efb910 (diff)
downloadpsn00bsdk-1e058d15e29adc482074d7225b4c1ed34e63568d.tar.gz
More library cleanups and libc fixes
Diffstat (limited to 'libpsn00b/psxapi/_initcd.s')
-rw-r--r--libpsn00b/psxapi/_initcd.s37
1 files changed, 0 insertions, 37 deletions
diff --git a/libpsn00b/psxapi/_initcd.s b/libpsn00b/psxapi/_initcd.s
deleted file mode 100644
index 600d686..0000000
--- a/libpsn00b/psxapi/_initcd.s
+++ /dev/null
@@ -1,37 +0,0 @@
-.section .text
-.set noreorder
-
-.include "hwregs_a.inc"
-
-.global _InitCd
-.type _InitCd, @function
-_InitCd:
- addiu $sp, -8
- sw $ra, 0($sp)
-
- lui $a0, IOBASE # Load IOBASE value
-
- lw $v0, DMA_DPCR($a0) # Get current DMA settings
- nop
- sw $v0, 4($sp) # Save to stack
-
- jal _96_init # Init CD subsystem
- nop
-
- lui $a0, IOBASE # Load IOBASE again
-
- lw $v0, 4($sp) # Get old DMA control settings
- lw $v1, DMA_DPCR($a0) # Get DMA settings by _96_init()
-
- lui $a1, 0xffff # Mask out settings for CD DMA
- ori $a1, 0x0f00
- and $v0, $a1
-
- or $v0, $v1 # Merge and set new DMA settings
- sw $v0, DMA_DPCR($a0)
-
- lw $ra, 0($sp)
- addiu $sp, 8
- jr $ra
- nop
- \ No newline at end of file