2 * EFI application loader
4 * Copyright (c) 2017 Heinrich Schuchardt
6 * SPDX-License-Identifier: GPL-2.0+
10 #define _EFI_DRIVER_H 1
14 #include <efi_loader.h>
17 * Operations supported by an EFI driver with respect to the EFI uclass
19 * @protocol The GUID of the protocol which is consumed by the
20 * driver. This GUID is used by the EFI uclass in the
21 * supports() and start() methods of the
22 * EFI_DRIVER_BINDING_PROTOCOL.
23 * @child_protocol Protocol supported by the child handles generated by
25 * @bind Function called by the EFI uclass to attach the
26 * driver to EFI driver to a handle.
28 struct efi_driver_ops {
29 const efi_guid_t *protocol;
30 const efi_guid_t *child_protocol;
31 int (*bind)(efi_handle_t handle, void *interface);
35 * This structure adds internal fields to the driver binding protocol.
37 struct efi_driver_binding_extended_protocol {
38 struct efi_driver_binding_protocol bp;
39 const struct efi_driver_ops *ops;
42 #endif /* _EFI_DRIVER_H */