Files
dusklight/libs/dolphin/dvd/dvdfs.cpp
T
2021-03-31 23:22:38 +02:00

435 lines
14 KiB
C++

//
// Generated By: dol2asm
// Translation Unit: dvdfs
//
#include "dol2asm.h"
#include "dolphin/types.h"
#include "dolphin/dvd/dvdfs.h"
//
// Forward References:
//
// False False
extern "C" void __DVDFSInit();
// False False
extern "C" void DVDConvertPathToEntrynum();
// False False
extern "C" void DVDFastOpen();
// False False
extern "C" void DVDOpen();
// False False
extern "C" void DVDClose();
// True False
extern "C" static void entryToPath();
// True False
extern "C" static void DVDConvertEntrynumToPath();
// True False
extern "C" static void DVDGetCurrentDir();
// False False
extern "C" void DVDChangeDir();
// False False
extern "C" void DVDReadAsyncPrio();
// True False
extern "C" static void cbForReadAsync();
// False False
extern "C" void DVDReadPrio();
// True False
extern "C" static void cbForReadSync();
// False False
extern "C" void DVDOpenDir();
// False False
extern "C" void DVDReadDir();
// False False
// bool False
extern "C" bool DVDCloseDir();
extern "C" extern u8 __DVDLongFileNameFlag[4];
extern "C" extern u8 __DVDThreadQueue[8];
//
// External References:
//
// False False
extern "C" void OSReport();
// False False
extern "C" void OSPanic();
// False False
extern "C" void OSDisableInterrupts();
// False False
extern "C" void OSRestoreInterrupts();
// False False
extern "C" void OSSleepThread();
// False False
extern "C" void OSWakeupThread();
// False False
extern "C" void DVDReadAbsAsyncPrio();
// False False
extern "C" void DVDCancel();
// False False
extern "C" void tolower();
//
// Declarations:
//
/* ############################################################################################## */
/* 80451758-8045175C 0004+00 s=1 e=0 z=0 None .sbss BootInfo */
static u8 BootInfo[4];
/* 8045175C-80451760 0004+00 s=10 e=0 z=0 None .sbss FstStart */
static u8 FstStart[4];
/* 80451760-80451764 0004+00 s=5 e=0 z=0 None .sbss FstStringStart */
static u8 FstStringStart[4];
/* 80451764-80451768 0004+00 s=2 e=0 z=0 None .sbss MaxEntryNum */
static u8 MaxEntryNum[4];
/* 803484F0-80348528 0038+00 s=0 e=2 z=0 None .text __DVDFSInit */
// 803484F4: 80451758 (BootInfo)
// 803484FC: 8045175C (FstStart)
// 80348500: 8045175C (FstStart)
// 80348510: 80451764 (MaxEntryNum)
// 80348514: 80451764 (MaxEntryNum)
// 80348520: 80451760 (FstStringStart)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// False False
extern "C" asm void __DVDFSInit() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/__DVDFSInit.s"
}
#pragma pop
/* ############################################################################################## */
/* 803D1380-803D1448 00C8+00 s=1 e=0 z=0 None .data @119 */
SECTION_DATA static u8 lit_119[200] = {
0x44, 0x56, 0x44, 0x43, 0x6F, 0x6E, 0x76, 0x65, 0x72, 0x74, 0x45, 0x6E, 0x74, 0x72, 0x79, 0x6E,
0x75, 0x6D, 0x54, 0x6F, 0x50, 0x61, 0x74, 0x68, 0x28, 0x70, 0x6F, 0x73, 0x73, 0x69, 0x62, 0x6C,
0x79, 0x20, 0x44, 0x56, 0x44, 0x4F, 0x70, 0x65, 0x6E, 0x20, 0x6F, 0x72, 0x20, 0x44, 0x56, 0x44,
0x43, 0x68, 0x61, 0x6E, 0x67, 0x65, 0x44, 0x69, 0x72, 0x20, 0x6F, 0x72, 0x20, 0x44, 0x56, 0x44,
0x4F, 0x70, 0x65, 0x6E, 0x44, 0x69, 0x72, 0x29, 0x3A, 0x20, 0x73, 0x70, 0x65, 0x63, 0x69, 0x66,
0x69, 0x65, 0x64, 0x20, 0x64, 0x69, 0x72, 0x65, 0x63, 0x74, 0x6F, 0x72, 0x79, 0x20, 0x6F, 0x72,
0x20, 0x66, 0x69, 0x6C, 0x65, 0x20, 0x28, 0x25, 0x73, 0x29, 0x20, 0x64, 0x6F, 0x65, 0x73, 0x6E,
0x27, 0x74, 0x20, 0x6D, 0x61, 0x74, 0x63, 0x68, 0x20, 0x73, 0x74, 0x61, 0x6E, 0x64, 0x61, 0x72,
0x64, 0x20, 0x38, 0x2E, 0x33, 0x20, 0x66, 0x6F, 0x72, 0x6D, 0x61, 0x74, 0x2E, 0x20, 0x54, 0x68,
0x69, 0x73, 0x20, 0x69, 0x73, 0x20, 0x61, 0x20, 0x74, 0x65, 0x6D, 0x70, 0x6F, 0x72, 0x61, 0x72,
0x79, 0x20, 0x72, 0x65, 0x73, 0x74, 0x72, 0x69, 0x63, 0x74, 0x69, 0x6F, 0x6E, 0x20, 0x61, 0x6E,
0x64, 0x20, 0x77, 0x69, 0x6C, 0x6C, 0x20, 0x62, 0x65, 0x20, 0x72, 0x65, 0x6D, 0x6F, 0x76, 0x65,
0x64, 0x20, 0x73, 0x6F, 0x6F, 0x6E, 0x0A, 0x00,
};
/* 804509E0-804509E8 0008+00 s=3 e=0 z=0 None .sdata @118 */
SECTION_SDATA static u8 lit_118[8] = {
0x64, 0x76, 0x64, 0x66, 0x73, 0x2E, 0x63, 0x00,
};
/* 80451768-8045176C 0004+00 s=4 e=0 z=0 None .sbss currentDirectory */
static u8 currentDirectory[4];
/* 8045176C-80451770 0004+00 s=1 e=1 z=0 None .sbss __DVDLongFileNameFlag */
u8 __DVDLongFileNameFlag[4];
/* 80348528-8034881C 02F4+00 s=3 e=6 z=0 None .text DVDConvertPathToEntrynum */
// 8034853C: 803D1380 (lit_119)
// 80348544: 803D1380 (lit_119)
// 80348548: 80451768 (currentDirectory)
// 803485A0: 8045175C (FstStart)
// 803485C0: 8045175C (FstStart)
// 803485F0: 8045176C (__DVDLongFileNameFlag)
// 80348694: 804509E0 (lit_118)
// 8034869C: 80006E7C (OSPanic)
// 8034871C: 80451760 (FstStringStart)
// 8034873C: 80365470 (tolower)
// 80348750: 80365470 (tolower)
// 80348798: 8045175C (FstStart)
// 803487D0: 8045175C (FstStart)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// False False
extern "C" asm void DVDConvertPathToEntrynum() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/DVDConvertPathToEntrynum.s"
}
#pragma pop
/* 8034881C-80348890 0074+00 s=0 e=3 z=0 None .text DVDFastOpen */
// 80348824: 80451764 (MaxEntryNum)
// 80348834: 8045175C (FstStart)
// 80348874: 8045175C (FstStart)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// False False
extern "C" asm void DVDFastOpen() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/DVDFastOpen.s"
}
#pragma pop
/* ############################################################################################## */
/* 803D1448-803D1480 0037+01 s=1 e=0 z=0 None .data @140 */
SECTION_DATA static u8 lit_140[55 + 1 /* padding */] = {
0x57, 0x61, 0x72, 0x6E, 0x69, 0x6E, 0x67, 0x3A, 0x20, 0x44, 0x56, 0x44, 0x4F, 0x70, 0x65, 0x6E,
0x28, 0x29, 0x3A, 0x20, 0x66, 0x69, 0x6C, 0x65, 0x20, 0x27, 0x25, 0x73, 0x27, 0x20, 0x77, 0x61,
0x73, 0x20, 0x6E, 0x6F, 0x74, 0x20, 0x66, 0x6F, 0x75, 0x6E, 0x64, 0x20, 0x75, 0x6E, 0x64, 0x65,
0x72, 0x20, 0x25, 0x73, 0x2E, 0x0A, 0x00,
/* padding */
0x00,
};
/* 80348890-80348958 00C8+00 s=0 e=3 z=1 None .text DVDOpen */
// 803488AC: 80348528 (DVDConvertPathToEntrynum)
// 803488C0: 80348C30 (DVDGetCurrentDir)
// 803488C4: 803D1448 (lit_140)
// 803488CC: 803D1448 (lit_140)
// 803488D8: 80006ABC (OSReport)
// 803488E8: 8045175C (FstStart)
// 80348928: 8045175C (FstStart)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// False False
extern "C" asm void DVDOpen() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/DVDOpen.s"
}
#pragma pop
/* 80348958-8034897C 0024+00 s=0 e=4 z=2 None .text DVDClose */
// 80348964: 8034B550 (DVDCancel)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// False False
extern "C" asm void DVDClose() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/DVDClose.s"
}
#pragma pop
/* 8034897C-80348ADC 0160+00 s=2 e=0 z=0 None .text entryToPath */
// 803489B0: 8045175C (FstStart)
// 803489B8: 80451760 (FstStringStart)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// True False
extern "C" asm static void entryToPath() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/entryToPath.s"
}
#pragma pop
/* 80348ADC-80348C30 0154+00 s=1 e=0 z=0 None .text DVDConvertEntrynumToPath */
// 80348B14: 8045175C (FstStart)
// 80348B18: 80451760 (FstStringStart)
// 80348B38: 8034897C (entryToPath)
// 80348BB8: 8045175C (FstStart)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// True False
extern "C" asm static void DVDConvertEntrynumToPath() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/DVDConvertEntrynumToPath.s"
}
#pragma pop
/* 80348C30-80348CF4 00C4+00 s=1 e=0 z=0 None .text DVDGetCurrentDir */
// 80348C58: 80451768 (currentDirectory)
// 80348C60: 8034897C (entryToPath)
// 80348C80: 8045175C (FstStart)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// True False
extern "C" asm static void DVDGetCurrentDir() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/DVDGetCurrentDir.s"
}
#pragma pop
/* 80348CF4-80348D54 0060+00 s=0 e=2 z=0 None .text DVDChangeDir */
// 80348D00: 80348528 (DVDConvertPathToEntrynum)
// 80348D10: 8045175C (FstStart)
// 80348D3C: 80451768 (currentDirectory)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// False False
extern "C" asm void DVDChangeDir() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/DVDChangeDir.s"
}
#pragma pop
/* ############################################################################################## */
/* 803D1480-803D14B4 0034+00 s=1 e=0 z=0 None .data @239 */
SECTION_DATA static u8 lit_239[52] = {
0x44, 0x56, 0x44, 0x52, 0x65, 0x61, 0x64, 0x41, 0x73, 0x79, 0x6E, 0x63, 0x28, 0x29, 0x3A, 0x20,
0x73, 0x70, 0x65, 0x63, 0x69, 0x66, 0x69, 0x65, 0x64, 0x20, 0x61, 0x72, 0x65, 0x61, 0x20, 0x69,
0x73, 0x20, 0x6F, 0x75, 0x74, 0x20, 0x6F, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x66, 0x69, 0x6C,
0x65, 0x20, 0x20, 0x00,
};
/* 80348D54-80348E14 00C0+00 s=0 e=2 z=0 None .text DVDReadAsyncPrio */
// 80348D8C: 803D1480 (lit_239)
// 80348D94: 803D1480 (lit_239)
// 80348D98: 804509E0 (lit_118)
// 80348DA0: 80006E7C (OSPanic)
// 80348DBC: 803D1480 (lit_239)
// 80348DC4: 803D1480 (lit_239)
// 80348DC8: 804509E0 (lit_118)
// 80348DD0: 80006E7C (OSPanic)
// 80348DD8: 80348E14 (cbForReadAsync)
// 80348DDC: 80348E14 (cbForReadAsync)
// 80348DF8: 8034AD2C (DVDReadAbsAsyncPrio)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// False False
extern "C" asm void DVDReadAsyncPrio() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/DVDReadAsyncPrio.s"
}
#pragma pop
/* 80348E14-80348E44 0030+00 s=1 e=0 z=0 None .text cbForReadAsync */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// True False
extern "C" asm static void cbForReadAsync() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/cbForReadAsync.s"
}
#pragma pop
/* ############################################################################################## */
/* 803D14B4-803D14E4 002F+01 s=1 e=0 z=0 None .data @265 */
SECTION_DATA static u8 lit_265[47 + 1 /* padding */] = {
0x44, 0x56, 0x44, 0x52, 0x65, 0x61, 0x64, 0x28, 0x29, 0x3A, 0x20, 0x73, 0x70, 0x65, 0x63, 0x69,
0x66, 0x69, 0x65, 0x64, 0x20, 0x61, 0x72, 0x65, 0x61, 0x20, 0x69, 0x73, 0x20, 0x6F, 0x75, 0x74,
0x20, 0x6F, 0x66, 0x20, 0x74, 0x68, 0x65, 0x20, 0x66, 0x69, 0x6C, 0x65, 0x20, 0x20, 0x00,
/* padding */
0x00,
};
/* 80451770-80451778 0008+00 s=2 e=3 z=0 None .sbss __DVDThreadQueue */
u8 __DVDThreadQueue[8];
/* 80348E44-80348F5C 0118+00 s=0 e=9 z=3 None .text DVDReadPrio */
// 80348E78: 803D14B4 (lit_265)
// 80348E80: 803D14B4 (lit_265)
// 80348E84: 804509E0 (lit_118)
// 80348E8C: 80006E7C (OSPanic)
// 80348EA8: 803D14B4 (lit_265)
// 80348EB0: 803D14B4 (lit_265)
// 80348EB4: 804509E0 (lit_118)
// 80348EBC: 80006E7C (OSPanic)
// 80348EC4: 80348F5C (cbForReadSync)
// 80348EC8: 80348F5C (cbForReadSync)
// 80348EE0: 8034AD2C (DVDReadAbsAsyncPrio)
// 80348EF4: 8033D6F4 (OSDisableInterrupts)
// 80348F30: 80451770 (__DVDThreadQueue)
// 80348F34: 80341BAC (OSSleepThread)
// 80348F40: 8033D71C (OSRestoreInterrupts)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// False False
extern "C" asm void DVDReadPrio() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/DVDReadPrio.s"
}
#pragma pop
/* 80348F5C-80348F80 0024+00 s=1 e=0 z=0 None .text cbForReadSync */
// 80348F60: 80451770 (__DVDThreadQueue)
// 80348F6C: 80341C98 (OSWakeupThread)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// True False
extern "C" asm static void cbForReadSync() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/cbForReadSync.s"
}
#pragma pop
/* ############################################################################################## */
/* 803D14E4-803D1520 003A+02 s=1 e=0 z=0 None .data @311 */
SECTION_DATA static u8 lit_311[58 + 2 /* padding */] = {
0x57, 0x61, 0x72, 0x6E, 0x69, 0x6E, 0x67, 0x3A, 0x20, 0x44, 0x56, 0x44, 0x4F, 0x70, 0x65, 0x6E,
0x44, 0x69, 0x72, 0x28, 0x29, 0x3A, 0x20, 0x66, 0x69, 0x6C, 0x65, 0x20, 0x27, 0x25, 0x73, 0x27,
0x20, 0x77, 0x61, 0x73, 0x20, 0x6E, 0x6F, 0x74, 0x20, 0x66, 0x6F, 0x75, 0x6E, 0x64, 0x20, 0x75,
0x6E, 0x64, 0x65, 0x72, 0x20, 0x25, 0x73, 0x2E, 0x0A, 0x00,
/* padding */
0x00, 0x00,
};
/* 80348F80-80349040 00C0+00 s=0 e=3 z=0 None .text DVDOpenDir */
// 80348F9C: 80348528 (DVDConvertPathToEntrynum)
// 80348FA8: 80451768 (currentDirectory)
// 80348FB4: 80348ADC (DVDConvertEntrynumToPath)
// 80348FB8: 803D14E4 (lit_311)
// 80348FC0: 803D14E4 (lit_311)
// 80348FCC: 80006ABC (OSReport)
// 80348FDC: 8045175C (FstStart)
// 80349018: 8045175C (FstStart)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// False False
extern "C" asm void DVDOpenDir() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/DVDOpenDir.s"
}
#pragma pop
/* 80349040-803490E4 00A4+00 s=0 e=3 z=0 None .text DVDReadDir */
// 8034906C: 8045175C (FstStart)
// 8034908C: 8045175C (FstStart)
// 80349090: 80451760 (FstStringStart)
// 803490A4: 8045175C (FstStart)
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
// False False
extern "C" asm void DVDReadDir() {
nofralloc
#include "asm/dolphin/dvd/dvdfs/DVDReadDir.s"
}
#pragma pop
/* 803490E4-803490EC 0008+00 s=0 e=3 z=0 None .text DVDCloseDir */
// False False
// bool False
extern "C" bool DVDCloseDir() {
return true;
}