|
@@ -506,8 +506,7 @@ static void print_hdr_v2(struct imx_header *imx_hdr)
|
|
genimg_print_size(hdr_v2->boot_data.size);
|
|
genimg_print_size(hdr_v2->boot_data.size);
|
|
printf("Load Address: %08x\n", (uint32_t)fhdr_v2->boot_data_ptr);
|
|
printf("Load Address: %08x\n", (uint32_t)fhdr_v2->boot_data_ptr);
|
|
printf("Entry Point: %08x\n", (uint32_t)fhdr_v2->entry);
|
|
printf("Entry Point: %08x\n", (uint32_t)fhdr_v2->entry);
|
|
- if (fhdr_v2->csf && (imximage_ivt_offset != UNDEFINED) &&
|
|
|
|
- (imximage_csf_size != UNDEFINED)) {
|
|
|
|
|
|
+ if (fhdr_v2->csf) {
|
|
uint16_t dcdlen;
|
|
uint16_t dcdlen;
|
|
int offs;
|
|
int offs;
|
|
|
|
|
|
@@ -515,10 +514,16 @@ static void print_hdr_v2(struct imx_header *imx_hdr)
|
|
offs = (char *)&hdr_v2->data.dcd_table
|
|
offs = (char *)&hdr_v2->data.dcd_table
|
|
- (char *)hdr_v2;
|
|
- (char *)hdr_v2;
|
|
|
|
|
|
|
|
+ /*
|
|
|
|
+ * The HAB block is the first part of the image, from
|
|
|
|
+ * start of IVT header (fhdr_v2->self) to the start of
|
|
|
|
+ * the CSF block (fhdr_v2->csf). So HAB size is
|
|
|
|
+ * calculated as:
|
|
|
|
+ * HAB_size = fhdr_v2->csf - fhdr_v2->self
|
|
|
|
+ */
|
|
printf("HAB Blocks: 0x%08x 0x%08x 0x%08x\n",
|
|
printf("HAB Blocks: 0x%08x 0x%08x 0x%08x\n",
|
|
(uint32_t)fhdr_v2->self, 0,
|
|
(uint32_t)fhdr_v2->self, 0,
|
|
- hdr_v2->boot_data.size - imximage_ivt_offset -
|
|
|
|
- imximage_csf_size);
|
|
|
|
|
|
+ (uint32_t)(fhdr_v2->csf - fhdr_v2->self));
|
|
printf("DCD Blocks: 0x00910000 0x%08x 0x%08x\n",
|
|
printf("DCD Blocks: 0x00910000 0x%08x 0x%08x\n",
|
|
offs, be16_to_cpu(dcdlen));
|
|
offs, be16_to_cpu(dcdlen));
|
|
}
|
|
}
|