[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20241125145848.506347-3-yeoreum.yun@arm.com>
Date: Mon, 25 Nov 2024 14:58:48 +0000
From: Yeoreum Yun <yeoreum.yun@....com>
To: catalin.marinas@....com,
will@...nel.org,
broonie@...nel.org,
sudeep.holla@....com,
guohanjun@...wei.com,
gshan@...hat.com,
prarit@...hat.com,
Jonathan.Cameron@...wei.com,
dwmw@...zon.co.uk,
ardb@...nel.org,
hagarhem@...zon.com
Cc: linux-arm-kernel@...ts.infradead.org,
linux-efi@...r.kernel.org,
linux-kernel@...r.kernel.org,
nd@....com,
Yeoreum Yun <yeoreum.yun@....com>
Subject: [PATCH 2/2] efi/fdt: ignore dtb when acpi option is used with force
Since acpi=force doesn't use dt fallback, it's meaningless to load dt
from comaand line option or from configuration table.
Skip loading dt when acpi=force option is used.
otherwise it could produce unnecessary error message
while scanning dt if passed dt's format is invalid.
Signed-off-by: Yeoreum Yun <yeoreum.yun@....com>
---
drivers/firmware/efi/libstub/fdt.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/drivers/firmware/efi/libstub/fdt.c b/drivers/firmware/efi/libstub/fdt.c
index 6a337f1f8787..04a054393d87 100644
--- a/drivers/firmware/efi/libstub/fdt.c
+++ b/drivers/firmware/efi/libstub/fdt.c
@@ -251,11 +251,13 @@ efi_status_t allocate_new_fdt_and_exit_boot(void *handle,
if (strstr(cmdline_ptr, "dtb="))
efi_err("Ignoring DTB from command line.\n");
} else {
- status = efi_load_dtb(image, &fdt_addr, &fdt_size);
+ if (!strstr(cmdline_ptr, "acpi=force")) {
+ status = efi_load_dtb(image, &fdt_addr, &fdt_size);
- if (status != EFI_SUCCESS && status != EFI_NOT_READY) {
- efi_err("Failed to load device tree!\n");
- goto fail;
+ if (status != EFI_SUCCESS && status != EFI_NOT_READY) {
+ efi_err("Failed to load device tree!\n");
+ goto fail;
+ }
}
}
--
LEVI:{C3F47F37-75D8-414A-A8BA-3980EC8A46D7}
Powered by blists - more mailing lists