From c3092b482a80b140fa21a48c2add431f9f86bab9 Mon Sep 17 00:00:00 2001 From: Aurora Date: Sun, 23 Oct 2016 03:42:52 +0200 Subject: [PATCH] This is actually Thumb code --- source/emunand.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/source/emunand.c b/source/emunand.c index c0fadca..67b2186 100644 --- a/source/emunand.c +++ b/source/emunand.c @@ -169,14 +169,17 @@ static inline u32 patchMpu(u8 *pos, u32 size) const u8 pattern[] = {0x03, 0x00, 0x24, 0x00}; u32 ret; - u32 *off = (u32 *)memsearch(pos, pattern, size, sizeof(pattern)); + u16 *off = (u16 *)memsearch(pos, pattern, size, sizeof(pattern)); if(off == NULL) ret = 1; else { - off[0] = 0x00360003; - off[6] = 0x00200603; - off[9] = 0x001C0603; + off[0] = 0x0003; + off[1] = 0x0036; + off[0xC] = 0x0603; + off[0xD] = 0x0020; + off[0x12] = 0x0603; + off[0x13] = 0x001C; ret = 0; }