.include "macros.inc" .section .text, "ax" # 0x80006A00 - 0x80406260 ; 0x003FF860 .global OSRegisterShutdownFunction OSRegisterShutdownFunction: /* 80022F10 0001ED50 80 AD E4 18 */ lwz r5, ShutdownFunctionQueue@sda21(r13) /* 80022F14 0001ED54 48 00 00 08 */ b lbl_80022F1C .global lbl_80022F18 lbl_80022F18: /* 80022F18 0001ED58 80 A5 00 08 */ lwz r5, 0x8(r5) .global lbl_80022F1C lbl_80022F1C: /* 80022F1C 0001ED5C 2C 05 00 00 */ cmpwi r5, 0x0 /* 80022F20 0001ED60 41 82 00 14 */ beq lbl_80022F34 /* 80022F24 0001ED64 80 85 00 04 */ lwz r4, 0x4(r5) /* 80022F28 0001ED68 80 03 00 04 */ lwz r0, 0x4(r3) /* 80022F2C 0001ED6C 7C 04 00 40 */ cmplw r4, r0 /* 80022F30 0001ED70 40 81 FF E8 */ ble lbl_80022F18 .global lbl_80022F34 lbl_80022F34: /* 80022F34 0001ED74 2C 05 00 00 */ cmpwi r5, 0x0 /* 80022F38 0001ED78 40 82 00 38 */ bne lbl_80022F70 /* 80022F3C 0001ED7C 38 8D E4 18 */ addi r4, r13, ShutdownFunctionQueue@sda21 /* 80022F40 0001ED80 80 84 00 04 */ lwz r4, 0x4(r4) /* 80022F44 0001ED84 2C 04 00 00 */ cmpwi r4, 0x0 /* 80022F48 0001ED88 40 82 00 0C */ bne lbl_80022F54 /* 80022F4C 0001ED8C 90 6D E4 18 */ stw r3, ShutdownFunctionQueue@sda21(r13) /* 80022F50 0001ED90 48 00 00 08 */ b lbl_80022F58 .global lbl_80022F54 lbl_80022F54: /* 80022F54 0001ED94 90 64 00 08 */ stw r3, 0x8(r4) .global lbl_80022F58 lbl_80022F58: /* 80022F58 0001ED98 38 00 00 00 */ li r0, 0x0 /* 80022F5C 0001ED9C 90 83 00 0C */ stw r4, 0xc(r3) /* 80022F60 0001EDA0 38 8D E4 18 */ addi r4, r13, ShutdownFunctionQueue@sda21 /* 80022F64 0001EDA4 90 03 00 08 */ stw r0, 0x8(r3) /* 80022F68 0001EDA8 90 64 00 04 */ stw r3, 0x4(r4) /* 80022F6C 0001EDAC 4E 80 00 20 */ blr .global lbl_80022F70 lbl_80022F70: /* 80022F70 0001EDB0 90 A3 00 08 */ stw r5, 0x8(r3) /* 80022F74 0001EDB4 80 85 00 0C */ lwz r4, 0xc(r5) /* 80022F78 0001EDB8 90 65 00 0C */ stw r3, 0xc(r5) /* 80022F7C 0001EDBC 2C 04 00 00 */ cmpwi r4, 0x0 /* 80022F80 0001EDC0 90 83 00 0C */ stw r4, 0xc(r3) /* 80022F84 0001EDC4 40 82 00 0C */ bne lbl_80022F90 /* 80022F88 0001EDC8 90 6D E4 18 */ stw r3, ShutdownFunctionQueue@sda21(r13) /* 80022F8C 0001EDCC 4E 80 00 20 */ blr .global lbl_80022F90 lbl_80022F90: /* 80022F90 0001EDD0 90 64 00 08 */ stw r3, 0x8(r4) /* 80022F94 0001EDD4 4E 80 00 20 */ blr /* 80022F98 0001EDD8 00 00 00 00 */ .4byte 0x00000000 /* 80022F9C 0001EDDC 00 00 00 00 */ .4byte 0x00000000 .global __OSCallShutdownFunctions __OSCallShutdownFunctions: /* 80022FA0 0001EDE0 94 21 FF E0 */ stwu r1, -0x20(r1) /* 80022FA4 0001EDE4 7C 08 02 A6 */ mflr r0 /* 80022FA8 0001EDE8 90 01 00 24 */ stw r0, 0x24(r1) /* 80022FAC 0001EDEC 93 E1 00 1C */ stw r31, 0x1c(r1) /* 80022FB0 0001EDF0 93 C1 00 18 */ stw r30, 0x18(r1) /* 80022FB4 0001EDF4 3B C0 00 00 */ li r30, 0x0 /* 80022FB8 0001EDF8 93 A1 00 14 */ stw r29, 0x14(r1) /* 80022FBC 0001EDFC 7C 9D 23 78 */ mr r29, r4 /* 80022FC0 0001EE00 93 81 00 10 */ stw r28, 0x10(r1) /* 80022FC4 0001EE04 7C 7C 1B 78 */ mr r28, r3 /* 80022FC8 0001EE08 38 60 00 00 */ li r3, 0x0 /* 80022FCC 0001EE0C 83 ED E4 18 */ lwz r31, ShutdownFunctionQueue@sda21(r13) /* 80022FD0 0001EE10 48 00 00 40 */ b lbl_80023010 .global lbl_80022FD4 lbl_80022FD4: /* 80022FD4 0001EE14 2C 1E 00 00 */ cmpwi r30, 0x0 /* 80022FD8 0001EE18 41 82 00 10 */ beq lbl_80022FE8 /* 80022FDC 0001EE1C 80 1F 00 04 */ lwz r0, 0x4(r31) /* 80022FE0 0001EE20 7C 03 00 40 */ cmplw r3, r0 /* 80022FE4 0001EE24 40 82 00 34 */ bne lbl_80023018 .global lbl_80022FE8 lbl_80022FE8: /* 80022FE8 0001EE28 81 9F 00 00 */ lwz r12, 0x0(r31) /* 80022FEC 0001EE2C 7F 83 E3 78 */ mr r3, r28 /* 80022FF0 0001EE30 7F A4 EB 78 */ mr r4, r29 /* 80022FF4 0001EE34 7D 89 03 A6 */ mtctr r12 /* 80022FF8 0001EE38 4E 80 04 21 */ bctrl /* 80022FFC 0001EE3C 7C 60 00 34 */ cntlzw r0, r3 /* 80023000 0001EE40 80 7F 00 04 */ lwz r3, 0x4(r31) /* 80023004 0001EE44 54 00 D9 7E */ srwi r0, r0, 5 /* 80023008 0001EE48 83 FF 00 08 */ lwz r31, 0x8(r31) /* 8002300C 0001EE4C 7F DE 03 78 */ or r30, r30, r0 .global lbl_80023010 lbl_80023010: /* 80023010 0001EE50 2C 1F 00 00 */ cmpwi r31, 0x0 /* 80023014 0001EE54 40 82 FF C0 */ bne lbl_80022FD4 .global lbl_80023018 lbl_80023018: /* 80023018 0001EE58 48 00 0E 49 */ bl __OSSyncSram /* 8002301C 0001EE5C 7C 60 00 34 */ cntlzw r0, r3 /* 80023020 0001EE60 83 E1 00 1C */ lwz r31, 0x1c(r1) /* 80023024 0001EE64 54 00 D9 7E */ srwi r0, r0, 5 /* 80023028 0001EE68 7F DE 03 78 */ or r30, r30, r0 /* 8002302C 0001EE6C 7F C0 00 34 */ cntlzw r0, r30 /* 80023030 0001EE70 83 C1 00 18 */ lwz r30, 0x18(r1) /* 80023034 0001EE74 83 A1 00 14 */ lwz r29, 0x14(r1) /* 80023038 0001EE78 54 03 D9 7E */ srwi r3, r0, 5 /* 8002303C 0001EE7C 83 81 00 10 */ lwz r28, 0x10(r1) /* 80023040 0001EE80 80 01 00 24 */ lwz r0, 0x24(r1) /* 80023044 0001EE84 7C 08 03 A6 */ mtlr r0 /* 80023048 0001EE88 38 21 00 20 */ addi r1, r1, 0x20 /* 8002304C 0001EE8C 4E 80 00 20 */ blr .global __OSShutdownDevices __OSShutdownDevices: /* 80023050 0001EE90 94 21 FF E0 */ stwu r1, -0x20(r1) /* 80023054 0001EE94 7C 08 02 A6 */ mflr r0 /* 80023058 0001EE98 90 01 00 24 */ stw r0, 0x24(r1) /* 8002305C 0001EE9C 39 61 00 20 */ addi r11, r1, 0x20 /* 80023060 0001EEA0 4B FE 42 DD */ bl lbl_8000733C /* 80023064 0001EEA4 38 03 FF FB */ addi r0, r3, -0x5 /* 80023068 0001EEA8 7C 7F 1B 78 */ mr r31, r3 /* 8002306C 0001EEAC 28 00 00 01 */ cmplwi r0, 0x1 /* 80023070 0001EEB0 40 81 00 0C */ ble lbl_8002307C /* 80023074 0001EEB4 2C 03 00 00 */ cmpwi r3, 0x0 /* 80023078 0001EEB8 40 82 00 0C */ bne lbl_80023084 .global lbl_8002307C lbl_8002307C: /* 8002307C 0001EEBC 3B 60 00 00 */ li r27, 0x0 /* 80023080 0001EEC0 48 00 00 08 */ b lbl_80023088 .global lbl_80023084 lbl_80023084: /* 80023084 0001EEC4 3B 60 00 01 */ li r27, 0x1 .global lbl_80023088 lbl_80023088: /* 80023088 0001EEC8 4B FF 97 D9 */ bl __OSStopAudioSystem /* 8002308C 0001EECC 2C 1B 00 00 */ cmpwi r27, 0x0 /* 80023090 0001EED0 40 82 00 10 */ bne lbl_800230A0 /* 80023094 0001EED4 38 60 00 01 */ li r3, 0x1 /* 80023098 0001EED8 48 03 0C F9 */ bl __PADDisableRecalibration /* 8002309C 0001EEDC 7C 7C 1B 78 */ mr r28, r3 .global lbl_800230A0 lbl_800230A0: /* 800230A0 0001EEE0 83 AD E4 18 */ lwz r29, ShutdownFunctionQueue@sda21(r13) /* 800230A4 0001EEE4 38 60 00 00 */ li r3, 0x0 /* 800230A8 0001EEE8 3B C0 00 00 */ li r30, 0x0 /* 800230AC 0001EEEC 48 00 00 40 */ b lbl_800230EC .global lbl_800230B0 lbl_800230B0: /* 800230B0 0001EEF0 2C 1E 00 00 */ cmpwi r30, 0x0 /* 800230B4 0001EEF4 41 82 00 10 */ beq lbl_800230C4 /* 800230B8 0001EEF8 80 1D 00 04 */ lwz r0, 0x4(r29) /* 800230BC 0001EEFC 7C 03 00 40 */ cmplw r3, r0 /* 800230C0 0001EF00 40 82 00 34 */ bne lbl_800230F4 .global lbl_800230C4 lbl_800230C4: /* 800230C4 0001EF04 81 9D 00 00 */ lwz r12, 0x0(r29) /* 800230C8 0001EF08 7F E4 FB 78 */ mr r4, r31 /* 800230CC 0001EF0C 38 60 00 00 */ li r3, 0x0 /* 800230D0 0001EF10 7D 89 03 A6 */ mtctr r12 /* 800230D4 0001EF14 4E 80 04 21 */ bctrl /* 800230D8 0001EF18 7C 60 00 34 */ cntlzw r0, r3 /* 800230DC 0001EF1C 80 7D 00 04 */ lwz r3, 0x4(r29) /* 800230E0 0001EF20 54 00 D9 7E */ srwi r0, r0, 5 /* 800230E4 0001EF24 83 BD 00 08 */ lwz r29, 0x8(r29) /* 800230E8 0001EF28 7F DE 03 78 */ or r30, r30, r0 .global lbl_800230EC lbl_800230EC: /* 800230EC 0001EF2C 2C 1D 00 00 */ cmpwi r29, 0x0 /* 800230F0 0001EF30 40 82 FF C0 */ bne lbl_800230B0 .global lbl_800230F4 lbl_800230F4: /* 800230F4 0001EF34 48 00 0D 6D */ bl __OSSyncSram /* 800230F8 0001EF38 7C 60 00 34 */ cntlzw r0, r3 /* 800230FC 0001EF3C 54 00 D9 7E */ srwi r0, r0, 5 /* 80023100 0001EF40 7F DE 03 79 */ or. r30, r30, r0 /* 80023104 0001EF44 40 82 FF 9C */ bne lbl_800230A0 .global lbl_80023108 lbl_80023108: /* 80023108 0001EF48 48 00 0D 59 */ bl __OSSyncSram /* 8002310C 0001EF4C 2C 03 00 00 */ cmpwi r3, 0x0 /* 80023110 0001EF50 41 82 FF F8 */ beq lbl_80023108 /* 80023114 0001EF54 4B FF E7 0D */ bl OSDisableInterrupts /* 80023118 0001EF58 83 CD E4 18 */ lwz r30, ShutdownFunctionQueue@sda21(r13) /* 8002311C 0001EF5C 38 60 00 00 */ li r3, 0x0 /* 80023120 0001EF60 3B A0 00 00 */ li r29, 0x0 /* 80023124 0001EF64 48 00 00 40 */ b lbl_80023164 .global lbl_80023128 lbl_80023128: /* 80023128 0001EF68 2C 1D 00 00 */ cmpwi r29, 0x0 /* 8002312C 0001EF6C 41 82 00 10 */ beq lbl_8002313C /* 80023130 0001EF70 80 1E 00 04 */ lwz r0, 0x4(r30) /* 80023134 0001EF74 7C 03 00 40 */ cmplw r3, r0 /* 80023138 0001EF78 40 82 00 34 */ bne lbl_8002316C .global lbl_8002313C lbl_8002313C: /* 8002313C 0001EF7C 81 9E 00 00 */ lwz r12, 0x0(r30) /* 80023140 0001EF80 7F E4 FB 78 */ mr r4, r31 /* 80023144 0001EF84 38 60 00 01 */ li r3, 0x1 /* 80023148 0001EF88 7D 89 03 A6 */ mtctr r12 /* 8002314C 0001EF8C 4E 80 04 21 */ bctrl /* 80023150 0001EF90 7C 60 00 34 */ cntlzw r0, r3 /* 80023154 0001EF94 80 7E 00 04 */ lwz r3, 0x4(r30) /* 80023158 0001EF98 54 00 D9 7E */ srwi r0, r0, 5 /* 8002315C 0001EF9C 83 DE 00 08 */ lwz r30, 0x8(r30) /* 80023160 0001EFA0 7F BD 03 78 */ or r29, r29, r0 .global lbl_80023164 lbl_80023164: /* 80023164 0001EFA4 2C 1E 00 00 */ cmpwi r30, 0x0 /* 80023168 0001EFA8 40 82 FF C0 */ bne lbl_80023128 .global lbl_8002316C lbl_8002316C: /* 8002316C 0001EFAC 48 00 0C F5 */ bl __OSSyncSram /* 80023170 0001EFB0 4B FF 9A 81 */ bl LCDisable /* 80023174 0001EFB4 2C 1B 00 00 */ cmpwi r27, 0x0 /* 80023178 0001EFB8 40 82 00 0C */ bne lbl_80023184 /* 8002317C 0001EFBC 7F 83 E3 78 */ mr r3, r28 /* 80023180 0001EFC0 48 03 0C 11 */ bl __PADDisableRecalibration .global lbl_80023184 lbl_80023184: /* 80023184 0001EFC4 3C 60 80 00 */ lis r3, 0x800000DC@ha /* 80023188 0001EFC8 80 63 00 DC */ lwz r3, 0x800000DC@l(r3) /* 8002318C 0001EFCC 48 00 00 24 */ b lbl_800231B0 .global lbl_80023190 lbl_80023190: /* 80023190 0001EFD0 A0 03 02 C8 */ lhz r0, 0x2c8(r3) /* 80023194 0001EFD4 83 A3 02 FC */ lwz r29, 0x2fc(r3) /* 80023198 0001EFD8 2C 00 00 01 */ cmpwi r0, 0x1 /* 8002319C 0001EFDC 41 82 00 0C */ beq lbl_800231A8 /* 800231A0 0001EFE0 2C 00 00 04 */ cmpwi r0, 0x4 /* 800231A4 0001EFE4 40 82 00 08 */ bne lbl_800231AC .global lbl_800231A8 lbl_800231A8: /* 800231A8 0001EFE8 48 00 1F 09 */ bl OSCancelThread .global lbl_800231AC lbl_800231AC: /* 800231AC 0001EFEC 7F A3 EB 78 */ mr r3, r29 .global lbl_800231B0 lbl_800231B0: /* 800231B0 0001EFF0 2C 03 00 00 */ cmpwi r3, 0x0 /* 800231B4 0001EFF4 40 82 FF DC */ bne lbl_80023190 /* 800231B8 0001EFF8 39 61 00 20 */ addi r11, r1, 0x20 /* 800231BC 0001EFFC 4B FE 41 CD */ bl lbl_80007388 /* 800231C0 0001F000 80 01 00 24 */ lwz r0, 0x24(r1) /* 800231C4 0001F004 7C 08 03 A6 */ mtlr r0 /* 800231C8 0001F008 38 21 00 20 */ addi r1, r1, 0x20 /* 800231CC 0001F00C 4E 80 00 20 */ blr .global OSShutdownSystem OSShutdownSystem: /* 800231D0 0001F010 94 21 FF C0 */ stwu r1, -0x40(r1) /* 800231D4 0001F014 7C 08 02 A6 */ mflr r0 /* 800231D8 0001F018 38 80 00 00 */ li r4, 0x0 /* 800231DC 0001F01C 38 A0 00 02 */ li r5, 0x2 /* 800231E0 0001F020 90 01 00 44 */ stw r0, 0x44(r1) /* 800231E4 0001F024 38 61 00 08 */ addi r3, r1, 0x8 /* 800231E8 0001F028 93 E1 00 3C */ stw r31, 0x3c(r1) /* 800231EC 0001F02C 4B FE 11 65 */ bl memset /* 800231F0 0001F030 48 02 82 41 */ bl SCInit .global lbl_800231F4 lbl_800231F4: /* 800231F4 0001F034 48 02 82 DD */ bl SCCheckStatus /* 800231F8 0001F038 28 03 00 01 */ cmplwi r3, 0x1 /* 800231FC 0001F03C 41 82 FF F8 */ beq lbl_800231F4 /* 80023200 0001F040 38 61 00 08 */ addi r3, r1, 0x8 /* 80023204 0001F044 48 02 9C 1D */ bl SCGetIdleMode /* 80023208 0001F048 48 00 3C 39 */ bl __OSStopPlayRecord /* 8002320C 0001F04C 48 00 34 F5 */ bl __OSUnRegisterStateEvent /* 80023210 0001F050 48 01 BC E1 */ bl __DVDPrepareReset /* 80023214 0001F054 38 61 00 18 */ addi r3, r1, 0x18 /* 80023218 0001F058 48 00 3F 09 */ bl __OSReadStateFlags /* 8002321C 0001F05C 8B E1 00 1E */ lbz r31, 0x1e(r1) /* 80023220 0001F060 48 01 B7 71 */ bl __DVDGetCoverStatus /* 80023224 0001F064 28 03 00 02 */ cmplwi r3, 0x2 /* 80023228 0001F068 41 82 00 0C */ beq lbl_80023234 /* 8002322C 0001F06C 38 60 00 03 */ li r3, 0x3 /* 80023230 0001F070 48 00 00 34 */ b lbl_80023264 .global lbl_80023234 lbl_80023234: /* 80023234 0001F074 28 1F 00 01 */ cmplwi r31, 0x1 /* 80023238 0001F078 40 82 00 28 */ bne lbl_80023260 /* 8002323C 0001F07C 38 61 00 0C */ addi r3, r1, 0xc /* 80023240 0001F080 48 00 0E 81 */ bl __OSGetRTCFlags /* 80023244 0001F084 2C 03 00 00 */ cmpwi r3, 0x0 /* 80023248 0001F088 41 82 00 18 */ beq lbl_80023260 /* 8002324C 0001F08C 80 01 00 0C */ lwz r0, 0xc(r1) /* 80023250 0001F090 2C 00 00 00 */ cmpwi r0, 0x0 /* 80023254 0001F094 40 82 00 0C */ bne lbl_80023260 /* 80023258 0001F098 38 60 00 01 */ li r3, 0x1 /* 8002325C 0001F09C 48 00 00 08 */ b lbl_80023264 .global lbl_80023260 lbl_80023260: /* 80023260 0001F0A0 38 60 00 02 */ li r3, 0x2 .global lbl_80023264 lbl_80023264: /* 80023264 0001F0A4 88 01 00 08 */ lbz r0, 0x8(r1) /* 80023268 0001F0A8 98 61 00 1E */ stb r3, 0x1e(r1) /* 8002326C 0001F0AC 28 00 00 01 */ cmplwi r0, 0x1 /* 80023270 0001F0B0 40 82 00 10 */ bne lbl_80023280 /* 80023274 0001F0B4 38 00 00 05 */ li r0, 0x5 /* 80023278 0001F0B8 98 01 00 1D */ stb r0, 0x1d(r1) /* 8002327C 0001F0BC 48 00 00 0C */ b lbl_80023288 .global lbl_80023280 lbl_80023280: /* 80023280 0001F0C0 38 00 00 01 */ li r0, 0x1 /* 80023284 0001F0C4 98 01 00 1D */ stb r0, 0x1d(r1) .global lbl_80023288 lbl_80023288: /* 80023288 0001F0C8 48 00 0F 59 */ bl __OSClearRTCFlags /* 8002328C 0001F0CC 38 61 00 18 */ addi r3, r1, 0x18 /* 80023290 0001F0D0 48 00 3D A1 */ bl __OSWriteStateFlags /* 80023294 0001F0D4 38 61 00 10 */ addi r3, r1, 0x10 /* 80023298 0001F0D8 4B FF 71 59 */ bl __OSGetIOSRev /* 8002329C 0001F0DC 88 01 00 08 */ lbz r0, 0x8(r1) /* 800232A0 0001F0E0 28 00 00 01 */ cmplwi r0, 0x1 /* 800232A4 0001F0E4 40 82 00 24 */ bne lbl_800232C8 /* 800232A8 0001F0E8 38 00 00 01 */ li r0, 0x1 /* 800232AC 0001F0EC 90 0D E4 14 */ stw r0, __OSIsReturnToIdle@sda21(r13) /* 800232B0 0001F0F0 48 00 14 E1 */ bl OSDisableScheduler /* 800232B4 0001F0F4 38 60 00 05 */ li r3, 0x5 /* 800232B8 0001F0F8 4B FF FD 99 */ bl __OSShutdownDevices /* 800232BC 0001F0FC 48 00 15 15 */ bl OSEnableScheduler /* 800232C0 0001F100 4B FF BA 31 */ bl __OSLaunchMenu /* 800232C4 0001F104 48 00 00 14 */ b lbl_800232D8 .global lbl_800232C8 lbl_800232C8: /* 800232C8 0001F108 48 00 14 C9 */ bl OSDisableScheduler /* 800232CC 0001F10C 38 60 00 02 */ li r3, 0x2 /* 800232D0 0001F110 4B FF FD 81 */ bl __OSShutdownDevices /* 800232D4 0001F114 48 00 32 2D */ bl __OSShutdownToSBY .global lbl_800232D8 lbl_800232D8: /* 800232D8 0001F118 80 01 00 44 */ lwz r0, 0x44(r1) /* 800232DC 0001F11C 83 E1 00 3C */ lwz r31, 0x3c(r1) /* 800232E0 0001F120 7C 08 03 A6 */ mtlr r0 /* 800232E4 0001F124 38 21 00 40 */ addi r1, r1, 0x40 /* 800232E8 0001F128 4E 80 00 20 */ blr /* 800232EC 0001F12C 00 00 00 00 */ .4byte 0x00000000 .global OSRestart OSRestart: /* 800232F0 0001F130 94 21 FF F0 */ stwu r1, -0x10(r1) /* 800232F4 0001F134 7C 08 02 A6 */ mflr r0 /* 800232F8 0001F138 90 01 00 14 */ stw r0, 0x14(r1) /* 800232FC 0001F13C 93 E1 00 0C */ stw r31, 0xc(r1) /* 80023300 0001F140 93 C1 00 08 */ stw r30, 0x8(r1) /* 80023304 0001F144 7C 7E 1B 78 */ mr r30, r3 /* 80023308 0001F148 4B FF 84 79 */ bl OSGetAppType /* 8002330C 0001F14C 7C 7F 1B 78 */ mr r31, r3 /* 80023310 0001F150 48 00 3B 31 */ bl __OSStopPlayRecord /* 80023314 0001F154 48 00 33 ED */ bl __OSUnRegisterStateEvent /* 80023318 0001F158 57 E0 06 3E */ clrlwi r0, r31, 24 /* 8002331C 0001F15C 28 00 00 81 */ cmplwi r0, 0x81 /* 80023320 0001F160 40 82 00 20 */ bne lbl_80023340 /* 80023324 0001F164 48 00 14 6D */ bl OSDisableScheduler /* 80023328 0001F168 38 60 00 04 */ li r3, 0x4 /* 8002332C 0001F16C 4B FF FD 25 */ bl __OSShutdownDevices /* 80023330 0001F170 48 00 14 A1 */ bl OSEnableScheduler /* 80023334 0001F174 7F C3 F3 78 */ mr r3, r30 /* 80023338 0001F178 48 00 4F E9 */ bl __OSRelaunchTitle /* 8002333C 0001F17C 48 00 00 28 */ b lbl_80023364 .global lbl_80023340 lbl_80023340: /* 80023340 0001F180 28 00 00 80 */ cmplwi r0, 0x80 /* 80023344 0001F184 40 82 00 20 */ bne lbl_80023364 /* 80023348 0001F188 48 00 14 49 */ bl OSDisableScheduler /* 8002334C 0001F18C 38 60 00 04 */ li r3, 0x4 /* 80023350 0001F190 4B FF FD 01 */ bl __OSShutdownDevices /* 80023354 0001F194 48 00 14 7D */ bl OSEnableScheduler /* 80023358 0001F198 80 8D E4 10 */ lwz r4, bootThisDol@sda21(r13) /* 8002335C 0001F19C 7F C3 F3 78 */ mr r3, r30 /* 80023360 0001F1A0 4B FF FB 21 */ bl __OSReboot .global lbl_80023364 lbl_80023364: /* 80023364 0001F1A4 48 00 14 2D */ bl OSDisableScheduler /* 80023368 0001F1A8 38 60 00 01 */ li r3, 0x1 /* 8002336C 0001F1AC 4B FF FC E5 */ bl __OSShutdownDevices /* 80023370 0001F1B0 80 0D E3 5C */ lwz r0, __OSInNandBoot@sda21(r13) /* 80023374 0001F1B4 2C 00 00 00 */ cmpwi r0, 0x0 /* 80023378 0001F1B8 40 82 00 10 */ bne lbl_80023388 /* 8002337C 0001F1BC 80 0D E3 CC */ lwz r0, __OSInReboot@sda21(r13) /* 80023380 0001F1C0 2C 00 00 00 */ cmpwi r0, 0x0 /* 80023384 0001F1C4 41 82 00 08 */ beq lbl_8002338C .global lbl_80023388 lbl_80023388: /* 80023388 0001F1C8 48 00 30 59 */ bl __OSInitSTM .global lbl_8002338C lbl_8002338C: /* 8002338C 0001F1CC 48 00 31 F5 */ bl __OSHotReset /* 80023390 0001F1D0 3C 60 80 42 */ lis r3, "@2083"@ha /* 80023394 0001F1D4 3C A0 80 42 */ lis r5, "@2084_80423744"@ha /* 80023398 0001F1D8 38 63 37 38 */ addi r3, r3, "@2083"@l /* 8002339C 0001F1DC 38 80 04 0A */ li r4, 0x40a /* 800233A0 0001F1E0 38 A5 37 44 */ addi r5, r5, "@2084_80423744"@l /* 800233A4 0001F1E4 4C C6 31 82 */ crclr 4*cr1+eq /* 800233A8 0001F1E8 48 16 74 49 */ bl OSPanic /* 800233AC 0001F1EC 80 01 00 14 */ lwz r0, 0x14(r1) /* 800233B0 0001F1F0 83 E1 00 0C */ lwz r31, 0xc(r1) /* 800233B4 0001F1F4 83 C1 00 08 */ lwz r30, 0x8(r1) /* 800233B8 0001F1F8 7C 08 03 A6 */ mtlr r0 /* 800233BC 0001F1FC 38 21 00 10 */ addi r1, r1, 0x10 /* 800233C0 0001F200 4E 80 00 20 */ blr /* 800233C4 0001F204 00 00 00 00 */ .4byte 0x00000000 /* 800233C8 0001F208 00 00 00 00 */ .4byte 0x00000000 /* 800233CC 0001F20C 00 00 00 00 */ .4byte 0x00000000 .global __OSReturnToMenu __OSReturnToMenu: /* 800233D0 0001F210 94 21 FF 70 */ stwu r1, -0x90(r1) /* 800233D4 0001F214 7C 08 02 A6 */ mflr r0 /* 800233D8 0001F218 90 01 00 94 */ stw r0, 0x94(r1) /* 800233DC 0001F21C 93 E1 00 8C */ stw r31, 0x8c(r1) /* 800233E0 0001F220 93 C1 00 88 */ stw r30, 0x88(r1) /* 800233E4 0001F224 3F C0 80 42 */ lis r30, "@2083"@ha /* 800233E8 0001F228 3B DE 37 38 */ addi r30, r30, "@2083"@l /* 800233EC 0001F22C 93 A1 00 84 */ stw r29, 0x84(r1) /* 800233F0 0001F230 7C 7D 1B 78 */ mr r29, r3 /* 800233F4 0001F234 48 00 3A 4D */ bl __OSStopPlayRecord /* 800233F8 0001F238 48 00 33 09 */ bl __OSUnRegisterStateEvent /* 800233FC 0001F23C 48 01 BA F5 */ bl __DVDPrepareReset /* 80023400 0001F240 38 61 00 58 */ addi r3, r1, 0x58 /* 80023404 0001F244 48 00 3D 1D */ bl __OSReadStateFlags /* 80023408 0001F248 8B E1 00 5E */ lbz r31, 0x5e(r1) /* 8002340C 0001F24C 48 01 B5 85 */ bl __DVDGetCoverStatus /* 80023410 0001F250 28 03 00 02 */ cmplwi r3, 0x2 /* 80023414 0001F254 41 82 00 0C */ beq lbl_80023420 /* 80023418 0001F258 38 00 00 03 */ li r0, 0x3 /* 8002341C 0001F25C 48 00 00 34 */ b lbl_80023450 .global lbl_80023420 lbl_80023420: /* 80023420 0001F260 28 1F 00 01 */ cmplwi r31, 0x1 /* 80023424 0001F264 40 82 00 28 */ bne lbl_8002344C /* 80023428 0001F268 38 61 00 08 */ addi r3, r1, 0x8 /* 8002342C 0001F26C 48 00 0C 95 */ bl __OSGetRTCFlags /* 80023430 0001F270 2C 03 00 00 */ cmpwi r3, 0x0 /* 80023434 0001F274 41 82 00 18 */ beq lbl_8002344C /* 80023438 0001F278 80 01 00 08 */ lwz r0, 0x8(r1) /* 8002343C 0001F27C 2C 00 00 00 */ cmpwi r0, 0x0 /* 80023440 0001F280 40 82 00 0C */ bne lbl_8002344C /* 80023444 0001F284 38 00 00 01 */ li r0, 0x1 /* 80023448 0001F288 48 00 00 08 */ b lbl_80023450 .global lbl_8002344C lbl_8002344C: /* 8002344C 0001F28C 38 00 00 02 */ li r0, 0x2 .global lbl_80023450 lbl_80023450: /* 80023450 0001F290 3B E0 00 03 */ li r31, 0x3 /* 80023454 0001F294 98 01 00 5E */ stb r0, 0x5e(r1) /* 80023458 0001F298 9B E1 00 5D */ stb r31, 0x5d(r1) /* 8002345C 0001F29C 9B A1 00 5F */ stb r29, 0x5f(r1) /* 80023460 0001F2A0 48 00 0D 81 */ bl __OSClearRTCFlags /* 80023464 0001F2A4 38 61 00 58 */ addi r3, r1, 0x58 /* 80023468 0001F2A8 48 00 3B C9 */ bl __OSWriteStateFlags /* 8002346C 0001F2AC 3C 60 81 28 */ lis r3, 0x8128 /* 80023470 0001F2B0 4B FF 8F 61 */ bl OSSetMEM1ArenaLo /* 80023474 0001F2B4 3C 60 81 2F */ lis r3, 0x812f /* 80023478 0001F2B8 4B FF 8F 39 */ bl OSSetMEM1ArenaHi /* 8002347C 0001F2BC 48 07 EB A5 */ bl ESP_InitLib /* 80023480 0001F2C0 2C 03 00 00 */ cmpwi r3, 0x0 /* 80023484 0001F2C4 41 82 00 78 */ beq lbl_800234FC /* 80023488 0001F2C8 38 61 00 38 */ addi r3, r1, 0x38 /* 8002348C 0001F2CC 48 00 3C 95 */ bl __OSReadStateFlags /* 80023490 0001F2D0 38 00 00 02 */ li r0, 0x2 /* 80023494 0001F2D4 98 01 00 3E */ stb r0, 0x3e(r1) /* 80023498 0001F2D8 9B E1 00 3D */ stb r31, 0x3d(r1) /* 8002349C 0001F2DC 48 00 0D 45 */ bl __OSClearRTCFlags /* 800234A0 0001F2E0 38 61 00 38 */ addi r3, r1, 0x38 /* 800234A4 0001F2E4 48 00 3B 8D */ bl __OSWriteStateFlags /* 800234A8 0001F2E8 4B FF B8 49 */ bl __OSLaunchMenu /* 800234AC 0001F2EC 48 00 12 E5 */ bl OSDisableScheduler /* 800234B0 0001F2F0 48 00 CB 31 */ bl __VISetRGBModeImm /* 800234B4 0001F2F4 80 0D E3 5C */ lwz r0, __OSInNandBoot@sda21(r13) /* 800234B8 0001F2F8 2C 00 00 00 */ cmpwi r0, 0x0 /* 800234BC 0001F2FC 40 82 00 10 */ bne lbl_800234CC /* 800234C0 0001F300 80 0D E3 CC */ lwz r0, __OSInReboot@sda21(r13) /* 800234C4 0001F304 2C 00 00 00 */ cmpwi r0, 0x0 /* 800234C8 0001F308 41 82 00 08 */ beq lbl_800234D0 .global lbl_800234CC lbl_800234CC: /* 800234CC 0001F30C 48 00 2F 15 */ bl __OSInitSTM .global lbl_800234D0 lbl_800234D0: /* 800234D0 0001F310 48 00 30 B1 */ bl __OSHotReset /* 800234D4 0001F314 38 7E 00 00 */ addi r3, r30, 0x0 /* 800234D8 0001F318 38 BE 00 0C */ addi r5, r30, 0xc /* 800234DC 0001F31C 38 80 04 0A */ li r4, 0x40a /* 800234E0 0001F320 4C C6 31 82 */ crclr 4*cr1+eq /* 800234E4 0001F324 48 16 73 0D */ bl OSPanic /* 800234E8 0001F328 38 7E 00 00 */ addi r3, r30, 0x0 /* 800234EC 0001F32C 38 BE 00 38 */ addi r5, r30, 0x38 /* 800234F0 0001F330 38 80 03 F2 */ li r4, 0x3f2 /* 800234F4 0001F334 4C C6 31 82 */ crclr 4*cr1+eq /* 800234F8 0001F338 48 16 72 F9 */ bl OSPanic .global lbl_800234FC lbl_800234FC: /* 800234FC 0001F33C 38 60 00 E0 */ li r3, 0xe0 /* 80023500 0001F340 38 80 00 20 */ li r4, 0x20 /* 80023504 0001F344 4B FF 8E ED */ bl OSAllocFromMEM1ArenaLo /* 80023508 0001F348 2C 03 00 00 */ cmpwi r3, 0x0 /* 8002350C 0001F34C 7C 7F 1B 78 */ mr r31, r3 /* 80023510 0001F350 40 82 00 7C */ bne lbl_8002358C /* 80023514 0001F354 38 61 00 18 */ addi r3, r1, 0x18 /* 80023518 0001F358 48 00 3C 09 */ bl __OSReadStateFlags /* 8002351C 0001F35C 38 60 00 02 */ li r3, 0x2 /* 80023520 0001F360 38 00 00 03 */ li r0, 0x3 /* 80023524 0001F364 98 61 00 1E */ stb r3, 0x1e(r1) /* 80023528 0001F368 98 01 00 1D */ stb r0, 0x1d(r1) /* 8002352C 0001F36C 48 00 0C B5 */ bl __OSClearRTCFlags /* 80023530 0001F370 38 61 00 18 */ addi r3, r1, 0x18 /* 80023534 0001F374 48 00 3A FD */ bl __OSWriteStateFlags /* 80023538 0001F378 4B FF B7 B9 */ bl __OSLaunchMenu /* 8002353C 0001F37C 48 00 12 55 */ bl OSDisableScheduler /* 80023540 0001F380 48 00 CA A1 */ bl __VISetRGBModeImm /* 80023544 0001F384 80 0D E3 5C */ lwz r0, __OSInNandBoot@sda21(r13) /* 80023548 0001F388 2C 00 00 00 */ cmpwi r0, 0x0 /* 8002354C 0001F38C 40 82 00 10 */ bne lbl_8002355C /* 80023550 0001F390 80 0D E3 CC */ lwz r0, __OSInReboot@sda21(r13) /* 80023554 0001F394 2C 00 00 00 */ cmpwi r0, 0x0 /* 80023558 0001F398 41 82 00 08 */ beq lbl_80023560 .global lbl_8002355C lbl_8002355C: /* 8002355C 0001F39C 48 00 2E 85 */ bl __OSInitSTM .global lbl_80023560 lbl_80023560: /* 80023560 0001F3A0 48 00 30 21 */ bl __OSHotReset /* 80023564 0001F3A4 38 7E 00 00 */ addi r3, r30, 0x0 /* 80023568 0001F3A8 38 BE 00 0C */ addi r5, r30, 0xc /* 8002356C 0001F3AC 38 80 04 0A */ li r4, 0x40a /* 80023570 0001F3B0 4C C6 31 82 */ crclr 4*cr1+eq /* 80023574 0001F3B4 48 16 72 7D */ bl OSPanic /* 80023578 0001F3B8 38 7E 00 00 */ addi r3, r30, 0x0 /* 8002357C 0001F3BC 38 BE 00 38 */ addi r5, r30, 0x38 /* 80023580 0001F3C0 38 80 03 F2 */ li r4, 0x3f2 /* 80023584 0001F3C4 4C C6 31 82 */ crclr 4*cr1+eq /* 80023588 0001F3C8 48 16 72 69 */ bl OSPanic .global lbl_8002358C lbl_8002358C: /* 8002358C 0001F3CC 7F E3 FB 78 */ mr r3, r31 /* 80023590 0001F3D0 38 80 00 00 */ li r4, 0x0 /* 80023594 0001F3D4 38 A0 00 E0 */ li r5, 0xe0 /* 80023598 0001F3D8 4B FE 0D B9 */ bl memset /* 8002359C 0001F3DC 7F E4 FB 78 */ mr r4, r31 /* 800235A0 0001F3E0 38 60 00 00 */ li r3, 0x0 /* 800235A4 0001F3E4 48 07 EC ED */ bl ESP_DiGetTicketView /* 800235A8 0001F3E8 2C 03 00 00 */ cmpwi r3, 0x0 /* 800235AC 0001F3EC 40 82 00 40 */ bne lbl_800235EC /* 800235B0 0001F3F0 48 00 44 51 */ bl OSPlayTimeIsLimited /* 800235B4 0001F3F4 2C 03 00 00 */ cmpwi r3, 0x0 /* 800235B8 0001F3F8 41 82 00 34 */ beq lbl_800235EC /* 800235BC 0001F3FC 38 60 00 00 */ li r3, 0x0 /* 800235C0 0001F400 38 00 FF FF */ li r0, -0x1 /* 800235C4 0001F404 90 61 00 10 */ stw r3, 0x10(r1) /* 800235C8 0001F408 7F E3 FB 78 */ mr r3, r31 /* 800235CC 0001F40C 38 81 00 10 */ addi r4, r1, 0x10 /* 800235D0 0001F410 38 A1 00 0C */ addi r5, r1, 0xc /* 800235D4 0001F414 90 01 00 0C */ stw r0, 0xc(r1) /* 800235D8 0001F418 48 00 48 D9 */ bl __OSGetPlayTime /* 800235DC 0001F41C 80 01 00 0C */ lwz r0, 0xc(r1) /* 800235E0 0001F420 2C 00 00 00 */ cmpwi r0, 0x0 /* 800235E4 0001F424 40 82 00 08 */ bne lbl_800235EC /* 800235E8 0001F428 48 00 47 19 */ bl __OSWriteExpiredFlagIfSet .global lbl_800235EC lbl_800235EC: /* 800235EC 0001F42C 48 00 11 A5 */ bl OSDisableScheduler /* 800235F0 0001F430 38 60 00 05 */ li r3, 0x5 /* 800235F4 0001F434 4B FF FA 5D */ bl __OSShutdownDevices /* 800235F8 0001F438 48 00 11 D9 */ bl OSEnableScheduler /* 800235FC 0001F43C 4B FF B6 F5 */ bl __OSLaunchMenu /* 80023600 0001F440 48 00 11 91 */ bl OSDisableScheduler /* 80023604 0001F444 48 00 C9 DD */ bl __VISetRGBModeImm /* 80023608 0001F448 80 0D E3 5C */ lwz r0, __OSInNandBoot@sda21(r13) /* 8002360C 0001F44C 2C 00 00 00 */ cmpwi r0, 0x0 /* 80023610 0001F450 40 82 00 10 */ bne lbl_80023620 /* 80023614 0001F454 80 0D E3 CC */ lwz r0, __OSInReboot@sda21(r13) /* 80023618 0001F458 2C 00 00 00 */ cmpwi r0, 0x0 /* 8002361C 0001F45C 41 82 00 08 */ beq lbl_80023624 .global lbl_80023620 lbl_80023620: /* 80023620 0001F460 48 00 2D C1 */ bl __OSInitSTM .global lbl_80023624 lbl_80023624: /* 80023624 0001F464 48 00 2F 5D */ bl __OSHotReset /* 80023628 0001F468 38 7E 00 00 */ addi r3, r30, 0x0 /* 8002362C 0001F46C 38 BE 00 0C */ addi r5, r30, 0xc /* 80023630 0001F470 38 80 04 0A */ li r4, 0x40a /* 80023634 0001F474 4C C6 31 82 */ crclr 4*cr1+eq /* 80023638 0001F478 48 16 71 B9 */ bl OSPanic /* 8002363C 0001F47C 80 01 00 94 */ lwz r0, 0x94(r1) /* 80023640 0001F480 83 E1 00 8C */ lwz r31, 0x8c(r1) /* 80023644 0001F484 83 C1 00 88 */ lwz r30, 0x88(r1) /* 80023648 0001F488 83 A1 00 84 */ lwz r29, 0x84(r1) /* 8002364C 0001F48C 7C 08 03 A6 */ mtlr r0 /* 80023650 0001F490 38 21 00 90 */ addi r1, r1, 0x90 /* 80023654 0001F494 4E 80 00 20 */ blr /* 80023658 0001F498 00 00 00 00 */ .4byte 0x00000000 /* 8002365C 0001F49C 00 00 00 00 */ .4byte 0x00000000 .global OSReturnToMenu OSReturnToMenu: /* 80023660 0001F4A0 94 21 FF F0 */ stwu r1, -0x10(r1) /* 80023664 0001F4A4 7C 08 02 A6 */ mflr r0 /* 80023668 0001F4A8 38 60 00 00 */ li r3, 0x0 /* 8002366C 0001F4AC 90 01 00 14 */ stw r0, 0x14(r1) /* 80023670 0001F4B0 4B FF FD 61 */ bl __OSReturnToMenu /* 80023674 0001F4B4 3C 60 80 42 */ lis r3, "@2083"@ha /* 80023678 0001F4B8 3C A0 80 42 */ lis r5, "@2131"@ha /* 8002367C 0001F4BC 38 63 37 38 */ addi r3, r3, "@2083"@l /* 80023680 0001F4C0 38 80 03 7F */ li r4, 0x37f /* 80023684 0001F4C4 38 A5 37 A4 */ addi r5, r5, "@2131"@l /* 80023688 0001F4C8 4C C6 31 82 */ crclr 4*cr1+eq /* 8002368C 0001F4CC 48 16 71 65 */ bl OSPanic /* 80023690 0001F4D0 80 01 00 14 */ lwz r0, 0x14(r1) /* 80023694 0001F4D4 7C 08 03 A6 */ mtlr r0 /* 80023698 0001F4D8 38 21 00 10 */ addi r1, r1, 0x10 /* 8002369C 0001F4DC 4E 80 00 20 */ blr .global OSReturnToDataManager OSReturnToDataManager: /* 800236A0 0001F4E0 94 21 FF F0 */ stwu r1, -0x10(r1) /* 800236A4 0001F4E4 7C 08 02 A6 */ mflr r0 /* 800236A8 0001F4E8 38 60 00 01 */ li r3, 0x1 /* 800236AC 0001F4EC 90 01 00 14 */ stw r0, 0x14(r1) /* 800236B0 0001F4F0 4B FF FD 21 */ bl __OSReturnToMenu /* 800236B4 0001F4F4 3C 60 80 42 */ lis r3, "@2083"@ha /* 800236B8 0001F4F8 3C A0 80 42 */ lis r5, "@2133"@ha /* 800236BC 0001F4FC 38 63 37 38 */ addi r3, r3, "@2083"@l /* 800236C0 0001F500 38 80 03 91 */ li r4, 0x391 /* 800236C4 0001F504 38 A5 37 D4 */ addi r5, r5, "@2133"@l /* 800236C8 0001F508 4C C6 31 82 */ crclr 4*cr1+eq /* 800236CC 0001F50C 48 16 71 25 */ bl OSPanic /* 800236D0 0001F510 80 01 00 14 */ lwz r0, 0x14(r1) /* 800236D4 0001F514 7C 08 03 A6 */ mtlr r0 /* 800236D8 0001F518 38 21 00 10 */ addi r1, r1, 0x10 /* 800236DC 0001F51C 4E 80 00 20 */ blr .global __OSReturnToMenuForError __OSReturnToMenuForError: /* 800236E0 0001F520 94 21 FF D0 */ stwu r1, -0x30(r1) /* 800236E4 0001F524 7C 08 02 A6 */ mflr r0 /* 800236E8 0001F528 90 01 00 34 */ stw r0, 0x34(r1) /* 800236EC 0001F52C 38 61 00 08 */ addi r3, r1, 0x8 /* 800236F0 0001F530 93 E1 00 2C */ stw r31, 0x2c(r1) /* 800236F4 0001F534 3F E0 80 42 */ lis r31, "@2083"@ha /* 800236F8 0001F538 3B FF 37 38 */ addi r31, r31, "@2083"@l /* 800236FC 0001F53C 48 00 3A 25 */ bl __OSReadStateFlags /* 80023700 0001F540 38 60 00 02 */ li r3, 0x2 /* 80023704 0001F544 38 00 00 03 */ li r0, 0x3 /* 80023708 0001F548 98 61 00 0E */ stb r3, 0xe(r1) /* 8002370C 0001F54C 98 01 00 0D */ stb r0, 0xd(r1) /* 80023710 0001F550 48 00 0A D1 */ bl __OSClearRTCFlags /* 80023714 0001F554 38 61 00 08 */ addi r3, r1, 0x8 /* 80023718 0001F558 48 00 39 19 */ bl __OSWriteStateFlags /* 8002371C 0001F55C 4B FF B5 D5 */ bl __OSLaunchMenu /* 80023720 0001F560 48 00 10 71 */ bl OSDisableScheduler /* 80023724 0001F564 48 00 C8 BD */ bl __VISetRGBModeImm /* 80023728 0001F568 80 0D E3 5C */ lwz r0, __OSInNandBoot@sda21(r13) /* 8002372C 0001F56C 2C 00 00 00 */ cmpwi r0, 0x0 /* 80023730 0001F570 40 82 00 10 */ bne lbl_80023740 /* 80023734 0001F574 80 0D E3 CC */ lwz r0, __OSInReboot@sda21(r13) /* 80023738 0001F578 2C 00 00 00 */ cmpwi r0, 0x0 /* 8002373C 0001F57C 41 82 00 08 */ beq lbl_80023744 .global lbl_80023740 lbl_80023740: /* 80023740 0001F580 48 00 2C A1 */ bl __OSInitSTM .global lbl_80023744 lbl_80023744: /* 80023744 0001F584 48 00 2E 3D */ bl __OSHotReset /* 80023748 0001F588 38 7F 00 00 */ addi r3, r31, 0x0 /* 8002374C 0001F58C 38 BF 00 0C */ addi r5, r31, 0xc /* 80023750 0001F590 38 80 04 0A */ li r4, 0x40a /* 80023754 0001F594 4C C6 31 82 */ crclr 4*cr1+eq /* 80023758 0001F598 48 16 70 99 */ bl OSPanic /* 8002375C 0001F59C 38 7F 00 00 */ addi r3, r31, 0x0 /* 80023760 0001F5A0 38 BF 00 38 */ addi r5, r31, 0x38 /* 80023764 0001F5A4 38 80 03 F2 */ li r4, 0x3f2 /* 80023768 0001F5A8 4C C6 31 82 */ crclr 4*cr1+eq /* 8002376C 0001F5AC 48 16 70 85 */ bl OSPanic /* 80023770 0001F5B0 80 01 00 34 */ lwz r0, 0x34(r1) /* 80023774 0001F5B4 83 E1 00 2C */ lwz r31, 0x2c(r1) /* 80023778 0001F5B8 7C 08 03 A6 */ mtlr r0 /* 8002377C 0001F5BC 38 21 00 30 */ addi r1, r1, 0x30 /* 80023780 0001F5C0 4E 80 00 20 */ blr /* 80023784 0001F5C4 00 00 00 00 */ .4byte 0x00000000 /* 80023788 0001F5C8 00 00 00 00 */ .4byte 0x00000000 /* 8002378C 0001F5CC 00 00 00 00 */ .4byte 0x00000000 .global __OSHotResetForError __OSHotResetForError: /* 80023790 0001F5D0 94 21 FF F0 */ stwu r1, -0x10(r1) /* 80023794 0001F5D4 7C 08 02 A6 */ mflr r0 /* 80023798 0001F5D8 90 01 00 14 */ stw r0, 0x14(r1) /* 8002379C 0001F5DC 80 0D E3 5C */ lwz r0, __OSInNandBoot@sda21(r13) /* 800237A0 0001F5E0 2C 00 00 00 */ cmpwi r0, 0x0 /* 800237A4 0001F5E4 40 82 00 10 */ bne lbl_800237B4 /* 800237A8 0001F5E8 80 0D E3 CC */ lwz r0, __OSInReboot@sda21(r13) /* 800237AC 0001F5EC 2C 00 00 00 */ cmpwi r0, 0x0 /* 800237B0 0001F5F0 41 82 00 08 */ beq lbl_800237B8 .global lbl_800237B4 lbl_800237B4: /* 800237B4 0001F5F4 48 00 2C 2D */ bl __OSInitSTM .global lbl_800237B8 lbl_800237B8: /* 800237B8 0001F5F8 48 00 2D C9 */ bl __OSHotReset /* 800237BC 0001F5FC 3C 60 80 42 */ lis r3, "@2083"@ha /* 800237C0 0001F600 3C A0 80 42 */ lis r5, "@2084_80423744"@ha /* 800237C4 0001F604 38 63 37 38 */ addi r3, r3, "@2083"@l /* 800237C8 0001F608 38 80 04 0A */ li r4, 0x40a /* 800237CC 0001F60C 38 A5 37 44 */ addi r5, r5, "@2084_80423744"@l /* 800237D0 0001F610 4C C6 31 82 */ crclr 4*cr1+eq /* 800237D4 0001F614 48 16 70 1D */ bl OSPanic /* 800237D8 0001F618 80 01 00 14 */ lwz r0, 0x14(r1) /* 800237DC 0001F61C 7C 08 03 A6 */ mtlr r0 /* 800237E0 0001F620 38 21 00 10 */ addi r1, r1, 0x10 /* 800237E4 0001F624 4E 80 00 20 */ blr /* 800237E8 0001F628 00 00 00 00 */ .4byte 0x00000000 /* 800237EC 0001F62C 00 00 00 00 */ .4byte 0x00000000 .global OSGetResetCode OSGetResetCode: /* 800237F0 0001F630 3C 60 80 4A */ lis r3, __OSRebootParams@ha /* 800237F4 0001F634 80 03 90 A0 */ lwz r0, __OSRebootParams@l(r3) /* 800237F8 0001F638 2C 00 00 00 */ cmpwi r0, 0x0 /* 800237FC 0001F63C 41 82 00 14 */ beq lbl_80023810 /* 80023800 0001F640 38 63 90 A0 */ addi r3, r3, -0x6f60 /* 80023804 0001F644 80 03 00 04 */ lwz r0, 0x4(r3) /* 80023808 0001F648 64 03 80 00 */ oris r3, r0, 0x8000 /* 8002380C 0001F64C 4E 80 00 20 */ blr .global lbl_80023810 lbl_80023810: /* 80023810 0001F650 3C 60 CC 00 */ lis r3, 0xCC003024@ha /* 80023814 0001F654 80 03 30 24 */ lwz r0, 0xCC003024@l(r3) /* 80023818 0001F658 54 03 E8 FE */ srwi r3, r0, 3 /* 8002381C 0001F65C 4E 80 00 20 */ blr .global OSResetSystem OSResetSystem: /* 80023820 0001F660 3C 60 80 42 */ lis r3, "@2083"@ha /* 80023824 0001F664 3C A0 80 42 */ lis r5, "@2163"@ha /* 80023828 0001F668 38 63 37 38 */ addi r3, r3, "@2083"@l /* 8002382C 0001F66C 38 80 04 A1 */ li r4, 0x4a1 /* 80023830 0001F670 38 A5 39 24 */ addi r5, r5, "@2163"@l /* 80023834 0001F674 4C C6 31 82 */ crclr 4*cr1+eq /* 80023838 0001F678 48 16 6F B8 */ b OSPanic /* 8002383C 0001F67C 00 00 00 00 */ .4byte 0x00000000 .include "macros.inc" .section .data, "wa" # 0x80421040 - 0x80496700 ; 0x000756C0 .global "@2083" "@2083": .4byte 0x4F535265 .4byte 0x7365742E .4byte 0x63000000 .global "@2084_80423744" "@2084_80423744": .4byte 0x5F5F4F53 .4byte 0x486F7452 .4byte 0x65736574 .4byte 0x28293A20 .4byte 0x46616C69 .4byte 0x65642074 .4byte 0x6F207265 .4byte 0x73657420 .4byte 0x73797374 .4byte 0x656D2E0A .4byte 0 .4byte 0x5F5F4F53 .4byte 0x52657475 .4byte 0x726E546F .4byte 0x4D656E75 .4byte 0x28293A20 .4byte 0x46616C69 .4byte 0x65642074 .4byte 0x6F20626F .4byte 0x6F742073 .4byte 0x79737465 .4byte 0x6D206D65 .4byte 0x6E752E0A .4byte 0 .global "@2131" "@2131": .4byte 0x4F535265 .4byte 0x7475726E .4byte 0x546F4D65 .4byte 0x6E752829 .4byte 0x3A204661 .4byte 0x6C696564 .4byte 0x20746F20 .4byte 0x626F6F74 .4byte 0x20737973 .4byte 0x74656D20 .4byte 0x6D656E75 .4byte 0x2E0A0000 .global "@2133" "@2133": .4byte 0x4F535265 .4byte 0x7475726E .4byte 0x546F4461 .4byte 0x74614D61 .4byte 0x6E616765 .4byte 0x7228293A .4byte 0x2046616C .4byte 0x69656420 .4byte 0x746F2062 .4byte 0x6F6F7420 .4byte 0x73797374 .4byte 0x656D206D .4byte 0x656E752E .4byte 0x0A000000 .4byte 0x43616C65 .4byte 0x6E646172 .4byte 0x2F43616C .4byte 0x656E6461 .4byte 0x725F696E .4byte 0x6465782E .4byte 0x68746D6C .4byte 0 .4byte 0x44697370 .4byte 0x6C61792F .4byte 0x44697370 .4byte 0x6C61795F .4byte 0x696E6465 .4byte 0x782E6874 .4byte 0x6D6C0000 .4byte 0x536F756E .4byte 0x642F536F .4byte 0x756E645F .4byte 0x696E6465 .4byte 0x782E6874 .4byte 0x6D6C0000 .4byte 0x50617265 .4byte 0x6E74616C .4byte 0x5F436F6E .4byte 0x74726F6C .4byte 0x2F506172 .4byte 0x656E7461 .4byte 0x6C5F436F .4byte 0x6E74726F .4byte 0x6C5F696E .4byte 0x6465782E .4byte 0x68746D6C .4byte 0 .4byte 0x496E7465 .4byte 0x726E6574 .4byte 0x2F496E74 .4byte 0x65726E65 .4byte 0x745F696E .4byte 0x6465782E .4byte 0x68746D6C .4byte 0 .4byte 0x57696943 .4byte 0x6F6E6E65 .4byte 0x63743234 .4byte 0x2F576969 .4byte 0x636F6E6E .4byte 0x65637432 .4byte 0x345F696E .4byte 0x6465782E .4byte 0x68746D6C .4byte 0 .4byte 0x55706461 .4byte 0x74652F55 .4byte 0x70646174 .4byte 0x655F696E .4byte 0x6465782E .4byte 0x68746D6C .4byte 0 .4byte 0x4F535265 .4byte 0x7475726E .4byte 0x546F5365 .4byte 0x7474696E .4byte 0x6728293A .4byte 0x20596F75 .4byte 0x2063616E .4byte 0x27742073 .4byte 0x70656369 .4byte 0x66792025 .4byte 0x642E2020 .4byte 0x0A000000 .global "@2163" "@2163": .4byte 0x4F535265 .4byte 0x73657453 .4byte 0x79737465 .4byte 0x6D282920 .4byte 0x6973206F .4byte 0x62736F6C .4byte 0x65746564 .4byte 0x2E204974 .4byte 0x20646F65 .4byte 0x736E2774 .4byte 0x20776F72 .4byte 0x6B20616E .4byte 0x79206C6F .4byte 0x6E676572 .4byte 0x2E0A0000 .4byte 0x4F535365 .4byte 0x74426F6F .4byte 0x74446F6C .4byte 0x28292069 .4byte 0x73206F62 .4byte 0x736F6C65 .4byte 0x7465642E .4byte 0x20497420 .4byte 0x646F6573 .4byte 0x6E277420 .4byte 0x776F726B .4byte 0x20616E79 .4byte 0x206C6F6E .4byte 0x6765722E .4byte 0x0A000000 .4byte 0 .include "macros.inc" .section .sbss, "", @nobits # 0x8055C6E0 - 0x8055DF80 ; 0x000018A0 .global bootThisDol bootThisDol: .skip 0x4 .global __OSIsReturnToIdle __OSIsReturnToIdle: .skip 0x4 .global ShutdownFunctionQueue ShutdownFunctionQueue: .skip 0x8