aboutsummaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorQuentin Schulz <quentin.schulz@cherry.de>2024-06-10 18:13:46 +0200
committerTom Rini <trini@konsulko.com>2024-06-18 10:41:15 -0600
commit512ed81e567e3dba05d92ce34e9fe2c4fb107373 (patch)
treef2fe05787fc32c3055cda3308caaa670ff234173 /lib
parentca4becc149e1a0063cc72a7bf071062d415bcaf6 (diff)
downloadu-boot-512ed81e567e3dba05d92ce34e9fe2c4fb107373.tar.gz
smbios: only look for a SYSINFO udevice if SYSINFO support is enabled
If SYSINFO support isn't enabled, it's a given that uclass_first_device for UCLASS_SYSINFO will not find anything, therefore let's skip the test entirely. This allows to get rid of the following debug message that may be confusing: Cannot find uclass for id 118: please add the UCLASS_DRIVER() declaration for this UCLASS_... id Signed-off-by: Quentin Schulz <quentin.schulz@cherry.de> Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'lib')
-rw-r--r--lib/smbios.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/smbios.c b/lib/smbios.c
index b190b010f30..a822acd48e9 100644
--- a/lib/smbios.c
+++ b/lib/smbios.c
@@ -571,7 +571,7 @@ ulong write_smbios_table(ulong addr)
int i;
ctx.node = ofnode_null();
- if (IS_ENABLED(CONFIG_OF_CONTROL)) {
+ if (IS_ENABLED(CONFIG_OF_CONTROL) && CONFIG_IS_ENABLED(SYSINFO)) {
uclass_first_device(UCLASS_SYSINFO, &ctx.dev);
if (ctx.dev)
parent_node = dev_read_subnode(ctx.dev, "smbios");