Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 7B73BC433F5 for ; Wed, 30 Mar 2022 10:06:27 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id E8766840B2; Wed, 30 Mar 2022 12:06:24 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=none dis=none) header.from=rock-chips.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by phobos.denx.de (Postfix, from userid 109) id 2144C840B2; Wed, 30 Mar 2022 12:06:23 +0200 (CEST) Received: from mail-m17657.qiye.163.com (mail-m17657.qiye.163.com [59.111.176.57]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id D5F2B80314 for ; Wed, 30 Mar 2022 12:06:17 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=rock-chips.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=kever.yang@rock-chips.com Received: from localhost.localdomain (unknown [58.22.7.114]) by mail-m17657.qiye.163.com (Hmail) with ESMTPA id 50B2B280386; Wed, 30 Mar 2022 18:06:03 +0800 (CST) From: Kever Yang To: u-boot@lists.denx.de Cc: Yi Liu , Kever Yang , Philipp Tomsich , Simon Glass Subject: [PATCH] tools: mkimage: No need to verify_header for header_v2 Date: Wed, 30 Mar 2022 18:05:59 +0800 Message-Id: <20220330100559.1482068-1-kever.yang@rock-chips.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-HM-Spam-Status: e1kfGhgUHx5ZQUtXWQgPGg8OCBgUHx5ZQUlOS1dZCBgUCR5ZQVlLVUtZV1 kWDxoPAgseWUFZKDYvK1lXWShZQUlKS0tKN1dZLVlBSVdZDwkaFQgSH1lBWUIfH0JWTEgdGkNDSR ofQhkfVRMBExYaEhckFA4PWVdZFhoPEhUdFFlBWU9LSFVKSkpLTkpVS1kG X-HM-Sender-Digest: e1kMHhlZQR0aFwgeV1kSHx4VD1lBWUc6ME06Qhw6PT5NDQ8dEg5NSBJI Ph0wCQtVSlVKTU9DTUhPTE1ITEtOVTMWGhIXVRAeDR4JVQIaFRw7CRQYEFYYExILCFUYFBZFWVdZ EgtZQVlOQ1VJSVVMVUpKT1lXWQgBWUFKTUxNNwY+ X-HM-Tid: 0a7fda4a18c0da03kuws50b2b280386 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.5 at phobos.denx.de X-Virus-Status: Clean From: Yi Liu rockchip header_v2 do not have a spl_hdr, so remove the verify. Signed-off-by: Yi Liu Signed-off-by: Kever Yang --- tools/rkcommon.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tools/rkcommon.c b/tools/rkcommon.c index 29f2676c19..ff62c75caa 100644 --- a/tools/rkcommon.c +++ b/tools/rkcommon.c @@ -450,6 +450,10 @@ int rkcommon_verify_header(unsigned char *buf, int size, struct spl_info *img_spl_info, *spl_info; int ret; + /* spl_hdr is abandon on header_v2 */ + if ((*(uint32_t *)buf) == RK_MAGIC_V2) + return 0; + ret = rkcommon_parse_header(buf, &header0, &img_spl_info); /* If this is the (unimplemented) RC4 case, then rewrite the result */ -- 2.25.1