From patchwork Mon Apr 23 18:35:03 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bryan O'Donoghue X-Patchwork-Id: 134024 Delivered-To: patch@linaro.org Received: by 10.46.151.6 with SMTP id r6csp1323262lji; Mon, 23 Apr 2018 11:35:12 -0700 (PDT) X-Google-Smtp-Source: AIpwx4/vWsYB7Y1vw9AyRMHOj0jfOtfuc8QDblGRq1+JiGYWiyVA+7zRSHDMiP87MK8b2lSxT31j X-Received: by 10.80.235.65 with SMTP id z1mr29439846edp.154.1524508512701; Mon, 23 Apr 2018 11:35:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524508512; cv=none; d=google.com; s=arc-20160816; b=JPsyO3r5g+7hKTWP2yP2NQE3Xd7tQntCFoA2LmVxacIXkcWqxtIf63Od+SpdCquHt5 LdI/cyHwV5CFNhPUM5q/erlRwV91b10DRSNCsI9CReHUHi7CrgTrDWhBSRJD3mXCzkaF l9R6flQOW8rvLlzIa93YI/p5kU1lTVMnkoIoHMA5tOiOB1nGxtkeptYP6NuD7ZHymnmP vbF2wo1hSXSg/Wiu1LeImS9tVUYesQfWZXcsrPQB0mRiHC5kSxDydo1zkkub5oULf7Z+ 9a7sgjo+RG7KmgKJ9ScxPFjNVne2TYFWwrGRmoXBLiRzIvEwVTLGmbJLqoHJO7UkoM36 mqQw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:cc:message-id:date:to:from :dkim-signature:arc-authentication-results; bh=8hNLaSTd7m1cvo4PbIqQc/gX1iVBWtDUuBgazTWhe+E=; b=jQvMGm7OFE/S9ZFAX77B+bE2GmSO0ZrOMvcoXDOS0TpJ9nv6kcbtXIg4c9eG+K8Qta XuNNqZHP0mRMsk3v8JGe+Ltacn0bbQUwxs4RYzTRDmlUBpcI6woirKvwNL9MAvCYDFDu iOr+Q8A4qcxyIZRNVcL4J5Zfi1YbfU/Zdip6nW8h2DlPwcE59PCWjKI8W+4eJWJ2oAof 27vHym3CZT2MJSJ9Tipcjtw12JZLWOa2KJZH/4WwPNzr6gMM5BYwpIZL7JmzsHa4XLpL 6aL5BSa6YEFxZ8zQDefQtlYP8ufVMlFl+9YJYyyNm4a5sOZzQM7OnIxerEbLvVO5OLv5 gZjw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=L80qp+8d; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id a57si824942edd.378.2018.04.23.11.35.11; Mon, 23 Apr 2018 11:35:12 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) client-ip=81.169.180.215; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=L80qp+8d; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by lists.denx.de (Postfix, from userid 105) id B7140C21E34; Mon, 23 Apr 2018 18:35:09 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=RCVD_IN_DNSWL_BLOCKED, RCVD_IN_MSPIKE_H2, T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id D14DEC21CB6; Mon, 23 Apr 2018 18:35:07 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id 0CD0FC21D4A; Mon, 23 Apr 2018 18:35:06 +0000 (UTC) Received: from mail-wr0-f194.google.com (mail-wr0-f194.google.com [209.85.128.194]) by lists.denx.de (Postfix) with ESMTPS id 7883FC21C57 for ; Mon, 23 Apr 2018 18:35:06 +0000 (UTC) Received: by mail-wr0-f194.google.com with SMTP id s18-v6so43928025wrg.9 for ; Mon, 23 Apr 2018 11:35:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id; bh=5eCWyjewjbkvoqUiENIQele96ebW53nrNQDsx1nv6wU=; b=L80qp+8dV5yjPSfz9vPbIVWolNu/6+/7a9LY0n5Z8jTV4OEt9M2g7QSl38WFrqxw3D PH3h/vnRv6XCEP8OOShC74Gp31Ok1ylVnIgSmRmm/b8j9H/LvdPLMOA4F+kBcu/3MMM+ zjODqOoDfP10MI0LIjjC1st9bnUVMQr/R+qtE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=5eCWyjewjbkvoqUiENIQele96ebW53nrNQDsx1nv6wU=; b=fkMgLQ7vu15r1SDL6ipZTFNllFurEEZr38n12Rxw9kBaVqdk3rEHGVJpXxku/gehPN PI4tbCGLENsco0PfLZptjvMUfN73LMFD+6FVsIDuan5jkP3IweCoBDs1Z9hzvpwOKzWU ShguzO0WG0kUR0Slqn/zWSZDNODVwoLo+6DxKZdeG5rmApmD6jqNxOZeltf7jSwG1sqF lJvEpXKVujozL20kvGr7RKioyumttU2al+bi3RNb0Ra1CH/jX2XCyQikeTLX6We4D817 m6o1yLqLkLPI8cVw4n9FYX+qYGfhxlfKJ8vkF6AwCwOFbKkBQiQIxdAVEE4s90HCQ8Nf Qc9w== X-Gm-Message-State: ALQs6tAiLNhWU3QYRFD9RgQ0I0W1CsjjLrTZUd5MbMIY6XaviE3B/P8Y wa8cbZRlYFmoLk84OK90PmOdhekuKTQ= X-Received: by 10.80.234.205 with SMTP id u13mr28974652edp.288.1524508505867; Mon, 23 Apr 2018 11:35:05 -0700 (PDT) Received: from event-horizon.net ([109.255.42.2]) by smtp.gmail.com with ESMTPSA id z4sm8401027edm.44.2018.04.23.11.35.04 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 23 Apr 2018 11:35:04 -0700 (PDT) From: Bryan O'Donoghue To: u-boot@lists.denx.de Date: Mon, 23 Apr 2018 18:35:03 +0000 Message-Id: <20180423183503.30601-1-bryan.odonoghue@linaro.org> X-Mailer: git-send-email 2.17.0 Cc: Fabio Estevam , Breno Lima Subject: [U-Boot] [PATCH] tools/imximage: Fix fruity lack of 0x prefix in DCD Blocks X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" commit 8519c9c98ad6 ("tools/imximage: use 0x prefix in HAB Blocks line") adds an 0x prefix to each HAB Block number to make it easier for host tools to process the HAB Block output, however it neglects to apply the same prefix to the DCD Blocks directive. You need the DCD Blocks directive if you are making a u-boot recovery image which the BootROM will accept via the USB upload utility. This disparity results in a fruity output like this with HAB Blocks prefixed but DCD Blocks not prefixed - which is pretty inconsistent. This patch fixes the difference assuming the original commit was a legitimate change. Old: Image Type: Freescale IMX Boot Image Image Ver: 2 (i.MX53/6/7 compatible) Mode: DCD Data Size: 430080 Bytes = 420.00 KiB = 0.41 MiB Load Address: 877ff420 Entry Point: 87800000 HAB Blocks: 0x877ff400 0x00000000 0x00066c00 DCD Blocks: 00910000 0000002c 000001d4 New: Image Type: Freescale IMX Boot Image Image Ver: 2 (i.MX53/6/7 compatible) Mode: DCD Data Size: 430080 Bytes = 420.00 KiB = 0.41 MiB Load Address: 877ff420 Entry Point: 87800000 HAB Blocks: 0x877ff400 0x00000000 0x00066c00 DCD Blocks: 0x00910000 0x0000002c 0x000001d4 Signed-off-by: Bryan O'Donoghue Cc: Rasmus Villemoes Cc: Fabio Estevam Cc: Breno Lima Reviewed-by: Fabio Estevam --- tools/imximage.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/imximage.c b/tools/imximage.c index 6dabb13520..6f16d45351 100644 --- a/tools/imximage.c +++ b/tools/imximage.c @@ -520,7 +520,7 @@ static void print_hdr_v2(struct imx_header *imx_hdr) (uint32_t)fhdr_v2->self, 0, hdr_v2->boot_data.size - imximage_ivt_offset - imximage_csf_size); - printf("DCD Blocks: 00910000 %08x %08x\n", + printf("DCD Blocks: 0x00910000 0x%08x 0x%08x\n", offs, be16_to_cpu(dcdlen)); } } else {