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 mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 34EB9C433F5 for ; Thu, 4 Nov 2021 03:13:29 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id A367260EDF for ; Thu, 4 Nov 2021 03:13:28 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org A367260EDF Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id B1F96836E5; Thu, 4 Nov 2021 04:11:13 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="crLSxy/7"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id BD79D8366D; Thu, 4 Nov 2021 04:10:40 +0100 (CET) Received: from mail-oi1-x231.google.com (mail-oi1-x231.google.com [IPv6:2607:f8b0:4864:20::231]) (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 C4AF783668 for ; Thu, 4 Nov 2021 04:10:14 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-oi1-x231.google.com with SMTP id d12so3574446oij.5 for ; Wed, 03 Nov 2021 20:10:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=YO7cMY6/sanF11PWw/CQ7iLSToNnJkoMIyTnfuBNS8o=; b=crLSxy/7DLohtoILFrRHf8P0atCYtzhf8hGqx5cEJ2toCOhZ3x1K5LZmCOybs+0M+1 H85rqRVHcnAZFDXF8SArFjzby0v0iTARkTBP24Nv04oMJtdDcd2Yw/1yqtDNx+EuqiCl I/0+eQ+f+7oYDtBWDMpoeWvoem62Tly7fcVUo= 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=YO7cMY6/sanF11PWw/CQ7iLSToNnJkoMIyTnfuBNS8o=; b=AJUdhyXYXNABJAQnZ8HjTir0XuQr/z682jUzFqNXkKHEB3sxE584Z/wrFa0FWo7Lg2 lmiKcKMRTtbeYWubYpE0UPq6+vAcdYZlI7lKEnvMtBNpoj1FTy95hMkyaHmFaYMpPb0I ioooIofcxwiVix758+XMpi4rNS5WgxAGQcL7PHf9xZliLKU7IdplXAUxVuejeGeIJnBZ VR6EqMyKSRhsJW+nwzGDGEzvpChGHrDIIqaFtq4hqE17kQrb3K+6rIbaaC4XwfAEezY7 7ndf66HGWy0YbxAT4gjaDQHiiLVBYMzR+Lw15VoVvPYGNTfcW6ocApqLMhVmwDT/k4ry eidQ== X-Gm-Message-State: AOAM532UKblIxOdfavcINpfoofyIPEwAjxjofUTL+XHzCNN8d8Q3cShS 6cpY+rK4TgponnoeH42X3PlDDp4WNadQNA== X-Google-Smtp-Source: ABdhPJwirkaK6jABp1UwB1rEqtTXwnQpUiGZjWHFhzTqfXORHx/gSsh5/ce0ErvZz6EzcDVMtJltjQ== X-Received: by 2002:aca:adc4:: with SMTP id w187mr480671oie.17.1635995413265; Wed, 03 Nov 2021 20:10:13 -0700 (PDT) Received: from kiwi.bld.corp.google.com (c-67-190-101-114.hsd1.co.comcast.net. [67.190.101.114]) by smtp.gmail.com with ESMTPSA id j25sm1050197oos.23.2021.11.03.20.10.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Nov 2021 20:10:12 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Ilias Apalodimas , Tom Rini , Christian Melki , Heinrich Schuchardt , Bin Meng , Simon Glass , Alexander Graf Subject: [PATCH v4 28/34] efi: Check for failure when initing the app Date: Wed, 3 Nov 2021 21:09:30 -0600 Message-Id: <20211104030936.2446706-18-sjg@chromium.org> X-Mailer: git-send-email 2.34.0.rc0.344.g81b53c2807-goog In-Reply-To: <20211104030936.2446706-1-sjg@chromium.org> References: <20211104030936.2446706-1-sjg@chromium.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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.2 at phobos.denx.de X-Virus-Status: Clean The stub checks for failure with efi_init(). Add this for the app as well. It is unlikely that anything can be done, but we may as well stop. Signed-off-by: Simon Glass --- (no changes since v1) lib/efi/efi_app.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/efi/efi_app.c b/lib/efi/efi_app.c index 23a65c46fd4..e454f1a1564 100644 --- a/lib/efi/efi_app.c +++ b/lib/efi/efi_app.c @@ -325,8 +325,11 @@ efi_status_t EFIAPI efi_main(efi_handle_t image, efi_status_t ret; /* Set up access to EFI data structures */ - efi_init(priv, "App", image, sys_table); - + ret = efi_init(priv, "App", image, sys_table); + if (ret) { + printf("Failed to set up ARP: err=%lx\n", ret); + return ret; + } efi_set_priv(priv); /* -- 2.34.0.rc0.344.g81b53c2807-goog