From patchwork Wed Feb 15 02:32:17 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Masahisa Kojima X-Patchwork-Id: 653686 Delivered-To: patch@linaro.org Received: by 2002:adf:f90f:0:0:0:0:0 with SMTP id b15csp91652wrr; Tue, 14 Feb 2023 18:31:23 -0800 (PST) X-Google-Smtp-Source: AK7set+kwr5yETs00tdM2cOjcDti0a404N72wp08c2XkSTXd4/QV3PICFpAiqnVY8rRezu+xUboV X-Received: by 2002:aca:1017:0:b0:37b:749b:5910 with SMTP id 23-20020aca1017000000b0037b749b5910mr152437oiq.2.1676428283653; Tue, 14 Feb 2023 18:31:23 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1676428283; cv=none; d=google.com; s=arc-20160816; b=yfnEeRpCqVLD2hyOgBb3j0aoPZeojnKiEJCDeaB61AeJtP2z5h+QFKxwMAFYxuMk/2 lJeGFT4wQ3OIKNpE4IhiUTO0uSHE0pzwOmkbs3N0IX+lb7OHQssXa5I/p1NnT71GKd9a I1o9b65Wbar3haBI2dsXChJ9odJtwJ0IF7XbtZeIFhC6ZX1dY4bZSqxIwOeqW7pl2l6k T009El0BP70M2Z1X/8YcrI5rBkdMYi76fVnk+1zfnE4vyQFGuOpNPT6XMDnAPyd3mVzE ROKqJhMivolQP0qPZ7SRt9jK7VraxLbjDktGQID7nD/5ap0ZWcycIN4VSg5beQ4bZ1mc i19A== 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:message-id:date:subject:cc:to :from:dkim-signature; bh=Bp86ZpZejTvqqXnnRDYw3lFNhcrDAFEyM0hR7mDXYs4=; b=JJLKniGxrA942FMy+nLLNhcfE6a/Vq0IcnAULV/IG3a5/5obwdO8vB21/ygDdGmn8L Va6pNoyk1fJZftGEev0CO/5XmzJOq/tW2TlDGPmpNtvc1kVdT72QjNOqeDCHyTYOrLTY Q7EOrmXHSCGcmrX0Ktl+P64reOViogZW8znF2RWSe/iLpQAaLxpLzqB0WISpv3rdVmrq +t5fM9Ftz2UuwRorGR5q6N6c/AkGLw1M5ofpn10Es947W50xnHcfevtHJbFFDLcmneKb MOw1AAojoGxk1QPHZlH6tcg3Qplj92c99ZgoP9xbKAy95k00zFHVO+zUWpxcjKH6T/Fa zVOw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=oaBemI8Z; 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 a13-20020a056808128d00b00364c74faf59si18185649oiw.236.2023.02.14.18.31.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 14 Feb 2023 18:31:23 -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=oaBemI8Z; 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 30715859E3; Wed, 15 Feb 2023 03:31:19 +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="oaBemI8Z"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id AF734859AF; Wed, 15 Feb 2023 03:31:16 +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,SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-pj1-x102c.google.com (mail-pj1-x102c.google.com [IPv6:2607:f8b0:4864:20::102c]) (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 B8FA6859E3 for ; Wed, 15 Feb 2023 03:31:13 +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=masahisa.kojima@linaro.org Received: by mail-pj1-x102c.google.com with SMTP id d13-20020a17090ad3cd00b0023127b2d602so609190pjw.2 for ; Tue, 14 Feb 2023 18:31:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Bp86ZpZejTvqqXnnRDYw3lFNhcrDAFEyM0hR7mDXYs4=; b=oaBemI8ZU3hjvsLYe+SCjBbov7yrmLPTTAuhoaqy+tpZ2e/xmNBHxP265HsG6W4Zp1 XZWtJ3vlLmbZ2bLY7pacepIH8Iau8+PrGNw6QpskNQjxfvM+maF2Tqt4cpB4j1NiAujN rzSb22syIBm4sLfwetTH2L9Pl08O8iNbwcJ3FWfNvISK/P/NFQhUJ37TG1OD1rMYNZaE jD+H2SKKKlLQkXCJ9iA3bKRQ+yP4ERbiQs2nd3xv50j8bxf5sDL9SX+2Uu7xGTMKgx4j LsoIg5gubKLoDSNP9z1fYr3NxGOyxHxsfIwVTPO+Oeu5ZIR2JDyQvARqrUAkxEfHxn6d Rv6w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Bp86ZpZejTvqqXnnRDYw3lFNhcrDAFEyM0hR7mDXYs4=; b=znE8CdrmMSciKWv2Q4J0YXaiOfMwZEehWatPVnC5Bv6tni7bgvimfyaf6X41LpshXo r6z0jl0nc/KUhw+mE9GkTHezvBlPYDhFipaZTidcUz3lW7fQzPdTxn6OPwZtnKD73E5k y+Skyv/E7JnnGoq2KURFh2jlhYONFdE4NFs7C4YunTqM5guknZ20dvCB/KiJemni2UiM neno1Q3Yw+e+9EH3Bh94U0BRpE1e82AVo9nhsOmhK3x8t6uX+Db55VTz2P5f9r6AmnCo aI/rgAK+yriaQQc2nbkgpLasapjr6H6kpENXcycHe+jZzBWevhfT4HR4uTlESh7dImW6 9mMw== X-Gm-Message-State: AO0yUKWk/kt//MjQlgNc+0mj5BIvA++E2++TXgpTz1Zscqs8foUJ5qf5 OcGRjpFS8r9OGTP8Kc6Tg7Y4MmtYGYUzzwDJYMg= X-Received: by 2002:a17:902:ced1:b0:19a:8494:c17f with SMTP id d17-20020a170902ced100b0019a8494c17fmr652747plg.61.1676428271850; Tue, 14 Feb 2023 18:31:11 -0800 (PST) Received: from localhost.localdomain ([240d:1a:cf7:5800:82fa:5bff:fe4b:26b1]) by smtp.gmail.com with ESMTPSA id v6-20020a1709028d8600b0019906c4c9dcsm10836486plo.98.2023.02.14.18.31.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 14 Feb 2023 18:31:11 -0800 (PST) From: Masahisa Kojima To: u-boot@lists.denx.de Cc: Heinrich Schuchardt , Ilias Apalodimas , Masahisa Kojima Subject: [PATCH] efi_loader: fix wrong attribute check for QueryVariableInfo Date: Wed, 15 Feb 2023 11:32:17 +0900 Message-Id: <20230215023218.8477-1-masahisa.kojima@linaro.org> X-Mailer: git-send-email 2.17.1 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.6 at phobos.denx.de X-Virus-Status: Clean QueryVariableInfo with EFI_VARIABLE_HARDWARE_ERROR_RECORD is accepted, remove wrong attribute check. Fixes: 454a9442fbce ("efi_loader: update attribute check for QueryVariableInfo()") Signed-off-by: Masahisa Kojima Reviewed-by: Heinrich Schuchardt --- lib/efi_loader/efi_variable.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/lib/efi_loader/efi_variable.c b/lib/efi_loader/efi_variable.c index b12e79d658..f1d967cd0e 100644 --- a/lib/efi_loader/efi_variable.c +++ b/lib/efi_loader/efi_variable.c @@ -385,9 +385,6 @@ efi_status_t efi_query_variable_info_int(u32 attributes, EFI_VARIABLE_RUNTIME_ACCESS) return EFI_INVALID_PARAMETER; - if (attributes & EFI_VARIABLE_HARDWARE_ERROR_RECORD) - return EFI_UNSUPPORTED; - if (attributes & ~(u32)EFI_VARIABLE_MASK) return EFI_INVALID_PARAMETER;