100 path = ( ( (
void * ) path ) +
147 return ( ( (
void * )
end ) - ( (
void * ) path ) );
166 return &
mac->MacAddress;
259 len = ( ( (
path->Length[1] << 8 ) |
path->Length[0] )
317 dst = ( ( (
void * ) dst ) +
len );
353 len = ( prefix_len +
sizeof ( *macpath ) +
sizeof ( *vlanpath ) +
363 macpath = ( ( (
void * )
path ) + prefix_len );
373 vlanpath = ( ( (
void * ) macpath ) +
sizeof ( *macpath ) );
378 end = ( ( (
void * ) vlanpath ) +
sizeof ( *vlanpath ) );
380 end = ( ( (
void * ) macpath ) +
sizeof ( *macpath ) );
406 uripath_len = (
sizeof ( *uripath ) + uri_len );
407 len = ( uripath_len +
sizeof ( *end ) );
415 uripath = ( (
void * )
path );
421 end = ( ( (
void * )
path ) + uripath_len );
460 iscsi_len = (
sizeof ( *iscsipath ) + name_len );
461 len = ( prefix_len + iscsi_len +
sizeof ( *end ) );
469 memcpy ( path, netpath, prefix_len );
470 iscsipath = ( ( (
void * ) path ) + prefix_len );
476 name = ( ( (
void * ) iscsipath ) +
sizeof ( *iscsipath ) );
478 end = ( ( (
void * )
name ) + name_len );
513 memset ( &satapath, 0,
sizeof ( satapath ) );
516 satapath.sata.Header.Length[0] =
sizeof ( satapath.sata );
517 satapath.sata.HBAPortNumber = aoedev->
major;
518 satapath.sata.PortMultiplierPortNumber = aoedev->
minor;
550 path =
zalloc (
sizeof ( *path ) );
557 path->fc.Header.Length[0] =
sizeof ( path->fc );
558 memcpy ( path->fc.WWN, &
desc->wwn, sizeof ( path->fc.WWN ) );
559 memcpy ( path->fc.Lun, &
desc->lun, sizeof ( path->fc.Lun ) );
562 return &path->fc.Header;
590 len = ( prefix_len +
sizeof ( *ibpath ) +
sizeof ( *end ) );
599 ibpath = ( ( (
void * )
path ) + prefix_len );
611 end = ( ( (
void * ) ibpath ) +
sizeof ( *ibpath ) );
647 len = ( prefix_len + (
count *
sizeof ( *usbpath ) ) +
657 end = ( ( (
void * )
path ) +
len -
sizeof ( *end ) );
659 usbpath = ( ( (
void * )
end ) -
sizeof ( *usbpath ) );
661 for ( ; usb ; usbpath--, usb = usb->
port->
hub->
usb ) {
688 path =
op (
object );
736 if ( ( !! dns->
IsIPv6 ) !=
745 for ( i = 0 ; i <
count ; i++ ) {
747 if ( frag_len > pathset->
len )
748 frag_len = pathset->
len;
817 if ( ( path->
Type != pathset->
type ) ||
822 if ( ( ret = pathset->
fetch ( pathset, path,
859 pathsets->
path = path;
884 DBGC (
settings,
"EFI path %s could not register for %s: %s\n",
static int efi_path_fetch(struct settings *settings, struct setting *setting, void *data, size_t len)
Fetch value of EFI device path setting.
#define MSG_FIBRECHANNELEX_DP
Fibre Channel Ex SubType.
struct arbelprm_rc_send_wqe rc
unsigned int efi_path_vlan(EFI_DEVICE_PATH_PROTOCOL *path)
Get VLAN tag from device path.
union srp_port_id srp
SRP version of port identifier.
Dynamic Host Configuration Protocol.
struct net_device * tcpip_netdev(struct sockaddr_tcpip *st_dest)
Determine transmitting network device.
#define ISCSI_LOGIN_OPTION_AUTHMETHOD_NON
uint8_t ll_addr_len
Link-layer address length.
struct ipxe_ib_sbft sbft
Boot firmware table parameters.
uint8_t interface[0]
List of interface numbers.
#define END_DEVICE_PATH_TYPE
struct sockaddr target_sockaddr
Target socket address (for boot firmware table)
uint8_t offset
Offset within device path.
unsigned int count
Number of interfaces.
uint32_t next
Next descriptor address.
uint32_t first
First block in range.
UINT8 IfType
Network interface type(i.e.
int(* fetch)(struct efi_path_setting *pathset, EFI_DEVICE_PATH_PROTOCOL *path, void *data, size_t len)
Fetch setting.
UINT8 SignatureType
Type of Disk Signature: (Unused values reserved).
u16 fc
802.11 Frame Control field
#define INFINIBAND_RESOURCE_FLAG_STORAGE_PROTOCOL
SRP target port identifier for Infiniband.
EFI_MAC_ADDRESS MacAddress
The MAC address for a network interface padded with 0s.
uint16_t major
Major number.
uint64_t desc
Microcode descriptor list physical address.
EFI_DEVICE_PATH_PROTOCOL * path
Device path.
#define ENOENT
No such file or directory.
struct device * dev
Underlying device.
union srp_port_id target
Target port identifier.
static struct settings_operations efi_path_settings_operations
EFI device path settings operations.
struct settings settings
Settings interface.
static int efi_path_fetch_fixed(struct efi_path_setting *pathset, EFI_DEVICE_PATH_PROTOCOL *path, void *data, size_t len)
Fetch an EFI device path fixed-size setting.
#define MSG_MAC_ADDR_DP
MAC Address Device Path SubType.
size_t efi_path_len(EFI_DEVICE_PATH_PROTOCOL *path)
Find length of device path (excluding terminator)
EFI_DEVICE_PATH_PROTOCOL Header
EFI_DEVICE_PATH_PROTOCOL Header
struct net_driver efi_path_net_driver __net_driver
EFI path settings per-netdevice driver.
union ib_gid dgid
Destination GID.
This protocol can be used on any device handle to obtain generic path/location information concerning...
EFI_DEVICE_PATH_PROTOCOL * efi_uri_path(struct uri *uri)
Construct EFI device path for URI.
#define offsetof(type, field)
Get offset of a field within a structure.
uint8_t mac[ETH_ALEN]
MAC address.
UINT16 LoginOption
iSCSI Login Options.
Uniform Resource Identifiers.
An EFI device path settings block.
#define MESSAGING_DEVICE_PATH
Messaging Device Paths.
An EFI device path setting.
UINT32 ResourceFlags
Flags to help identify/manage InfiniBand device path elements: Bit 0 - IOC/Service (0b = IOC,...
A network upper-layer driver.
static struct settings * netdev_settings(struct net_device *netdev)
Get per-netdevice configuration settings block.
static void settings_init(struct settings *settings, struct settings_operations *op, struct refcnt *refcnt, const struct settings_scope *default_scope)
Initialise a settings block.
void * intf_object(struct interface *intf)
Get pointer to object containing object interface.
static void efi_path_terminate(EFI_DEVICE_PATH_PROTOCOL *end)
Terminate device path.
EFI_DEVICE_PATH_PROTOCOL * efi_path_prev(EFI_DEVICE_PATH_PROTOCOL *path, EFI_DEVICE_PATH_PROTOCOL *curr)
Find previous element of device path.
struct interface * intf
Original interface.
static void uuid_mangle(union uuid *uuid)
Change UUID endianness.
EFI_DEVICE_PATH_PROTOCOL * efi_paths(EFI_DEVICE_PATH_PROTOCOL *first,...)
Concatenate EFI device paths.
EFI_IP_ADDRESS DnsServerIp[]
Instance of the DNS server address.
struct usb_device * usb
Underlying USB device, if any.
#define MSG_URI_DP
Uniform Resource Identifiers (URI) Device Path SubType.
EFI_DEVICE_PATH_PROTOCOL * efi_loaded_image_path
Device path for the loaded image's device handle.
void * memcpy(void *dest, const void *src, size_t len) __nonnull
EFI_DEVICE_PATH_PROTOCOL Header
struct usb_port * port
USB port.
assert((readw(&hdr->flags) &(GTF_reading|GTF_writing))==0)
#define container_of(ptr, type, field)
Get containing structure.
#define MEDIA_HARDDRIVE_DP
Hard Drive Media Device Path SubType.
#define DHCP_SETTINGS_NAME
Settings block name used for DHCP responses.
struct sbft_srp_subtable srp
The SRP subtable.
const char * path
Path (after URI decoding)
#define MSG_SATA_DP
SATA Device Path SubType.
static struct net_device * netdev
UINT8 ParentPortNumber
USB Parent Port Number.
Transport-network layer interface.
uint16_t count
Number of entries.
void * efi_path_mac(EFI_DEVICE_PATH_PROTOCOL *path)
Get MAC address from device path.
UINT16 VlanId
VLAN identifier (0-4094).
size_t format_uri(const struct uri *uri, char *buf, size_t len)
Format URI.
const struct setting_type * type
Setting type.
An Infiniband SRP sBFT created by iPXE.
#define MSG_IPv4_DP
IPv4 Device Path SubType.
EFI_DEVICE_PATH_PROTOCOL * efi_fcp_path(struct fcp_description *desc)
Construct EFI device path for Fibre Channel device.
const char * efi_devpath_text(EFI_DEVICE_PATH_PROTOCOL *path)
Get textual representation of device path.
UINT64 Lun
iSCSI Logical Unit Number.
union ib_guid service_id
Service ID.
uint8_t id
Request identifier.
static unsigned int usb_depth(struct usb_device *usb)
Get USB depth.
CHAR8 Uri[]
Instance of the URI pursuant to RFC 3986.
EFI_DEVICE_PATH_PROTOCOL * efi_ib_srp_path(struct ib_srp_device *ib_srp)
Construct EFI device path for Infiniband SRP device.
EFI_DEVICE_PATH_PROTOCOL Header
char * strerror(int errno)
Retrieve string representation of error number.
EFI_DEVICE_PATH_PROTOCOL * efi_netdev_path(struct net_device *netdev)
Construct EFI device path for network device.
struct refcnt refcnt
Reference counter.
static void(* free)(struct refcnt *refcnt))
EFI_DEVICE_PATH_PROTOCOL * efi_usb_path(struct usb_function *func)
Construct EFI device path for USB function.
struct scsi_lun lun
SCSI LUN (for boot firmware table)
void * zalloc(size_t size)
Allocate cleared memory.
UINT8 InterfaceNumber
USB Interface Number.
static int efi_path_net_probe(struct net_device *netdev, void *priv)
Create per-netdevice EFI path settings.
#define MSG_ISCSI_DP
iSCSI Device Path SubType
#define MSG_IPv6_DP
IPv6 Device Path SubType.
size_t strlen(const char *src)
Get length of string.
Settings block operations.
UINT64 DeviceId
64-bit persistent ID of remote device.
#define MSG_INFINIBAND_DP
InfiniBand Device Path SubType.
#define MSG_DNS_DP
DNS Device Path SubType.
#define MEDIA_DEVICE_PATH
struct usb_device * usb
USB device.
An Infiniband SRP device.
uint16_t ll_proto
Link-layer protocol.
EFI_DEVICE_PATH_PROTOCOL * efi_path_next(EFI_DEVICE_PATH_PROTOCOL *path)
Find next element in device path.
An FCP device description.
EFI_DEVICE_PATH_PROTOCOL * efi_iscsi_path(struct iscsi_session *iscsi)
Construct EFI device path for iSCSI device.
static int efi_path_fetch_dns(struct efi_path_setting *pathset, EFI_DEVICE_PATH_PROTOCOL *path, void *data, size_t len)
Fetch an EFI device path DNS setting.
uint8_t len
Length (if fixed)
struct device * dev
Underlying hardware device.
UINT64 TargetPortId
64-bit persistent ID of remote IOC port.
Network device management.
UINT8 Signature[16]
Signature unique to this partition: If SignatureType is 0, this field has to be initialized with 16 z...
#define MSG_VLAN_DP
VLAN Device Path SubType.
static uint16_t struct vmbus_xfer_pages_operations * op
UINT64 ServiceId
64-bit unique identifier to remote IOC or server process.
char * target_iqn
Target IQN.
EFI_DEVICE_PATH_PROTOCOL * efi_describe(struct interface *intf)
Describe object as an EFI device path.
char name[NETDEV_NAME_LEN]
Name of this network device.
static struct efi_path_setting efi_path_settings[]
EFI device path settings.
EFI_DEVICE_PATH_PROTOCOL Header
UINT8 Length[2]
Specific Device Path data.
SCSI RDMA Protocol over Infiniband.
UINT8 PortGid[16]
128-bit Global Identifier for remote fabric port.
static struct tlan_private * priv
__builtin_va_list va_list
Universal Serial Bus (USB)
EFI_DEVICE_PATH_PROTOCOL * efi_aoe_path(struct aoe_device *aoedev)
Construct EFI device path for AoE device.
struct uri * efi_path_uri(EFI_DEVICE_PATH_PROTOCOL *path)
Parse URI from device path.
struct ib_device * ibdev
Infiniband device.
struct usb_hub * hub
USB hub.
UINT8 SubType
Varies by Type 0xFF End Entire Device Path, or 0x01 End This Instance of a Device Path and start a ne...
int(* fetch)(struct settings *settings, struct setting *setting, void *data, size_t len)
Fetch value of setting.
The Hard Drive Media Device Path is used to represent a partition on a hard drive.
const struct setting * setting
Setting.
void intf_put(struct interface *intf)
Decrement reference count on an object interface.
uint8_t minor
Minor number.
if(len >=6 *4) __asm__ __volatile__("movsl" if(len >=5 *4) __asm__ __volatile__("movsl" if(len >=4 *4) __asm__ __volatile__("movsl" if(len >=3 *4) __asm__ __volatile__("movsl" if(len >=2 *4) __asm__ __volatile__("movsl" if(len >=1 *4) __asm__ __volatile__("movsl" if((len % 4) >=2) __asm__ __volatile__("movsw" if((len % 2) >=1) __asm__ __volatile__("movsb" return dest
uint32_t end
Ending offset.
struct net_device * netdev
Network device.
uint8_t data[48]
Additional event data.
struct sbft_ib_subtable ib
The Infiniband subtable.
UINT8 Type
0x01 Hardware Device Path.
struct usb_function_descriptor desc
Function descriptor.
A Uniform Resource Identifier.
int register_settings(struct settings *settings, struct settings *parent, const char *name)
Register settings block.
EFI_DEVICE_PATH_PROTOCOL * path
EFI device path copy.
struct efi_device * efidev_parent(struct device *dev)
Get parent EFI device.
typeof(acpi_finder=acpi_find)
ACPI table finder.
uint8_t ll_addr[MAX_LL_ADDR_LEN]
Link-layer address.
#define SIGNATURE_TYPE_GUID
static unsigned int vlan_tag(struct net_device *netdev)
Get the VLAN tag.
#define va_start(ap, last)
UINT8 IsIPv6
Indicates the DNS server address is IPv4 or IPv6 address.
struct settings * find_child_settings(struct settings *parent, const char *name)
Find child settings block.
struct device dev
Generic device.
FILE_LICENCE(GPL2_OR_LATER)
uint64_t tag
Identity tag.
uint8_t subtype
Path subtype.
int setting_cmp(const struct setting *a, const struct setting *b)
Compare two settings.
int memcmp(const void *first, const void *second, size_t len)
Compare memory regions.
#define NULL
NULL pointer (VOID *)
EFI_DEVICE_PATH_PROTOCOL * efi_path_end(EFI_DEVICE_PATH_PROTOCOL *path)
Find end of device path.
#define intf_get_dest_op(intf, type, dest)
Get object interface destination and operation method.
int efi_path_guid(EFI_DEVICE_PATH_PROTOCOL *path, union uuid *guid)
Get partition GUID from device path.
EFI_DEVICE_PATH_PROTOCOL Header
#define MSG_USB_DP
USB Device Path SubType.
struct ll_protocol * ll_protocol
Link-layer protocol.
struct uri * parse_uri(const char *uri_string)
Parse URI.
void * memset(void *dest, int character, size_t len) __nonnull
PACKED union @532::@546 Header
#define efi_describe_TYPE(object_type)