From patchwork Wed Feb 16 01:49:51 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AKASHI Takahiro X-Patchwork-Id: 543038 Delivered-To: patch@linaro.org Received: by 2002:ac0:e142:0:0:0:0:0 with SMTP id r2csp969154imn; Tue, 15 Feb 2022 17:50:27 -0800 (PST) X-Google-Smtp-Source: ABdhPJya0KFVQ14GejK0lmiLbpQykAoYn6AK9LbT6lVvOVDM4ZkWpDCYZ4HcFZynbOGZHfvojxFK X-Received: by 2002:a17:906:848a:b0:6ce:b94d:b907 with SMTP id m10-20020a170906848a00b006ceb94db907mr562588ejx.310.1644976227633; Tue, 15 Feb 2022 17:50:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1644976227; cv=none; d=google.com; s=arc-20160816; b=oSqdN2It0QRqU9a/cPZQEN53UnWRzlYhj02UulskdTRMkGfV/pE51o7TDMx580ALQB Ti6064qQyU5lepQ6+OpNEmgHTBPrYLXn2PgVurb9+1iP5UrgeP0TAjJiS+l/DMN48er9 lavZkmJ8IAuWBJ8sqHMVmnb/z1fjBqy/pRKxoM3eHdVtlrSRQ13l+PvJVF1mESKo/xqI afsSKt0nRNBAdz2/Q/bM1iHxILExMIO+B339FqQw+IA586zvoPaeTfVyPn/efadJ9GI9 m17sYu8eOCTQb13g1BzsbbueHQEKa3BfwFSZnt2Mq4B7/BVOgJr0wjHPVaWBxNM5rj/X rTEQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from:dkim-signature; bh=RjW5JAuQZk44rs9kHlD83G/P0KL9IgN5urfBDVdBe9M=; b=Ad2XlS0mQG+SaAs6Uzq52YcmBEzHvPsF7PtdIy13FQGFLIcdUOm80rYBrGP8iqGGh+ CnR4gId0LurBkFhfIIp2HbCIakUqSVk6KVyCHrmYAHyNeHTzgyhrsLxC0VvEc/PjsXlL SgTzc6ATwegB0AFiXnN0ovio2/Tx03azpLsa4uNgMRA7F05Xd8nqhrOMd+ATZzW5Jlby Dzy0sD9W4yeGjm2IbJl3jOKuoj6b3PilYhcd67SOI4SG5g/xagrXgn+beDOZVBDJugge /Fq0LlajlLYf95v9Gtd8Ob31NX99zvW0prOMoQk4UxdA/8Ry9z8Y5E1kk5F6sZxI2jGO OM+A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=r5ZzD+9m; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [2a01:238:438b:c500:173d:9f52:ddab:ee01]) by mx.google.com with ESMTPS id u7si21676970eju.706.2022.02.15.17.50.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Feb 2022 17:50:27 -0800 (PST) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=r5ZzD+9m; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 2a01:238:438b:c500:173d:9f52:ddab:ee01 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 4E8F083754; Wed, 16 Feb 2022 02:50:23 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="r5ZzD+9m"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 5F0E38388F; Wed, 16 Feb 2022 02:50:21 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE, T_SCC_BODY_TEXT_LINE,T_SPF_TEMPERROR autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-pg1-x52c.google.com (mail-pg1-x52c.google.com [IPv6:2607:f8b0:4864:20::52c]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id CA860836BE for ; Wed, 16 Feb 2022 02:50:09 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=takahiro.akashi@linaro.org Received: by mail-pg1-x52c.google.com with SMTP id p23so805466pgj.2 for ; Tue, 15 Feb 2022 17:50:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=RjW5JAuQZk44rs9kHlD83G/P0KL9IgN5urfBDVdBe9M=; b=r5ZzD+9mk04TJ0jJw7U4Pg3YyPqWgG28/SFDqxuVpeUm1Y9Jz4+QYwsSMtKgVGdpek e5wOCTj1Y6T3PzfYoUv/LDjoHfOesGpQstHyjoNn20ljM5syiERo9QCASh+LcCAnD6AC WMot65DsOuglnjV1EvUZmFCrAxsh2kgw5Vnpmx5SVzA/gjOhUkGAfieuUqbWbTTmVx2+ E7mS0asKBnUCyVb7BBKmOHWjsBLdA/sMRDVF6eb7CG0LOAsglO9BXcMWtAbqAEPf/J4y za1xd31xpqZs2M7YBfRKmQYMroATFflFYPiEyG2cCRozkXNj2rMThiTkwVesTcp+XKot Hkwg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=RjW5JAuQZk44rs9kHlD83G/P0KL9IgN5urfBDVdBe9M=; b=XZGa8dyYva75qXRxNnhm7BkLnq6c33osRIoKnAiEDM1mc3MRPr9AAw668w341TGTW2 qYcnmbkFeZ1/m/H2seOqcy9pOA32GqiR02gNg1fDsVDESLcmVjeURpJR9515WZH4MxXz hBzYfDuHBk2IKbOW/ghPle6OT/bwRLJSVl3I635beidDj7mp0J5CJ+cZkdECi1JN6x+4 EznY6esbJEOKKmwS0nNYzHpxNw0gEgipZPYbMGns/xCMJu5GgbsJIWZEsH71EdLBze6x aXGtE4VqBUz3lDGIYRRnFFlCQeIP63FL6g9wgPJJMn/cIwqVh34Y1lGhbF+8kv1+X31g o96A== X-Gm-Message-State: AOAM531c0EaqBd80TSqTzVsdiuxD3EMe9s0T3/KP8J8E4LgmdansDIkY G65AfAY8uFuDthCqHKvS53IifA== X-Received: by 2002:a63:905:0:b0:35e:14cc:a9e0 with SMTP id 5-20020a630905000000b0035e14cca9e0mr328859pgj.429.1644976208154; Tue, 15 Feb 2022 17:50:08 -0800 (PST) Received: from localhost.localdomain ([2400:4050:c3e1:100:21fe:bed8:d751:b2c0]) by smtp.gmail.com with ESMTPSA id n5sm3766485pgt.22.2022.02.15.17.50.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Feb 2022 17:50:07 -0800 (PST) From: AKASHI Takahiro To: trini@konsulko.com, xypron.glpk@gmx.de Cc: u-boot@lists.denx.de, AKASHI Takahiro Subject: [PATCH] tools: mkeficapsule: remove duplicated code Date: Wed, 16 Feb 2022 10:49:51 +0900 Message-Id: <20220216014951.42724-1-takahiro.akashi@linaro.org> X-Mailer: git-send-email 2.33.0 MIME-Version: 1.0 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 That code is mistakenly duplicated due to copy-and-paste error. Just remove it. Fixes: CID 348360 Signed-off-by: AKASHI Takahiro Reviewed-by: Heinrich Schuchardt --- tools/mkeficapsule.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/tools/mkeficapsule.c b/tools/mkeficapsule.c index f7590e482f10..c118335b93bd 100644 --- a/tools/mkeficapsule.c +++ b/tools/mkeficapsule.c @@ -210,8 +210,6 @@ static int create_auth_data(struct auth_context *ctx) cert.size = file_size; ret = read_bin_file(ctx->key_file, &key.data, &file_size); - if (ret < 0) - return -1; if (ret < 0) return -1; if (file_size > UINT_MAX)