iPXE
Data Structures | Macros | Typedefs | Functions | Variables
Arp.h File Reference

EFI ARP Protocol Definition. More...

Go to the source code of this file.

Data Structures

struct  EFI_ARP_FIND_DATA
 
struct  EFI_ARP_CONFIG_DATA
 
struct  _EFI_ARP_PROTOCOL
 ARP is used to resolve local network protocol addresses into network hardware addresses. More...
 

Macros

#define EFI_ARP_SERVICE_BINDING_PROTOCOL_GUID
 
#define EFI_ARP_PROTOCOL_GUID
 

Typedefs

typedef struct _EFI_ARP_PROTOCOL EFI_ARP_PROTOCOL
 
typedef EFI_STATUS(EFIAPIEFI_ARP_CONFIGURE) (IN EFI_ARP_PROTOCOL *This, IN EFI_ARP_CONFIG_DATA *ConfigData OPTIONAL)
 This function is used to assign a station address to the ARP cache for this instance of the ARP driver. More...
 
typedef EFI_STATUS(EFIAPIEFI_ARP_ADD) (IN EFI_ARP_PROTOCOL *This, IN BOOLEAN DenyFlag, IN VOID *TargetSwAddress OPTIONAL, IN VOID *TargetHwAddress OPTIONAL, IN UINT32 TimeoutValue, IN BOOLEAN Overwrite)
 This function is used to insert entries into the ARP cache. More...
 
typedef EFI_STATUS(EFIAPIEFI_ARP_FIND) (IN EFI_ARP_PROTOCOL *This, IN BOOLEAN BySwAddress, IN VOID *AddressBuffer OPTIONAL, OUT UINT32 *EntryLength OPTIONAL, OUT UINT32 *EntryCount OPTIONAL, OUT EFI_ARP_FIND_DATA **Entries OPTIONAL, IN BOOLEAN Refresh)
 This function searches the ARP cache for matching entries and allocates a buffer into which those entries are copied. More...
 
typedef EFI_STATUS(EFIAPIEFI_ARP_DELETE) (IN EFI_ARP_PROTOCOL *This, IN BOOLEAN BySwAddress, IN VOID *AddressBuffer OPTIONAL)
 This function removes specified ARP cache entries. More...
 
typedef EFI_STATUS(EFIAPIEFI_ARP_FLUSH) (IN EFI_ARP_PROTOCOL *This)
 This function delete all dynamic entries from the ARP cache that match the specified software protocol type. More...
 
typedef EFI_STATUS(EFIAPIEFI_ARP_REQUEST) (IN EFI_ARP_PROTOCOL *This, IN VOID *TargetSwAddress OPTIONAL, IN EFI_EVENT ResolvedEvent OPTIONAL, OUT VOID *TargetHwAddress)
 This function tries to resolve the TargetSwAddress and optionally returns a TargetHwAddress if it already exists in the ARP cache. More...
 
typedef EFI_STATUS(EFIAPIEFI_ARP_CANCEL) (IN EFI_ARP_PROTOCOL *This, IN VOID *TargetSwAddress OPTIONAL, IN EFI_EVENT ResolvedEvent OPTIONAL)
 This function aborts the previous ARP request (identified by This, TargetSwAddress and ResolvedEvent) that is issued by EFI_ARP_PROTOCOL.Request(). More...
 

Functions

 FILE_LICENCE (BSD2_PATENT)
 

Variables

EFI_GUID gEfiArpServiceBindingProtocolGuid
 
EFI_GUID gEfiArpProtocolGuid
 

Detailed Description

EFI ARP Protocol Definition.

The EFI ARP Service Binding Protocol is used to locate EFI ARP Protocol drivers to create and destroy child of the driver to communicate with other host using ARP protocol. The EFI ARP Protocol provides services to map IP network address to hardware address used by a data link protocol.

Copyright (c) 2006 - 2018, Intel Corporation. All rights reserved.
SPDX-License-Identifier: BSD-2-Clause-Patent

