Blob Blame History Raw
From: Ard Biesheuvel <ardb@kernel.org>
Date: Thu, 23 Jan 2020 09:17:48 +0100
Subject: scsi: iscsi: Use EFI GetVariable only when available
Patch-mainline: v5.7-rc1
Git-commit: 69f4cab134d204f0260d69ae407a2562e56a5025
References: bsc#1174029, bsc#1174110, bsc#1174111

Replace the EFI runtime services check with one that tells us whether
EFI GetVariable() is implemented by the firmware.

Cc: "James E.J. Bottomley" <jejb@linux.ibm.com>
Cc: "Martin K. Petersen" <martin.petersen@oracle.com>
Cc: linux-scsi@vger.kernel.org
Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Acked-by: Lee, Chun-Yi <jlee@suse.com>
---
 drivers/scsi/isci/init.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/scsi/isci/init.c
+++ b/drivers/scsi/isci/init.c
@@ -618,7 +618,7 @@ static int isci_pci_probe(struct pci_dev
 		return -ENOMEM;
 	pci_set_drvdata(pdev, pci_info);
 
-	if (efi_enabled(EFI_RUNTIME_SERVICES))
+	if (efi_rt_services_supported(EFI_RT_SUPPORTED_GET_VARIABLE))
 		orom = isci_get_efi_var(pdev);
 
 	if (!orom)