[U-Boot] [PATCH v3 00/16] efi_loader: implement driver management
Heinrich Schuchardt
xypron.glpk at gmx.de
Thu Jan 11 07:15:53 UTC 2018
This series implements the OpenProtocolInformation, ConnectController,
and DisconnectController boot services.
The EFI application creating a new device will call ConnectController
to request the installation of all necessary drivers. Before
deleting the device it will call DisconectController to remove all
child controllers and to detach the driver.
E.g. iPXE may be used to connect an iSCSI target. It then creates a
handle by installing the EFI_BLOCK_IO_PROTOCOL. It calls
ConnectController and expects U-Boot to create the partition handles
and to provide the EFI_SIMPLE_FILE_SYSTEM_PROTOCOL. (The driver
connecting to the EFI_BLOCK_IO_PROTOCOL is not yet implemented in
U-Boot.)
A self test is provided for the driver management.
The bootefi selftest now creates colored output.
Two bug fixes are included.
To complete the implementation of the EFI boot services the following
future work is needed:
* manage events in a linked list (see Rob's proposal)
* implement ReinstallProtocol and RegisterProtocolNotify
---
v3:
Add more comments to code.
Avoid memory leak when debug printing device path.
v2:
Clean up debug output in efi_add_protocol (patch 8).
Correctly return EFI_NOT_FOUND if no driver is uninstalled in
DisconnectController (patch 11).
Define a local structure as static (patch 15).
Heinrich Schuchardt (16):
efi_selftest: colored test output
efi_loader: simplify efi_remove_all_protocols
efi_selftest: do not try to close device path protocol
efi_loader: list of open protocol infos
efi_loader: open_info in OpenProtocol
efi_loader: open_info in CloseProtocol
efi_loader: implement OpenProtocolInformation
efi_loader: debug output installed device path
efi_loader: implement ConnectController
efi_loader: fix signature of efi_disconnect_controller
efi_loader: implement DisconnectController
efi_loader: disconnect controllers in UninstallProtocol
efi_selftest: remove todo in manage protocols
efi_selftest: remove todo in device path test
efi_selftest: test for (Dis)ConnectController
efi_loader: consistently use efi_handle_t for handles
cmd/bootefi.c | 10 +-
include/efi_api.h | 48 +-
include/efi_loader.h | 38 +-
include/efi_selftest.h | 27 +-
lib/efi_loader/efi_boottime.c | 763 +++++++++++++++++++++---
lib/efi_loader/efi_console.c | 6 +-
lib/efi_selftest/Makefile | 1 +
lib/efi_selftest/efi_selftest.c | 25 +-
lib/efi_selftest/efi_selftest_console.c | 13 +-
lib/efi_selftest/efi_selftest_controllers.c | 385 ++++++++++++
lib/efi_selftest/efi_selftest_devicepath.c | 48 +-
lib/efi_selftest/efi_selftest_manageprotocols.c | 22 +-
12 files changed, 1219 insertions(+), 167 deletions(-)
create mode 100644 lib/efi_selftest/efi_selftest_controllers.c
--
2.14.2
More information about the U-Boot
mailing list