Revision Reference:
This Protocol was introduced in UEFI Specification 2.0.

Definition in file Arp.h.

Macro Definition Documentation

◆ EFI_ARP_SERVICE_BINDING_PROTOCOL_GUID

#define EFI_ARP_SERVICE_BINDING_PROTOCOL_GUID
Value:
{ \
0xf44c00ee, 0x1f2c, 0x4a00, {0xaa, 0x9, 0x1c, 0x9f, 0x3e, 0x8, 0x0, 0xa3 } \
}

Definition at line 23 of file Arp.h.

◆ EFI_ARP_PROTOCOL_GUID

#define EFI_ARP_PROTOCOL_GUID
Value:
{ \
0xf4b427bb, 0xba21, 0x4f16, {0xbc, 0x4e, 0x43, 0xe4, 0x16, 0xab, 0x61, 0x9c } \
}

Definition at line 28 of file Arp.h.

Typedef Documentation

◆ EFI_ARP_PROTOCOL

Definition at line 33 of file Arp.h.

◆ EFI_ARP_CONFIGURE

typedef EFI_STATUS(EFIAPI * EFI_ARP_CONFIGURE) (IN EFI_ARP_PROTOCOL *This, IN EFI_ARP_CONFIG_DATA *ConfigData OPTIONAL)

This function is used to assign a station address to the ARP cache for this instance of the ARP driver.

Each ARP instance has one station address. The EFI_ARP_PROTOCOL driver will respond to ARP requests that match this registered station address. A call to this function with the ConfigData field set to NULL will reset this ARP instance.

Once a protocol type and station address have been assigned to this ARP instance, all the following ARP functions will use this information. Attempting to change the protocol type or station address to a configured ARP instance will result in errors.

Parameters
ThisThe pointer to the EFI_ARP_PROTOCOL instance.
ConfigDataThe pointer to the EFI_ARP_CONFIG_DATA structure.
Return values
EFI_SUCCESSThe new station address was successfully registered.
EFI_INVALID_PARAMETEROne or more of the following conditions is TRUE: This is NULL. SwAddressLength is zero when ConfigData is not NULL. StationAddress is NULL when ConfigData is not NULL.
EFI_ACCESS_DENIEDThe SwAddressType, SwAddressLength, or StationAddress is different from the one that is already registered.
EFI_OUT_OF_RESOURCESStorage for the new StationAddress could not be allocated.

Definition at line 144 of file Arp.h.

◆ EFI_ARP_ADD

typedef EFI_STATUS(EFIAPI * EFI_ARP_ADD) (IN EFI_ARP_PROTOCOL *This, IN BOOLEAN DenyFlag, IN VOID *TargetSwAddress OPTIONAL, IN VOID *TargetHwAddress OPTIONAL, IN UINT32 TimeoutValue, IN BOOLEAN Overwrite)

This function is used to insert entries into the ARP cache.

ARP cache entries are typically inserted and updated by network protocol drivers as network traffic is processed. Most ARP cache entries will time out and be deleted if the network traffic stops. ARP cache entries that were inserted by the Add() function may be static (will not time out) or dynamic (will time out). Default ARP cache timeout values are not covered in most network protocol specifications (although RFC 1122 comes pretty close) and will only be discussed in general terms in this specification. The timeout values that are used in the EFI Sample Implementation should be used only as a guideline. Final product implementations of the EFI network stack should be tuned for their expected network environments.

