Re: [PATCH 1/1] arch/x86: Add better error logging to efi main

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 10 Jul, at 02:12:41AM, ulf@xxxxxxxxxxxx wrote:
> @@ -1376,7 +1376,10 @@ struct boot_params *efi_main(struct efi_config *c,
> 
> 	setup_graphics(boot_params);
> 
> -	setup_efi_pci(boot_params);
> +	status = setup_efi_pci(boot_params);
> +	if (status != EFI_SUCCESS) {
> +		efi_printk(sys_table, "setup_efi_pci() failed!\n");
> +	}
 
Actually, it turns out that a lot of people are seeing this error
message in what would be an otherwise quiet boot,

  https://bugzilla.kernel.org/show_bug.cgi?id=81891

Maybe we should distinguish between EFI_PCI_IO_PROTOCOL_GUID not being
found and all other errors, i.e. memory allocation failure. We obviously
do want to know if we failed to allocate memory, but we're less bothered
if we've no PCI devices.

Something like below? Folks on Cc, could you apply this snippet and see
whether you're still seeing the error message?

---

diff --git a/arch/x86/boot/compressed/eboot.c b/arch/x86/boot/compressed/eboot.c
index f4bdab1dbf66..37743459d089 100644
--- a/arch/x86/boot/compressed/eboot.c
+++ b/arch/x86/boot/compressed/eboot.c
@@ -534,8 +534,15 @@ static efi_status_t setup_efi_pci(struct boot_params *params)
 					NULL, &size, pci_handle);
 	}
 
-	if (status != EFI_SUCCESS)
+	if (status != EFI_SUCCESS) {
+		/*
+		 * We must have encountered a non-fatal error condition,
+		 * such as being unable to locate pci_proto. Return, but
+		 * don't report an error.
+		 */
+		status = EFI_SUCCESS;
 		goto free_handle;
+	}
 
 	if (efi_early->is64)
 		status = setup_efi_pci64(params, pci_handle, size);

-- 
Matt Fleming, Intel Open Source Technology Center
--
To unsubscribe from this list: send the line "unsubscribe linux-efi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux