Skip to content
This repository has been archived by the owner on Oct 17, 2020. It is now read-only.

Commit

Permalink
Fix 7.0.1 compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
EliseZeroTwo committed Apr 22, 2019
1 parent 575a937 commit b454690
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/firmware.c
Expand Up @@ -57,7 +57,7 @@ pk11_offs *distinguishVersions(u32 kb) {
return &_pk11_offs[0]; return &_pk11_offs[0];
} }
} else if ((kb == KB_FIRMWARE_VERSION_700)) { } else if ((kb == KB_FIRMWARE_VERSION_700)) {
if (strcmp(id, "20181218175730")) { if (strcmp(id, "20181218175730") != 0 && strcmp(id, "20190208150037") != 0) {
return &_pk11_offs[9]; return &_pk11_offs[9];
} else { } else {
return &_pk11_offs[8]; return &_pk11_offs[8];
Expand All @@ -78,7 +78,7 @@ u8 loadFirm() {
bctBuf = ReadBoot0(&storage); bctBuf = ReadBoot0(&storage);
u32 ver = (*(u32*)(bctBuf+0x2330)) - 1; u32 ver = (*(u32*)(bctBuf+0x2330)) - 1;
u32 pkg11_size = *(u32 *)(bctBuf + 0x233C); u32 pkg11_size = *(u32 *)(bctBuf + 0x233C);
for (u32 i = 0; _pk11_offs[i].pkg11_off; i++) { //TODO distinguish 1.x & 2.x for (u32 i = 0; _pk11_offs[i].pkg11_off; i++) {
if(_pk11_offs[i].kb == ver){ if(_pk11_offs[i].kb == ver){
pk11Offs = (pk11_offs *)&_pk11_offs[i]; pk11Offs = (pk11_offs *)&_pk11_offs[i];
break; break;
Expand Down Expand Up @@ -130,8 +130,8 @@ u8 loadFirm() {


// Unpack Package2. // Unpack Package2.
print("Unpacking package2...\n"); print("Unpacking package2...\n");

pkg2_hdr_t *dec_pkg2 = unpackFirmwarePackage(pkg2); pkg2_hdr_t *dec_pkg2 = unpackFirmwarePackage(pkg2);

LIST_INIT(kip1_info); LIST_INIT(kip1_info);
pkg2_parse_kips(&kip1_info, dec_pkg2); pkg2_parse_kips(&kip1_info, dec_pkg2);


Expand Down
1 change: 1 addition & 0 deletions src/package.c
Expand Up @@ -18,6 +18,7 @@
#include "error.h" #include "error.h"
#include "fs.h" #include "fs.h"
#include "package.h" #include "package.h"
#include "patches.h"
#include "kippatches/fs.inc" #include "kippatches/fs.inc"


bool customSecmon = false; bool customSecmon = false;
Expand Down

0 comments on commit b454690

Please sign in to comment.