49 #define IBM_BOFM_DRIVER_CONFIGURATION_PROTOCOL_GUID \ 50 { 0x03207ce2, 0xd9c7, 0x11dc, \ 51 { 0xa9, 0x4d, 0x00, 0x19, 0x7d, 0x89, 0x02, 0x38 } } 53 #define IBM_BOFM_DRIVER_CONFIGURATION2_PROTOCOL_GUID \ 54 { 0xe82a9763, 0x0584, 0x4e41, \ 55 { 0xbb, 0x39, 0xe0, 0xcd, 0xb8, 0xc1, 0xf0, 0xfc } } 100 #define IBM_BOFM_TABLE BOFM_DataStructure_t 189 &bofm1.interface ) ) != 0 ) {
191 DBGC (
device,
"EFIBOFM %s cannot find BOFM protocol\n",
197 if ( ( efirc = bofm1.bofm1->RegisterSupport ( bofm1.bofm1,
device,
202 DBGC (
device,
"EFIBOFM %s could not register support: %s\n",
207 DBGC (
device,
"EFIBOFM %s has driver \"%s\"\n",
238 DBGC (
device,
"EFIBOFM %s cannot get PCI information: %s\n",
245 &efipci.
io ) ) != 0 ) {
246 DBGC (
device,
"EFIBOFM %s cannot open PCI device: %s\n",
253 &bofm1.interface ) ) != 0 ) {
255 DBGC (
device,
"EFIBOFM %s cannot find BOFM protocol\n",
257 goto err_locate_bofm;
259 bofmtab = &bofm1.bofm1->BofmTable;
260 DBGC (
device,
"EFIBOFM %s found version 1 BOFM table at %p+%04x\n",
265 &bofm2.interface ) ) == 0 ) {
266 bofmtab2 = &bofm2.bofm2->BofmTable;
267 DBGC (
device,
"EFIBOFM %s found version 2 BOFM table at " 269 bofmtab2->Parameters.Length );
270 assert ( bofm2.bofm2->RegisterSupport ==
271 bofm1.bofm1->RegisterSupport );
273 DBGC (
device,
"EFIBOFM %s cannot find BOFM2 protocol\n",
280 DBGC2 (
device,
"EFIBOFM %s version 1 before processing:\n",
284 DBGC2 (
device,
"EFIBOFM %s version 2 before processing:\n",
288 bofmrc =
bofm ( ( bofmtab2 ? bofmtab2 : bofmtab ), &efipci.
pci );
291 DBGC2 (
device,
"EFIBOFM %s version 1 after processing:\n",
295 DBGC2 (
device,
"EFIBOFM %s version 2 after processing:\n",
302 if ( ( efirc = bofm2.bofm2->SetStatus ( bofm2.bofm2,
device,
303 FALSE, bofmrc ) ) != 0){
305 DBGC (
device,
"EFIBOFM %s could not set BOFM2 " 311 if ( ( efirc = bofm1.bofm1->SetStatus ( bofm1.bofm1,
device,
312 FALSE, bofmrc ) ) != 0){
314 DBGC (
device,
"EFIBOFM %s could not set BOFM "
EFI_BOOT_SERVICES * BootServices
A pointer to the EFI Boot Services Table.
struct arbelprm_rc_send_wqe rc
#define EEFI(efirc)
Convert an EFI status code to an iPXE status code.
int efipci_info(EFI_HANDLE device, struct efi_pci_device *efipci)
Get EFI PCI device information.
#define IBM_BOFM_DRIVER_CONFIGURATION2_PROTOCOL_GUID
IBM_BOFM_DRIVER_CONFIGURATION_SUPPORT RegisterSupport
struct pci_device pci
PCI device.
EFI_LOCATE_PROTOCOL LocateProtocol
128 bit buffer containing a unique identifier value.
IBM_BOFM_DRIVER_CONFIGURATION_STATUS SetStatus
static void efi_bofm_stop(struct efi_device *efidev __unused)
Detach driver from device.
EFI_GUID efi_pci_io_protocol_guid
PCI I/O protocol GUID.
#define efi_open_unsafe(handle, protocol, interface)
Open protocol for unsafe persistent use.
BOFM_Parameters_t Parameters
static int efi_bofm_start(struct efi_device *efidev)
Attach driver to device.
IBM_BOFM_DRIVER_CONFIGURATION_SUPPORT RegisterSupport
EFI_HANDLE BOOLEAN ResetRequired
#define EFI_DRIVER_EARLY
Early drivers.
EFI_HANDLE device
EFI device handle.
void efi_close_unsafe(EFI_HANDLE handle, EFI_GUID *protocol)
Close protocol opened for unsafe persistent use.
IBM_BOFM_DRIVER_CONFIGURATION_STATUS2 SetStatus
IBM BladeCenter Open Fabric Manager (BOFM)
#define IBM_BOFM_DRIVER_CONFIGURATION_PROTOCOL_GUID
assert((readw(&hdr->flags) &(GTF_reading|GTF_writing))==0)
#define __unused
Declare a variable or data structure as unused.
struct efi_driver efi_bofm_driver __efi_driver(EFI_DRIVER_EARLY)
EFI BOFM driver.
static int efi_bofm_supported(EFI_HANDLE device)
Check if device is supported.
const char * efi_handle_name(EFI_HANDLE handle)
Get name of an EFI handle.
char * strerror(int errno)
Retrieve string representation of error number.
EFI_HANDLE UINT8 UINT8 iSCSI_Parameter_Version
unsigned long long UINT64
EFI_HANDLE ControllerHandle
#define EAGAIN
Resource temporarily unavailable.
EFI_PCI_IO_PROTOCOL * io
PCI I/O protocol.
int bofm(void *bofmtab, struct pci_device *pci)
Process BOFM table.
EFI_HANDLE UINT8 UINT8 UINT8 BOFM_Parameter_Version
static EFI_GUID bofm2_protocol_guid
BOFM2 protocol GUID.
typedef EFI_STATUS(EFIAPI *IBM_BOFM_DRIVER_CONFIGURATION_SUPPORT)(IN IBM_BOFM_DRIVER_CONFIGURATION_PROTOCOL *This
RETURN_STATUS EFI_STATUS
Function return status for EFI API.
static EFI_GUID bofm1_protocol_guid
BOFM1 protocol GUID.
struct pci_device_id * id
Driver device ID.
int bofm_find_driver(struct pci_device *pci)
Find BOFM driver for PCI device.
EFI_SYSTEM_TABLE * efi_systab
EFI_HANDLE BOOLEAN UINT8 BOFMReturnCode
EFI_HANDLE UINT8 SupporttedOptions
FILE_LICENCE(GPL2_OR_LATER_OR_UBDL)
#define NULL
NULL pointer (VOID *)