Skip to content

Commit

Permalink
unpackbootimg: patch for tagsaddr too
Browse files Browse the repository at this point in the history
- display tags_addr and export out to file
  • Loading branch information
osm0sis committed Oct 25, 2013
1 parent 23b502e commit 9a86bf0
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions unpackbootimg.c
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ int main(int argc, char** argv)
if (header.second_size != 0) {
printf("BOARD_SECOND_ADDR %08x\n", header.second_addr);
}
printf("BOARD_TAGS_ADDR %08x\n", header.tags_addr);
if (header.dt_size != 0) {
printf("BOARD_DT_SIZE %d\n", header.dt_size);
}
Expand Down Expand Up @@ -146,6 +147,13 @@ int main(int argc, char** argv)
write_string_to_file(tmp, secondaddrtmp);
}

//printf("tagsaddr...\n");
sprintf(tmp, "%s/%s", directory, basename(filename));
strcat(tmp, "-tagsaddr");
char tagsaddrtmp[200];
sprintf(tagsaddrtmp, "%08x", header.tags_addr);
write_string_to_file(tmp, tagsaddrtmp);

total_read += sizeof(header);
//printf("total read: %d\n", total_read);
total_read += read_padding(f, sizeof(header), pagesize);
Expand Down

0 comments on commit 9a86bf0

Please sign in to comment.