From patchwork Thu Jun 26 14:23:33 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 32560 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-pd0-f199.google.com (mail-pd0-f199.google.com [209.85.192.199]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 9CE202066E for ; Thu, 26 Jun 2014 14:26:56 +0000 (UTC) Received: by mail-pd0-f199.google.com with SMTP id r10sf12364493pdi.2 for ; Thu, 26 Jun 2014 07:26:55 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:subject:date:message-id :in-reply-to:references:cc:precedence:list-id:list-unsubscribe :list-archive:list-post:list-help:list-subscribe:mime-version:sender :errors-to:x-original-sender:x-original-authentication-results :mailing-list:content-type:content-transfer-encoding; bh=BBoHUuyG+JUyhoXzhpoHWvclAPyIvPDvxNrOCggair8=; b=Ca1/eVIQRi9Un99NzBBvlTcxTxtQysFcjvmJociePeoubY3wDeXhBOrrhghQUxmoHj YgJRcDPFOlPyzOmJBdIVL0mr46uqDsoRg3ghLAvj1LswGyUVsrdXe/Lz6XIc/H1wNhqA SqlgbHOlUz64DPTWeHeDSqTtDE2hUGg6aCUXx9CXnRvy4XFgPgNMSz8ZY05ppEOB7UhS C8p0tIIBhQfXs4p1xk8Cu/ZSmKd8cAoQeBp93JAiyGnNj2eEy+/YgqOnKvH5EVTOsYSO mLY7UJBIfN2WjSltXPc1daNLaFQFuIZogM9Rs8NrhN3Ril84YC2UtAwJLLcXundvdbe5 YVqQ== X-Gm-Message-State: ALoCoQm+fM4FS2XcBSyMkALc/CP0cuDFUjiNtA5jm8fhXwWv36aalLRt3hDdnrorG2N6etvhqBTg X-Received: by 10.66.164.167 with SMTP id yr7mr8284745pab.15.1403792815568; Thu, 26 Jun 2014 07:26:55 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.48.112 with SMTP id n103ls246355qga.86.gmail; Thu, 26 Jun 2014 07:26:55 -0700 (PDT) X-Received: by 10.220.250.203 with SMTP id mp11mr13653406vcb.2.1403792815383; Thu, 26 Jun 2014 07:26:55 -0700 (PDT) Received: from mail-vc0-f175.google.com (mail-vc0-f175.google.com [209.85.220.175]) by mx.google.com with ESMTPS id cz8si4454813vcb.88.2014.06.26.07.26.55 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 26 Jun 2014 07:26:55 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.175 as permitted sender) client-ip=209.85.220.175; Received: by mail-vc0-f175.google.com with SMTP id hy4so3629382vcb.34 for ; Thu, 26 Jun 2014 07:26:55 -0700 (PDT) X-Received: by 10.52.248.146 with SMTP id ym18mr11469429vdc.8.1403792815269; Thu, 26 Jun 2014 07:26:55 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.221.37.5 with SMTP id tc5csp34259vcb; Thu, 26 Jun 2014 07:26:54 -0700 (PDT) X-Received: by 10.67.3.166 with SMTP id bx6mr21799101pad.7.1403792814502; Thu, 26 Jun 2014 07:26:54 -0700 (PDT) Received: from bombadil.infradead.org (bombadil.infradead.org. [2001:1868:205::9]) by mx.google.com with ESMTPS id rn13si10029234pab.178.2014.06.26.07.26.54 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 26 Jun 2014 07:26:54 -0700 (PDT) Received-SPF: none (google.com: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org does not designate permitted sender hosts) client-ip=2001:1868:205::9; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1X0AcH-0006MC-Jl; Thu, 26 Jun 2014 14:25:33 +0000 Received: from mail-we0-f176.google.com ([74.125.82.176]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1X0Aaz-0003sh-Eh for linux-arm-kernel@lists.infradead.org; Thu, 26 Jun 2014 14:24:17 +0000 Received: by mail-we0-f176.google.com with SMTP id u56so3644852wes.21 for ; Thu, 26 Jun 2014 07:23:46 -0700 (PDT) X-Received: by 10.180.90.233 with SMTP id bz9mr4692598wib.42.1403792626283; Thu, 26 Jun 2014 07:23:46 -0700 (PDT) Received: from ards-macbook-pro.local ([109.114.99.252]) by mx.google.com with ESMTPSA id jb16sm25046864wic.10.2014.06.26.07.23.44 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 26 Jun 2014 07:23:45 -0700 (PDT) From: Ard Biesheuvel To: matt.fleming@intel.com, x86@kernel.org Subject: [PATCH v2 1/5] efi/arm64: avoid EFI_ERROR as a generic return code Date: Thu, 26 Jun 2014 16:23:33 +0200 Message-Id: <1403792617-25792-2-git-send-email-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 1.8.3.2 In-Reply-To: <1403792617-25792-1-git-send-email-ard.biesheuvel@linaro.org> References: <1403792617-25792-1-git-send-email-ard.biesheuvel@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140626_072413_704068_D228E846 X-CRM114-Status: GOOD ( 10.36 ) X-Spam-Score: -0.7 (/) X-Spam-Report: SpamAssassin version 3.4.0 on bombadil.infradead.org summary: Content analysis details: (-0.7 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [74.125.82.176 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H3 RBL: Good reputation (+3) [74.125.82.176 listed in wl.mailspike.net] -0.0 SPF_PASS SPF: sender matches SPF record -0.0 RCVD_IN_MSPIKE_WL Mailspike good senders Cc: linux-efi@vger.kernel.org, Ard Biesheuvel , catalin.marinas@arm.com, msalter@redhat.com, leif.lindholm@linaro.org, roy.franz@linaro.org, hpa@zytor.com, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: ard.biesheuvel@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.175 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 As EFI_ERROR is not a UEFI result code but a local invention only intended to allow get_dram_base() to signal failure, we should not use it elsewhere. Replace with EFI_LOAD_ERROR. Signed-off-by: Ard Biesheuvel --- arch/arm64/kernel/efi-stub.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/kernel/efi-stub.c b/arch/arm64/kernel/efi-stub.c index e786e6cdc400..7aa7155a9740 100644 --- a/arch/arm64/kernel/efi-stub.c +++ b/arch/arm64/kernel/efi-stub.c @@ -69,7 +69,7 @@ static efi_status_t handle_kernel_image(efi_system_table_t *sys_table, if (*image_addr != (dram_base + TEXT_OFFSET)) { pr_efi_err(sys_table, "Failed to alloc kernel memory\n"); efi_free(sys_table, kernel_memsize, *image_addr); - return EFI_ERROR; + return EFI_LOAD_ERROR; } *image_size = kernel_memsize; }