Pre-IPL ROM Stage disassembled code

Pre-IPLROM Stage
Dumped from Motherboard: TA-081
ROM:BFC00000  # =============== S U B R O U T I N E =======================================
ROM:BFC00000
ROM:BFC00000
ROM:BFC00000 __start:                                 # CODE XREF: ROM:BFC00200j
ROM:BFC00000                 ctc0    $v0, $4
ROM:BFC00004                 lw      $v0, 0xBC100000  # check Number of NMI that occured
ROM:BFC00004                                          # from System Config Register
ROM:BFC0000C                 bnez    $v0, loc_BFC00064
ROM:BFC00010                 nop
ROM:BFC00014                 ctc0    $zero, $9
ROM:BFC00018                 jal     pspClearDcache
ROM:BFC0001C                 nop
ROM:BFC00020                 jal     pspClearIcache
ROM:BFC00024                 nop
ROM:BFC00028                 lui     $a0, 0xA001
ROM:BFC0002C                 la      $a1, RAM_PAYLOAD
ROM:BFC00034                 li      $a2, 0xAF8
ROM:BFC00038
ROM:BFC00038 loc_BFC00038:                            # CODE XREF: __start+48j
ROM:BFC00038                 lw      $t0, 0($a1)      # this loop copy code
ROM:BFC00038                                          # from[0xbfc00280]
ROM:BFC00038                                          # to[0xa0010000]size[0xAF8]
ROM:BFC0003C                 addiu   $a1, 4
ROM:BFC00040                 sw      $t0, 0($a0)
ROM:BFC00044                 addiu   $a2, -4
ROM:BFC00048                 bgtz    $a2, loc_BFC00038
ROM:BFC0004C                 addiu   $a0, 4
ROM:BFC00050                 li      $sp, 0x80013FF0  # setup temp stack point
ROM:BFC00058                 lui     $t9, 0x8001
ROM:BFC0005C                 jr      $t9              # jump to RAM c entry[0x80010000]
ROM:BFC00060                 sync
ROM:BFC00064  # ---------------------------------------------------------------------------
ROM:BFC00064
ROM:BFC00064 loc_BFC00064:                            # CODE XREF: __start+Cj
ROM:BFC00064                 cfc0    $v0, $9
ROM:BFC00068                 beqz    $v0, loc_BFC00078
ROM:BFC0006C                 nop
ROM:BFC00070                 jr      $v0
ROM:BFC00074                 nop
ROM:BFC00078  # ---------------------------------------------------------------------------
ROM:BFC00078
ROM:BFC00078 loc_BFC00078:                            # CODE XREF: __start+68j
ROM:BFC00078                 cfc0    $v0, $4
ROM:BFC0007C                 mfc0    $k1, SR          # Clear status reg bit22
ROM:BFC0007C                                          # "Bootstrap Exception Vector"
ROM:BFC00080                 li      $k0, 0xFFBFFFFF
ROM:BFC00088                 and     $k1, $k0
ROM:BFC0008C                 mtc0    $k1, SR
ROM:BFC00090                 mfc0    $k0, $25         # Return ISR
ROM:BFC00094                 jr      $k0
ROM:BFC00098                 nop
ROM:BFC00098  # End of function __start
ROM:BFC00098
ROM:BFC00098  # ---------------------------------------------------------------------------
ROM:BFC0009C Filling:        .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC0009C                 .byte 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
ROM:BFC00200  # ---------------------------------------------------------------------------
ROM:BFC00200                 b       __start          # General exception Vector Address when BEV==1
ROM:BFC00200  # ---------------------------------------------------------------------------
ROM:BFC00204                 .word 0
ROM:BFC00208
ROM:BFC00208  # =============== S U B R O U T I N E =======================================
ROM:BFC00208
ROM:BFC00208
ROM:BFC00208 pspClearIcache:                          # CODE XREF: __start+20p
ROM:BFC00208                 mfc0    $t0, Config      # Configuration register
ROM:BFC0020C                 li      $t1, 0x1000      # cache size is given by 2^(12+IC)
ROM:BFC0020C                                          # 0x1000 = 2^12
ROM:BFC00210                 ext     $t0, 9, 3
ROM:BFC00214                 sllv    $t1, $t0         # calc cache size
ROM:BFC00218                 mtc0    $zero, TagLo     # Cache Tag register
ROM:BFC0021C                 mtc0    $zero, TagHi     # Cache Tag register
ROM:BFC00220                 move    $t0, $zero
ROM:BFC00224
ROM:BFC00224 loc_BFC00224:                            # CODE XREF: pspClearIcache+28j
ROM:BFC00224                 cache   1, 0($t0)        # Index Invalidate (primary data cache)
ROM:BFC00228                 cache   3, 0($t0)        # Index Invalidate (secondary data cache)
ROM:BFC0022C                 addiu   $t0, 0x40
ROM:BFC00230                 bne     $t0, $t1, loc_BFC00224
ROM:BFC00234                 nop
ROM:BFC00238                 jr      $ra
ROM:BFC0023C                 nop
ROM:BFC0023C  # End of function pspClearIcache
ROM:BFC0023C
ROM:BFC00240
ROM:BFC00240  # =============== S U B R O U T I N E =======================================
ROM:BFC00240
ROM:BFC00240
ROM:BFC00240 pspClearDcache:                          # CODE XREF: __start+18p
ROM:BFC00240                 mfc0    $t0, Config      # Configuration register
ROM:BFC00244                 li      $t1, 0x1000
ROM:BFC00248                 ext     $t0, 6, 3
ROM:BFC0024C                 sllv    $t1, $t0
ROM:BFC00250                 mtc0    $zero, TagLo     # Cache Tag register
ROM:BFC00254                 mtc0    $zero, TagHi     # Cache Tag register
ROM:BFC00258                 move    $t0, $zero
ROM:BFC0025C
ROM:BFC0025C loc_BFC0025C:                            # CODE XREF: pspClearDcache+28j
ROM:BFC0025C                 cache   0x11, 0($t0)     # Hit Invalidate (primary data cache)
ROM:BFC00260                 cache   0x13, 0($t0)     # Hit Invalidate (secondary data cache)
ROM:BFC00264                 addiu   $t0, 0x40
ROM:BFC00268                 bne     $t0, $t1, loc_BFC0025C
ROM:BFC0026C                 nop
ROM:BFC00270                 jr      $ra
ROM:BFC00270  # End of function pspClearDcache
ROM:BFC00270
ROM:BFC00270  # ---------------------------------------------------------------------------
ROM:BFC00274                 .word 0
ROM:BFC00278                 .word 0
ROM:BFC0027C                 .word 0
ROM:BFC00280 RAM_PAYLOAD:    .word 0x3C048001, 0x24840A80, 0xC0041AC, 0, 0x3C08BC10 # DATA XREF: __start+2Co
ROM:BFC00280                 .word 0x8D090068, 0x94C02, 0x11200005, 0, 0x8D090078, 0x35290800
… …
ROM:BFC00FB0 aCopyrightC2004:.ascii "Copyright (C) 2004 Sony Computer Entertainment Inc. All right"
ROM:BFC00FB0                 .ascii "s reserved."<0>
ROM:BFC00FF9                 .byte    0
ROM:BFC00FFA                 .byte    0
ROM:BFC00FFB                 .byte    0
ROM:BFC00FFC                 .word 0x20040420
ROM:BFC00FFC
ROM:BFC00FFC                  # end

좋은 웹페이지 즐겨찾기