Initial commit

This commit is contained in:
Gericom
2025-11-22 11:08:28 +01:00
commit 9cf3ffbfcf
358 changed files with 58350 additions and 0 deletions

View File

@@ -0,0 +1,26 @@
#pragma once
#include "sections.h"
#include "thumbInstructions.h"
#include "../acekard-common/iorpgSdWaitForStateAsm.h"
DEFINE_SECTION_SYMBOLS(ak2_sdreadsector);
extern "C" void ak2_sdReadSector(u32 srcSector, void* dst, u32 sectorCount);
extern u32 ak2_sdReadSector_sdWaitForState_address;
class AK2SDReadSectorPatchCode : public PatchCode
{
public:
explicit AK2SDReadSectorPatchCode(PatchHeap& patchHeap,
const ioRPGSDWaitForStatePatchCode* iorpgSdWaitForStatePatchCode)
: PatchCode(SECTION_START(ak2_sdreadsector), SECTION_SIZE(ak2_sdreadsector), patchHeap)
{
ak2_sdReadSector_sdWaitForState_address = (u32)iorpgSdWaitForStatePatchCode->GetSDWaitForStateFunction();
}
const void* GetSDReadSectorFunction() const
{
return GetAddressAtTarget((void*)ak2_sdReadSector);
}
};