|
iPXE
|
Device model. More...
Go to the source code of this file.
Data Structures | |
| struct | device_description |
| A hardware device description. More... | |
| struct | device |
| A hardware device. More... | |
| struct | root_device |
| A root device. More... | |
| struct | root_driver |
| A root device driver. More... | |
Macros | |
| #define | BUS_TYPE_PCI 1 |
| PCI bus type. | |
| #define | BUS_TYPE_ISAPNP 2 |
| ISAPnP bus type. | |
| #define | BUS_TYPE_EISA 3 |
| EISA bus type. | |
| #define | BUS_TYPE_MCA 4 |
| MCA bus type. | |
| #define | BUS_TYPE_ISA 5 |
| ISA bus type. | |
| #define | BUS_TYPE_TAP 6 |
| TAP bus type. | |
| #define | BUS_TYPE_EFI 7 |
| EFI bus type. | |
| #define | BUS_TYPE_XEN 8 |
| Xen bus type. | |
| #define | BUS_TYPE_HV 9 |
| Hyper-V bus type. | |
| #define | BUS_TYPE_USB 10 |
| USB bus type. | |
| #define | BUS_TYPE_DT 11 |
| Devicetree bus type. | |
| #define | ROOT_DEVICES __table ( struct root_device, "root_devices" ) |
| Root device table. | |
| #define | __root_device __table_entry ( ROOT_DEVICES, 01 ) |
| Declare a root device. | |
| #define | identify_device_TYPE(object_type) |
Functions | |
| FILE_LICENCE (GPL2_OR_LATER_OR_UBDL) | |
| FILE_SECBOOT (PERMITTED) | |
| static void | rootdev_set_drvdata (struct root_device *rootdev, void *priv) |
| Set root device driver-private data. | |
| static void * | rootdev_get_drvdata (struct root_device *rootdev) |
| Get root device driver-private data. | |
| static void | devices_get (void) |
| Prevent devices from being removed on shutdown. | |
| static void | devices_put (void) |
| Allow devices to be removed on shutdown. | |
| struct device * | identify_device (struct interface *intf) |
| Identify a device behind an interface. | |
Variables | |
| int | device_keep_count |
| Device removal inhibition counter. | |
Device model.
Definition in file device.h.
| #define BUS_TYPE_PCI 1 |
PCI bus type.
Definition at line 44 of file device.h.
Referenced by ehci_poll_companions(), int13_device_path_info(), netdev_fetch_bustype(), pci_autoboot_init(), pci_read_config(), pxenv_start_undi(), pxenv_undi_get_nic_type(), uhci_root_speed(), undibus_probe(), and undinet_irq_is_broken().
| #define BUS_TYPE_ISAPNP 2 |
ISAPnP bus type.
Definition at line 47 of file device.h.
Referenced by isapnpbus_probe(), netdev_fetch_bustype(), pxenv_start_undi(), pxenv_undi_get_nic_type(), and undibus_probe().
| #define BUS_TYPE_EISA 3 |
EISA bus type.
Definition at line 50 of file device.h.
Referenced by eisabus_probe(), and netdev_fetch_bustype().
| #define BUS_TYPE_MCA 4 |
MCA bus type.
Definition at line 53 of file device.h.
Referenced by mcabus_probe(), and netdev_fetch_bustype().
| #define BUS_TYPE_ISA 5 |
ISA bus type.
Definition at line 56 of file device.h.
Referenced by isabus_probe(), netdev_fetch_bustype(), and t509bus_probe().
| #define BUS_TYPE_TAP 6 |
| #define BUS_TYPE_EFI 7 |
EFI bus type.
Definition at line 62 of file device.h.
Referenced by efi_device_info(), efidev_alloc(), and netdev_fetch_bustype().
| #define BUS_TYPE_XEN 8 |
Xen bus type.
Definition at line 65 of file device.h.
Referenced by netdev_fetch_bustype(), and xenbus_probe_device().
| #define BUS_TYPE_HV 9 |
Hyper-V bus type.
Definition at line 68 of file device.h.
Referenced by netdev_fetch_bustype(), and vmbus_probe_channels().
| #define BUS_TYPE_USB 10 |
USB bus type.
Definition at line 71 of file device.h.
Referenced by netdev_fetch_bustype(), and usb_probe_all().
| #define BUS_TYPE_DT 11 |
Devicetree bus type.
Definition at line 74 of file device.h.
Referenced by dt_probe_node(), and netdev_fetch_bustype().
| #define ROOT_DEVICES __table ( struct root_device, "root_devices" ) |
| #define __root_device __table_entry ( ROOT_DEVICES, 01 ) |
| #define identify_device_TYPE | ( | object_type | ) |
Definition at line 178 of file device.h.
Referenced by identify_device().
| FILE_LICENCE | ( | GPL2_OR_LATER_OR_UBDL | ) |
| FILE_SECBOOT | ( | PERMITTED | ) |
|
inlinestatic |
Set root device driver-private data.
| rootdev | Root device |
| priv | Private data |
Definition at line 144 of file device.h.
References priv, and root_device::priv.
Referenced by hv_probe(), and hv_remove().
|
inlinestatic |
Get root device driver-private data.
| rootdev | Root device |
| priv | Private data |
Definition at line 155 of file device.h.
References root_device::priv.
Referenced by hv_quiesce(), hv_remove(), and hv_unquiesce().
|
inlinestatic |
Prevent devices from being removed on shutdown.
Definition at line 165 of file device.h.
References device_keep_count.
Referenced by int13_hook(), and pxe_activate().
|
inlinestatic |
Allow devices to be removed on shutdown.
Definition at line 173 of file device.h.
References device_keep_count.
Referenced by int13_unhook(), and pxe_deactivate().
Identify a device behind an interface.
| intf | Interface |
| device | Device, or NULL |
Definition at line 126 of file device.c.
References dest, identify_device(), identify_device_TYPE, interface::intf, intf_get_dest_op, intf_object(), intf_put(), NULL, and op.
Referenced by fcpdev_identify_device(), identify_device(), and int13_device_path_info().
|
extern |
Device removal inhibition counter.
Definition at line 45 of file device.c.
Referenced by devices_get(), devices_put(), and remove_devices().