Parameters
ThisPointer to the EFI_ARP_PROTOCOL instance.
DenyFlagSet to TRUE if this entry is a deny entry. Set to FALSE if this entry is a normal entry.
TargetSwAddressPointer to a protocol address to add (or deny). May be set to NULL if DenyFlag is TRUE.
TargetHwAddressPointer to a hardware address to add (or deny). May be set to NULL if DenyFlag is TRUE.
TimeoutValueTime in 100-ns units that this entry will remain in the ARP cache. A value of zero means that the entry is permanent. A nonzero value will override the one given by Configure() if the entry to be added is a dynamic entry.
OverwriteIf TRUE, the matching cache entry will be overwritten with the supplied parameters. If FALSE, EFI_ACCESS_DENIED is returned if the corresponding cache entry already exists.
Return values
EFI_SUCCESSThe entry has been added or updated.
EFI_INVALID_PARAMETEROne or more of the following conditions is TRUE: This is NULL. DenyFlag is FALSE and TargetHwAddress is NULL. DenyFlag is FALSE and TargetSwAddress is NULL. TargetHwAddress is NULL and TargetSwAddress is NULL. Neither TargetSwAddress nor TargetHwAddress are NULL when DenyFlag is TRUE.
EFI_OUT_OF_RESOURCESThe new ARP cache entry could not be allocated.
EFI_ACCESS_DENIEDThe ARP cache entry already exists and Overwrite is not true.
EFI_NOT_STARTEDThe ARP driver instance has not been configured.

Definition at line 196 of file Arp.h.

◆ EFI_ARP_FIND

typedef EFI_STATUS(EFIAPI * EFI_ARP_FIND) (IN EFI_ARP_PROTOCOL *This, IN BOOLEAN BySwAddress, IN VOID *AddressBuffer OPTIONAL, OUT UINT32 *EntryLength OPTIONAL, OUT UINT32 *EntryCount OPTIONAL, OUT EFI_ARP_FIND_DATA **Entries OPTIONAL, IN BOOLEAN Refresh)

This function searches the ARP cache for matching entries and allocates a buffer into which those entries are copied.

The first part of the allocated buffer is EFI_ARP_FIND_DATA, following which are protocol address pairs and hardware address pairs. When finding a specific protocol address (BySwAddress is TRUE and AddressBuffer is not NULL), the ARP cache timeout for the found entry is reset if Refresh is set to TRUE. If the found ARP cache entry is a permanent entry, it is not affected by Refresh.

Parameters
ThisThe pointer to the EFI_ARP_PROTOCOL instance.
BySwAddressSet to TRUE to look for matching software protocol addresses. Set to FALSE to look for matching hardware protocol addresses.
AddressBufferThe pointer to the address buffer. Set to NULL to match all addresses.
EntryLengthThe size of an entry in the entries buffer.
EntryCountThe number of ARP cache entries that are found by the specified criteria.
EntriesThe pointer to the buffer that will receive the ARP cache entries.
RefreshSet to TRUE to refresh the timeout value of the matching ARP cache entry.
Return values
EFI_SUCCESSThe requested ARP cache entries were copied into the buffer.
EFI_INVALID_PARAMETEROne or more of the following conditions is TRUE: This is NULL. Both EntryCount and EntryLength are NULL, when Refresh is FALSE.
EFI_NOT_FOUNDNo matching entries were found.
EFI_NOT_STARTEDThe ARP driver instance has not been configured.

Definition at line 241 of file Arp.h.

◆ EFI_ARP_DELETE

typedef EFI_STATUS(EFIAPI * EFI_ARP_DELETE) (IN EFI_ARP_PROTOCOL *This, IN BOOLEAN BySwAddress, IN VOID *AddressBuffer OPTIONAL)

This function removes specified ARP cache entries.

Parameters
ThisThe pointer to the EFI_ARP_PROTOCOL instance.
BySwAddressSet to TRUE to delete matching protocol addresses. Set to FALSE to delete matching hardware addresses.
AddressBufferThe pointer to the address buffer that is used as a key to look for the cache entry. Set to NULL to delete all entries.
Return values
EFI_SUCCESSThe entry was removed from the ARP cache.
EFI_INVALID_PARAMETERThis is NULL.
EFI_NOT_FOUNDThe specified deletion key was not found.
EFI_NOT_STARTEDThe ARP driver instance has not been configured.

