Fix bug with previous changes to execute_multiboot()

This commit is contained in:
Philippe Symons 2025-03-24 14:17:01 +01:00
parent 3d02b1aea7
commit 65b0e10b48

View File

@ -1,4 +1,5 @@
#include <tonc.h>
#include <string.h>
// This file is autogenerated from the file in the graphics folder
#include "ptgb_logo_l.h"
@ -6,6 +7,7 @@
#include "multiboot_rom_bin.h"
#define SPRITE_CHAR_BLOCK 4
#define DST_EWRAM (void*)0x02000000
#define MULTIBOOT_ENTRY_POINT (void*)0x020000C0
/**
@ -67,7 +69,7 @@ static void load_logo(u32* curSpriteIndex)
*/
static void load_multiboot_rom(const void *src, u32 size)
{
memcpy32(MULTIBOOT_ENTRY_POINT, src, size);
memcpy(DST_EWRAM, src, size);
}
/**
@ -76,6 +78,7 @@ static void load_multiboot_rom(const void *src, u32 size)
void execute_multiboot()
{
// Disable interrupts
// During the time the user could swap out the cartridge, we should disable interrupts
REG_IME = 0;
// Set up waitstates (multiboot defaults to faster EWRAM access)