|
| | FILE_LICENCE (GPL2_OR_LATER_OR_UBDL) |
| | FILE_SECBOOT (PERMITTED) |
| int | efipci_read (struct pci_device *pci, unsigned long location, void *value) |
| | Read from PCI configuration space.
|
| int | efipci_write (struct pci_device *pci, unsigned long location, unsigned long value) |
| | Write to PCI configuration space.
|
| static __always_inline int | PCIAPI_INLINE (efi, pci_can_probe)(struct pci_device *pci __unused) |
| | Check if PCI bus probing is allowed.
|
| static __always_inline int | PCIAPI_INLINE (efi, pci_read_config_byte)(struct pci_device *pci |
| | Read byte from PCI configuration space via EFI.
|
| return | efipci_read (pci, EFIPCI_LOCATION(where, EFIPCI_WIDTH_BYTE), value) |
| static __always_inline int | PCIAPI_INLINE (efi, pci_read_config_word)(struct pci_device *pci |
| | Read word from PCI configuration space via EFI.
|
| return | efipci_read (pci, EFIPCI_LOCATION(where, EFIPCI_WIDTH_WORD), value) |
| static __always_inline int | PCIAPI_INLINE (efi, pci_read_config_dword)(struct pci_device *pci |
| | Read dword from PCI configuration space via EFI.
|
| return | efipci_read (pci, EFIPCI_LOCATION(where, EFIPCI_WIDTH_DWORD), value) |
| static __always_inline int | PCIAPI_INLINE (efi, pci_write_config_byte)(struct pci_device *pci |
| | Write byte to PCI configuration space via EFI.
|
| static __always_inline int | PCIAPI_INLINE (efi, pci_write_config_word)(struct pci_device *pci |
| | Write word to PCI configuration space via EFI.
|
| static __always_inline int | PCIAPI_INLINE (efi, pci_write_config_dword)(struct pci_device *pci |
| | Write dword to PCI configuration space via EFI.
|
iPXE PCI I/O API for EFI
Definition in file efi_pci_api.h.
| int efipci_read |
( |
struct pci_device * | pci, |
|
|
unsigned long | location, |
|
|
void * | value ) |
|
extern |
Read from PCI configuration space.
- Parameters
-
| pci | PCI device |
| location | Encoded offset and width |
- Return values
-
| value | Value |
| rc | Return status code |
Definition at line 307 of file efi_pci.c.
308 {
313
314
317
318
323 DBGC ( pci,
"EFIPCI " PCI_FMT " config read from offset %02lx "
327 }
328
329 return 0;
330}
struct _EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL
RETURN_STATUS EFI_STATUS
Function return status for EFI API.
struct arbelprm_rc_send_wqe rc
pseudo_bit_t value[0x00020]
static unsigned long efipci_address(struct pci_device *pci, unsigned long location)
Calculate EFI PCI configuration space address.
static int efipci_root_open(struct pci_device *pci, EFI_HANDLE *handle, EFI_PCI_ROOT_BRIDGE_IO_PROTOCOL **root)
Open EFI PCI root bridge I/O protocol for ephemeral use.
#define EFIPCI_OFFSET(_location)
#define EFIPCI_WIDTH(_location)
#define EEFI(efirc)
Convert an EFI status code to an iPXE status code.
#define PCI_FMT
PCI device debug message format.
#define PCI_ARGS(pci)
PCI device debug message arguments.
struct stp_switch root
Root switch.
char * strerror(int errno)
Retrieve string representation of error number.
References DBGC, EEFI, EFI_HANDLE, efipci_address(), EFIPCI_OFFSET, efipci_root_open(), EFIPCI_WIDTH, handle, PCI_ARGS, PCI_FMT, rc, root, strerror(), and value.
| int efipci_write |
( |
struct pci_device * | pci, |
|
|
unsigned long | location, |
|
|
unsigned long | value ) |
|
extern |
Write to PCI configuration space.
- Parameters
-
| pci | PCI device |
| location | Encoded offset and width |
| value | Value |
- Return values
-
Definition at line 340 of file efi_pci.c.
341 {
346
347
350
351
356 DBGC ( pci,
"EFIPCI " PCI_FMT " config write to offset %02lx "
360 }
361
362 return 0;
363}
References DBGC, EEFI, EFI_HANDLE, efipci_address(), EFIPCI_OFFSET, efipci_root_open(), EFIPCI_WIDTH, handle, PCI_ARGS, PCI_FMT, rc, root, strerror(), and value.
Referenced by PCIAPI_INLINE(), PCIAPI_INLINE(), and PCIAPI_INLINE().