From: Tobias Waldekranz <tobias@waldekranz.com>
To: barebox@lists.infradead.org
Subject: [PATCH] efi: fix probing of EFI devices with parents
Date: Wed, 13 Aug 2025 23:40:45 +0200 [thread overview]
Message-ID: <20250813214103.254178-1-tobias@waldekranz.com> (raw)
The refactor in the referenced commit sends in the match function as
the context data - instead of the handle we are looking for.
This meant that efi_find_device() always returned NULL, leading to all
EFI devices with parent handles not being probed.
Fix this by sending in the handle instead.
Fixes: 4a5a9b58b568 ("drive: bus: make use of new bus_find_device helper")
Signed-off-by: Tobias Waldekranz <tobias@waldekranz.com>
---
drivers/efi/efi-device.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/efi/efi-device.c b/drivers/efi/efi-device.c
index 0e6f75659f..f0e22bd140 100644
--- a/drivers/efi/efi-device.c
+++ b/drivers/efi/efi-device.c
@@ -40,8 +40,7 @@ static struct efi_device *efi_find_device(efi_handle_t handle)
{
struct device *dev;
- dev = bus_find_device(&efi_bus, NULL, efi_device_match_handle,
- efi_device_match_handle);
+ dev = bus_find_device(&efi_bus, NULL, handle, efi_device_match_handle);
if (dev)
return container_of(dev, struct efi_device, dev);
--
2.43.0
next reply other threads:[~2025-08-13 21:45 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-13 21:40 Tobias Waldekranz [this message]
2025-08-14 7:16 ` Ahmad Fatoum
2025-08-14 10:54 ` Sascha Hauer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250813214103.254178-1-tobias@waldekranz.com \
--to=tobias@waldekranz.com \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox