diff options
Diffstat (limited to 'mtkimage-gpt-expand.patch')
-rw-r--r-- | mtkimage-gpt-expand.patch | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/mtkimage-gpt-expand.patch b/mtkimage-gpt-expand.patch new file mode 100644 index 000000000000..a1819a469d14 --- /dev/null +++ b/mtkimage-gpt-expand.patch @@ -0,0 +1,28 @@ +diff -NarU 6 a/tools/mtk_image.h b/tools/mtk_image.h +Create empty space for sectors 1 to 34. +--- a/tools/mtk_image.h 2021-06-10 20:32:04.156559289 +0200 ++++ b/tools/mtk_image.h 2021-06-10 20:32:36.964722097 +0200 +@@ -16,13 +16,13 @@ + struct { + char name[12]; + uint32_t version; + uint32_t size; + }; + +- uint8_t pad[0x200]; ++ uint8_t pad[34*512]; + }; + + #define EMMC_BOOT_NAME "EMMC_BOOT" + #define SF_BOOT_NAME "SF_BOOT" + #define SDMMC_BOOT_NAME "SDMMC_BOOT" + +diff -NarU 1 a/tools/mtk_image.c b/tools/mtk_image.c +Increase memory buffer size. +--- a/tools/mtk_image.c 2021-06-11 13:26:11.580666817 +0200 ++++ b/tools/mtk_image.c 2021-06-11 13:29:14.024018325 +0200 +@@ -63,3 +63,3 @@ + /* GFH header + 2 * 4KB pages of NAND */ +-static char hdr_tmp[sizeof(struct gfh_header) + 0x2000]; ++static char hdr_tmp[sizeof(struct gfh_header) + 0x2000 + 0x10000]; + |