Definition at line 270 of file Arp.h.

◆ EFI_ARP_FLUSH

typedef EFI_STATUS(EFIAPI * EFI_ARP_FLUSH) (IN EFI_ARP_PROTOCOL *This)

This function delete all dynamic entries from the ARP cache that match the specified software protocol type.

Parameters
ThisThe pointer to the EFI_ARP_PROTOCOL instance.
Return values
EFI_SUCCESSThe cache has been flushed.
EFI_INVALID_PARAMETERThis is NULL.
EFI_NOT_FOUNDThere are no matching dynamic cache entries.
EFI_NOT_STARTEDThe ARP driver instance has not been configured.

Definition at line 290 of file Arp.h.

◆ EFI_ARP_REQUEST

typedef EFI_STATUS(EFIAPI * EFI_ARP_REQUEST) (IN EFI_ARP_PROTOCOL *This, IN VOID *TargetSwAddress OPTIONAL, IN EFI_EVENT ResolvedEvent OPTIONAL, OUT VOID *TargetHwAddress)

This function tries to resolve the TargetSwAddress and optionally returns a TargetHwAddress if it already exists in the ARP cache.

Parameters
ThisThe pointer to the EFI_ARP_PROTOCOL instance.
TargetSwAddressThe pointer to the protocol address to resolve.
ResolvedEventThe pointer to the event that will be signaled when the address is resolved or some error occurs.
TargetHwAddressThe pointer to the buffer for the resolved hardware address in network byte order.
Return values
EFI_SUCCESSThe data is copied from the ARP cache into the TargetHwAddress buffer.
EFI_INVALID_PARAMETEROne or more of the following conditions is TRUE: This is NULL. TargetHwAddress is NULL.
EFI_ACCESS_DENIEDThe requested address is not present in the normal ARP cache but is present in the deny address list. Outgoing traffic to that address is forbidden.
EFI_NOT_STARTEDThe ARP driver instance has not been configured.
EFI_NOT_READYThe request has been started and is not finished.

Definition at line 318 of file Arp.h.

◆ EFI_ARP_CANCEL

typedef EFI_STATUS(EFIAPI * EFI_ARP_CANCEL) (IN EFI_ARP_PROTOCOL *This, IN VOID *TargetSwAddress OPTIONAL, IN EFI_EVENT ResolvedEvent OPTIONAL)

This function aborts the previous ARP request (identified by This, TargetSwAddress and ResolvedEvent) that is issued by EFI_ARP_PROTOCOL.Request().

If the request is in the internal ARP request queue, the request is aborted immediately and its ResolvedEvent is signaled. Only an asynchronous address request needs to be canceled. If TargeSwAddress and ResolveEvent are both NULL, all the pending asynchronous requests that have been issued by This instance will be cancelled and their corresponding events will be signaled.

Parameters
ThisThe pointer to the EFI_ARP_PROTOCOL instance.
TargetSwAddressThe pointer to the protocol address in previous request session.
ResolvedEventPointer to the event that is used as the notification event in previous request session.
Return values
EFI_SUCCESSThe pending request session(s) is/are aborted and corresponding event(s) is/are signaled.
EFI_INVALID_PARAMETEROne or more of the following conditions is TRUE: This is NULL. TargetSwAddress is not NULL and ResolvedEvent is NULL. TargetSwAddress is NULL and ResolvedEvent is not NULL.
EFI_NOT_STARTEDThe ARP driver instance has not been configured.
EFI_NOT_FOUNDThe request is not issued by EFI_ARP_PROTOCOL.Request().

Definition at line 355 of file Arp.h.

Function Documentation

◆ FILE_LICENCE()

FILE_LICENCE ( BSD2_PATENT  )

Variable Documentation

◆ gEfiArpServiceBindingProtocolGuid

EFI_GUID gEfiArpServiceBindingProtocolGuid

◆ gEfiArpProtocolGuid

EFI_GUID gEfiArpProtocolGuid