diff options
author | Michael Olbrich <m.olbrich@pengutronix.de> | 2017-03-11 17:07:33 +0100 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2017-03-30 08:23:19 +0200 |
commit | 1f1fcf24cf5fcaf269607b69bd37f8bdfa937487 (patch) | |
tree | 7349d78c544c1364cecf34a21dec43ccceb6195c /drivers/efi | |
parent | 3e1af511f06021e138132f227a1746f44bbe8e31 (diff) | |
download | barebox-1f1fcf24cf5fcaf269607b69bd37f8bdfa937487.tar.gz barebox-1f1fcf24cf5fcaf269607b69bd37f8bdfa937487.tar.xz |
efi: only iterate over handles that provide the device path protocol
All other handled are skipped anyways.
Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'drivers/efi')
-rw-r--r-- | drivers/efi/efi-device.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/efi/efi-device.c b/drivers/efi/efi-device.c index 7ab62a763a..e9b03cb02a 100644 --- a/drivers/efi/efi-device.c +++ b/drivers/efi/efi-device.c @@ -101,7 +101,8 @@ static efi_handle_t *efi_find_parent(efi_handle_t *handle) struct efi_open_protocol_information_entry *entry_buffer; unsigned long entry_count; - ret = efi_locate_handle(all_handles, NULL, NULL, &handle_count, &handles); + ret = efi_locate_handle(by_protocol, &efi_device_path_protocol_guid, + NULL, &handle_count, &handles); if (ret) return NULL; @@ -243,7 +244,8 @@ void efi_register_devices(void) struct efi_device **efidevs; int registered; - ret = efi_locate_handle(all_handles, NULL, NULL, &handle_count, &handles); + ret = efi_locate_handle(by_protocol, &efi_device_path_protocol_guid, + NULL, &handle_count, &handles); if (ret) return; |