mirror of
https://github.com/CTCaer/hekate.git
synced 2024-11-22 18:06:40 +00:00
Fix ipatches backup on dumping
This commit is contained in:
parent
20040ae70f
commit
dad380344f
2 changed files with 5 additions and 5 deletions
|
@ -688,15 +688,15 @@ void bootrom_ipatches_info()
|
|||
if (!sd_save_to_file((u8 *)BOOTROM_BASE, BOOTROM_SIZE, path))
|
||||
gfx_puts(&gfx_con, "\nbootrom_patched.bin saved!\n");
|
||||
|
||||
u8 ipatch_backup[13];
|
||||
memcpy(ipatch_backup, (void *) IPATCH_BASE, 13);
|
||||
memset((void*)IPATCH_BASE, 0, 13);
|
||||
u32 ipatch_backup[13];
|
||||
memcpy(ipatch_backup, (void *) IPATCH_BASE, sizeof(ipatch_backup));
|
||||
memset((void*)IPATCH_BASE, 0, sizeof(ipatch_backup));
|
||||
|
||||
emmcsn_path_impl(path, "/dumps", "bootrom_unpatched.bin", NULL);
|
||||
if (!sd_save_to_file((u8 *)BOOTROM_BASE, BOOTROM_SIZE, path))
|
||||
gfx_puts(&gfx_con, "\nbootrom_unpatched.bin saved!\n");
|
||||
|
||||
memcpy((void*)IPATCH_BASE, ipatch_backup, 13);
|
||||
memcpy((void*)IPATCH_BASE, ipatch_backup, sizeof(ipatch_backup));
|
||||
|
||||
sd_unmount();
|
||||
}
|
||||
|
|
|
@ -96,7 +96,7 @@ static void _se_lock(bool lock_se)
|
|||
SE(SE_SECURITY_0) &= 0xFFFFFFFB; // Make access lock regs secure only.
|
||||
}
|
||||
|
||||
memset((void *)IPATCH_BASE, 0, 13);
|
||||
memset((void *)IPATCH_BASE, 0, 13 * sizeof(u32));
|
||||
SB(SB_CSR) = 0x10; // Protected IROM enable.
|
||||
|
||||
// This is useful for documenting the bits in the SE config registers, so we can keep it around.
|
||||
|
|
Loading…
Reference in a new issue