|
iPXE
|
EFI driver vetoes. More...
#include <stddef.h>#include <stdlib.h>#include <string.h>#include <errno.h>#include <ipxe/settings.h>#include <ipxe/pci.h>#include <ipxe/efi/efi.h>#include <ipxe/efi/Protocol/DriverBinding.h>#include <ipxe/efi/Protocol/LoadedImage.h>#include <ipxe/efi/Protocol/ComponentName.h>#include <ipxe/efi/Protocol/ComponentName2.h>#include <ipxe/efi/efi_veto.h>Go to the source code of this file.
Data Structures | |
| struct | efi_veto_candidate |
| A driver veto candidate. More... | |
| struct | efi_veto |
| A driver veto. More... | |
Functions | |
| FILE_LICENCE (GPL2_OR_LATER_OR_UBDL) | |
| static int | efi_veto_unload (struct efi_veto *veto) |
| Unload an EFI driver. More... | |
| static int | efi_veto_disconnect (struct efi_veto *veto) |
| Disconnect an EFI driver from all handles. More... | |
| static int | efi_veto_uninstall (struct efi_veto *veto) |
| Uninstall an EFI driver binding protocol. More... | |
| static int | efi_veto_close_protocol (struct efi_veto *veto, EFI_HANDLE handle, EFI_GUID *protocol) |
| Close protocol on handle potentially opened by an EFI driver. More... | |
| static int | efi_veto_close_handle (struct efi_veto *veto, EFI_HANDLE handle) |
| Close handle potentially opened by an EFI driver. More... | |
| static int | efi_veto_close (struct efi_veto *veto) |
| Close all remaining handles opened by an EFI driver. More... | |
| static int | efi_veto_destroy (struct efi_veto *veto) |
| Terminate an EFI driver with extreme prejudice. More... | |
| static int | efi_veto_driver (struct efi_veto *veto) |
| Veto an EFI driver. More... | |
| static int | efi_veto_ip4config (EFI_DRIVER_BINDING_PROTOCOL *binding __unused, EFI_LOADED_IMAGE_PROTOCOL *loaded __unused, const char *manufacturer, const CHAR16 *name) |
| Veto Ip4ConfigDxe driver on some platforms. More... | |
| static int | efi_veto_hp_xhci (EFI_DRIVER_BINDING_PROTOCOL *binding __unused, EFI_LOADED_IMAGE_PROTOCOL *loaded __unused, const char *manufacturer, const CHAR16 *name) |
| Veto HP XhciDxe driver. More... | |
| static int | efi_veto_vmware_uefipxebc (EFI_DRIVER_BINDING_PROTOCOL *binding __unused, EFI_LOADED_IMAGE_PROTOCOL *loaded __unused, const char *manufacturer, const CHAR16 *name) |
| Veto VMware UefiPxeBcDxe driver. More... | |
| static int | efi_veto_dhcp6 (EFI_DRIVER_BINDING_PROTOCOL *binding __unused, EFI_LOADED_IMAGE_PROTOCOL *loaded __unused, const char *manufacturer __unused, const CHAR16 *name) |
| Veto Dhcp6Dxe driver. More... | |
| static int | efi_veto_find (EFI_HANDLE driver, const char *manufacturer, struct efi_veto *veto) |
| Find driver veto, if any. More... | |
| void | efi_veto (void) |
| Remove any vetoed drivers. More... | |
Variables | |
| static struct efi_veto_candidate | efi_vetoes [] |
| Driver vetoes. More... | |
EFI driver vetoes.
Definition in file efi_veto.c.
| FILE_LICENCE | ( | GPL2_OR_LATER_OR_UBDL | ) |
|
static |
Unload an EFI driver.
| veto | Driver veto |
| rc | Return status code |
Definition at line 77 of file efi_veto.c.
References EFI_SYSTEM_TABLE::BootServices, DBGC, efi_veto::driver, EEFI, efi_handle_name(), efi_systab, efi_veto::image, rc, strerror(), and EFI_BOOT_SERVICES::UnloadImage.
Referenced by efi_veto_driver().
|
static |
Disconnect an EFI driver from all handles.
| veto | Driver veto |
| rc | Return status code |
Definition at line 103 of file efi_veto.c.
References AllHandles, EFI_SYSTEM_TABLE::BootServices, count, DBGC, DBGC2, efi_veto::driver, EEFI, efi_disconnect(), efi_handle_name(), efi_systab, EFI_BOOT_SERVICES::FreePool, handle, EFI_BOOT_SERVICES::LocateHandleBuffer, NULL, rc, and strerror().
Referenced by efi_veto_destroy().
|
static |
Uninstall an EFI driver binding protocol.
| veto | Driver veto |
| rc | Return status code |
Definition at line 151 of file efi_veto.c.
References EFI_SYSTEM_TABLE::BootServices, DBGC, DBGC2, efi_veto::driver, EEFI, efi_driver_binding_protocol_guid, efi_handle_name(), efi_open, efi_systab, NULL, rc, strerror(), and EFI_BOOT_SERVICES::UninstallMultipleProtocolInterfaces.
Referenced by efi_veto_destroy().
|
static |
Close protocol on handle potentially opened by an EFI driver.
| veto | Driver veto |
| handle | Potentially opened handle |
| protocol | Opened protocol |
| rc | Return status code |
Definition at line 191 of file efi_veto.c.
References EFI_OPEN_PROTOCOL_INFORMATION_ENTRY::AgentHandle, EFI_SYSTEM_TABLE::BootServices, EFI_BOOT_SERVICES::CloseProtocol, controller, EFI_OPEN_PROTOCOL_INFORMATION_ENTRY::ControllerHandle, count, DBGC, DBGC_EFI_OPENER, efi_veto::driver, EEFI, efi_guid_ntoa(), efi_handle_name(), efi_systab, EFI_BOOT_SERVICES::FreePool, handle, efi_veto::image, EFI_BOOT_SERVICES::OpenProtocolInformation, protocol, rc, and strerror().
Referenced by efi_veto_close_handle().
|
static |
Close handle potentially opened by an EFI driver.
| veto | Driver veto |
| handle | Potentially opened handle |
| rc | Return status code |
Definition at line 251 of file efi_veto.c.
References EFI_SYSTEM_TABLE::BootServices, count, DBGC, efi_veto::driver, EEFI, efi_handle_name(), efi_systab, efi_veto_close_protocol(), EFI_BOOT_SERVICES::FreePool, handle, protocol, EFI_BOOT_SERVICES::ProtocolsPerHandle, rc, and strerror().
Referenced by efi_veto_close().
|
static |
Close all remaining handles opened by an EFI driver.
| veto | Driver veto |
| rc | Return status code |
Definition at line 295 of file efi_veto.c.
References AllHandles, EFI_SYSTEM_TABLE::BootServices, count, DBGC, DBGC2, efi_veto::driver, EEFI, efi_handle_name(), efi_systab, efi_veto_close_handle(), EFI_BOOT_SERVICES::FreePool, handle, EFI_BOOT_SERVICES::LocateHandleBuffer, NULL, rc, and strerror().
Referenced by efi_veto_destroy().
|
static |
Terminate an EFI driver with extreme prejudice.
| veto | Driver veto |
| rc | Return status code |
Definition at line 338 of file efi_veto.c.
References DBGC, efi_veto::driver, efi_handle_name(), efi_veto_close(), efi_veto_disconnect(), efi_veto_uninstall(), and rc.
Referenced by efi_veto_driver().
|
static |
Veto an EFI driver.
| veto | Driver veto |
| rc | Return status code |
Definition at line 365 of file efi_veto.c.
References efi_veto_destroy(), efi_veto_unload(), and rc.
Referenced by efi_veto().
|
static |
Veto Ip4ConfigDxe driver on some platforms.
| binding | Driver binding protocol |
| loaded | Loaded image protocol |
| manufacturer | Manufacturer name, if present |
| name | Driver name, if present |
| vetoed | Driver is to be vetoed |
Definition at line 389 of file efi_veto.c.
References manufacturer, memcmp(), name, and strcmp().
|
static |
Veto HP XhciDxe driver.
| binding | Driver binding protocol |
| loaded | Loaded image protocol |
| manufacturer | Manufacturer name, if present |
| name | Driver name, if present |
| vetoed | Driver is to be vetoed |
Definition at line 420 of file efi_veto.c.
References pci_class_id::class, pci_driver::class, for_each_table_entry, manufacturer, memcmp(), name, PCI_CLASS, PCI_CLASS_SERIAL, PCI_CLASS_SERIAL_USB, PCI_CLASS_SERIAL_USB_XHCI, PCI_DRIVERS, and strcmp().
|
static |
Veto VMware UefiPxeBcDxe driver.
| binding | Driver binding protocol |
| loaded | Loaded image protocol |
| manufacturer | Manufacturer name, if present |
| name | Driver name, if present |
| vetoed | Driver is to be vetoed |
Definition at line 459 of file efi_veto.c.
References manufacturer, memcmp(), name, and strcmp().
|
static |
Veto Dhcp6Dxe driver.
| binding | Driver binding protocol |
| loaded | Loaded image protocol |
| manufacturer | Manufacturer name, if present |
| name | Driver name, if present |
| vetoed | Driver is to be vetoed |
Definition at line 487 of file efi_veto.c.
|
static |
Find driver veto, if any.
| driver | Driver binding handle |
| manufacturer | Manufacturer name, if present |
| veto | Driver veto to fill in |
| rc | Return status code |
Definition at line 530 of file efi_veto.c.
References DBGC, DBGC2, efi_component_name2_protocol_guid, efi_component_name_protocol_guid, efi_driver_binding_protocol_guid, efi_handle_name(), efi_loaded_image_protocol_guid, efi_open, efi_vetoes, _EFI_COMPONENT_NAME2_PROTOCOL::GetDriverName, EFI_LOADED_IMAGE_PROTOCOL::ImageBase, _EFI_DRIVER_BINDING_PROTOCOL::ImageHandle, EFI_LOADED_IMAGE_PROTOCOL::ImageSize, manufacturer, memset(), name, NULL, rc, strerror(), efi_veto_candidate::veto, and wtf.
Referenced by efi_veto().
| void efi_veto | ( | void | ) |
Remove any vetoed drivers.
Definition at line 614 of file efi_veto.c.
References EFI_SYSTEM_TABLE::BootServices, ByProtocol, count, DBGC, efi_veto::driver, EEFI, efi_driver_binding_protocol_guid, efi_handle_name(), efi_systab, efi_veto_driver(), efi_veto_find(), efi_vetoes, fetch_string_setting_copy(), free, EFI_BOOT_SERVICES::FreePool, EFI_BOOT_SERVICES::LocateHandleBuffer, manufacturer, NULL, rc, and strerror().
Referenced by efi_probe().
|
static |
Driver vetoes.
Definition at line 503 of file efi_veto.c.
Referenced by efi_veto(), and efi_veto_find().
1.8.15