From f27422d88466278d45216acf52400c005c1a45de Mon Sep 17 00:00:00 2001 From: root <182859762@qq.com> Date: Fri, 13 Oct 2023 09:21:17 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=8E=89=E4=BA=86=E4=B8=80=E4=BA=9B?= =?UTF-8?q?=E7=BC=96=E8=AF=91=E8=AD=A6=E5=91=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- source/arm11/open_agb_firm.c | 8 ++++---- source/arm11/pages.c | 4 ++++ 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/source/arm11/open_agb_firm.c b/source/arm11/open_agb_firm.c index 4d5d211..fd50447 100644 --- a/source/arm11/open_agb_firm.c +++ b/source/arm11/open_agb_firm.c @@ -26,6 +26,7 @@ #include "arm11/drivers/hid.h" // @MERGE 231006 START #include "drivers/lgy_common.h" +#include "drivers/lgy11.h" // @MERGE 231006 END #include "arm11/drivers/lgyfb.h" #include "arm11/console.h" @@ -118,10 +119,9 @@ Result dump_rom( u32 size ) if( (res=fOpen(&file, "dump.gba", FA_OPEN_ALWAYS|FA_WRITE)) != RES_OK ) return res; - u8 *p = LGY_ROM_LOC; u32 len; ee_printf("dumping into dump.gba, file size %ld\n", size); - for( u8 *p=LGY_ROM_LOC; size > 0; size-=len, p+=len ) + for( u8 *p=(u8*)LGY_ROM_LOC; size > 0; size-=len, p+=len ) { res = fWrite( file, p, size < 256 ? size : 256, &len ); if( res != RES_OK ) @@ -269,7 +269,7 @@ static u32 read_hookpoint_file( void *path, u32 hookpoint[MAX_HOOKPOINT] ) return retval; } -static Result loadGbaRom(const char *const path, u32 *const romSizeOut) +static Result loadGbaRom(char * path, u32 *const romSizeOut) { Result res; FHandle f; @@ -516,7 +516,7 @@ static Result searchGbaDb(u64 x, GameDbEntry *const db, s32 *const entryPos) static u16 getSaveType(u32 romSize, const char *const savePath) { - FILINFO fi; + //FILINFO fi; const bool saveOverride = g_oafConfig.saveOverride; const u16 autoSaveType = detectSaveType(romSize); //const bool saveExists = fStat(savePath, &fi) == RES_OK; diff --git a/source/arm11/pages.c b/source/arm11/pages.c index a6abfaa..5a884fd 100644 --- a/source/arm11/pages.c +++ b/source/arm11/pages.c @@ -1,8 +1,12 @@ #include #include +#include #include "types.h" +#include "fsutil.h" #include "arm11/pages.h" #include "arm11/drivers/mcu.h" +#include "arm11/fmt.h" +#include "drivers/gfx.h" atp_error_t disp_str( atp_callerdata_t data, atp_counter_t, atp_linecfg_t *cfg ) {