Add support for the new NOOK_MAGIC
The new cmdline value that's been in use since Marshmallow
This commit is contained in:
parent
31360c34ed
commit
3e48427eaf
@ -124,7 +124,8 @@ int parse_img(const char *image, boot_img *boot) {
|
||||
fprintf(stderr, "PXA_BOOT_HDR\n");
|
||||
boot->hdr = malloc(sizeof(pxa_boot_img_hdr));
|
||||
memcpy(boot->hdr, head, sizeof(pxa_boot_img_hdr));
|
||||
} else if (memcmp(((boot_img_hdr*) head)->cmdline, NOOK_MAGIC, 12) == 0) {
|
||||
} else if (memcmp(((boot_img_hdr*) head)->cmdline, NOOK_MAGIC, 12) == 0
|
||||
|| memcmp(((boot_img_hdr*) head)->cmdline, NOOK_NEW_MAGIC, 26) == 0) {
|
||||
boot->flags |= NOOK_FLAG;
|
||||
fprintf(stderr, "NOOK_GREEN_LOADER\n");
|
||||
head += NOOK_PRE_HEADER_SZ - 1;
|
||||
|
@ -39,6 +39,7 @@ typedef enum {
|
||||
#define SEANDROID_MAGIC "SEANDROIDENFORCE"
|
||||
#define TEGRABLOB_MAGIC "-SIGNED-BY-SIGNBLOB-"
|
||||
#define NOOK_MAGIC "Green Loader"
|
||||
#define NOOK_NEW_MAGIC "eMMC boot.img+secondloader"
|
||||
#define NOOK_PRE_HEADER_SZ 1048576
|
||||
|
||||
#define SUP_LIST ((char *[]) { "gzip", "xz", "lzma", "bzip2", "lz4", "lz4_legacy", NULL })
|
||||
|
Loading…
Reference in New Issue
Block a user