10#ifndef __EFI_IP6_ND_H__
11#define __EFI_IP6_ND_H__
13#define IP6_GET_TICKS(Ms) (((Ms) + IP6_TIMER_INTERVAL_IN_MS - 1) / IP6_TIMER_INTERVAL_IN_MS)
16 IP6_INF_ROUTER_LIFETIME = 0xFFFF,
19 IP6_MAX_RTR_SOLICITATIONS = 3,
20 IP6_RTR_SOLICITATION_INTERVAL = 4000,
22 IP6_MIN_RANDOM_FACTOR_SCALED = 1,
23 IP6_MAX_RANDOM_FACTOR_SCALED = 3,
24 IP6_RANDOM_FACTOR_SCALE = 2,
26 IP6_MAX_MULTICAST_SOLICIT = 3,
27 IP6_MAX_UNICAST_SOLICIT = 3,
28 IP6_MAX_ANYCAST_DELAY_TIME = 1,
29 IP6_MAX_NEIGHBOR_ADV = 3,
30 IP6_REACHABLE_TIME = 30000,
31 IP6_RETRANS_TIMER = 1000,
32 IP6_DELAY_FIRST_PROBE_TIME = 5000,
34 IP6_MIN_LINK_MTU = 1280,
35 IP6_MAX_LINK_MTU = 1500,
37 IP6_IS_ROUTER_FLAG = 0x80,
38 IP6_SOLICITED_FLAG = 0x40,
39 IP6_OVERRIDE_FLAG = 0x20,
41 IP6_M_ADDR_CONFIG_FLAG = 0x80,
42 IP6_O_CONFIG_FLAG = 0x40,
44 IP6_ON_LINK_FLAG = 0x80,
45 IP6_AUTO_CONFIG_FLAG = 0x40,
49 IP6_REDITECT_LENGTH = 40,
50 IP6_DAD_ENTRY_SIGNATURE =
SIGNATURE_32 (
'I',
'P',
'D',
'E')
95#define IP6_NEXT_OPTION_OFFSET(offset, length) (offset + sizeof(IP6_OPTION_HEADER) + length)
97 IP6_NEXT_OPTION_OFFSET (0, 0) == 2,
98 "The next option is minimally the combined size of the option tag and length"
123 UINT32 ValidLifetime;
124 UINT32 PreferredLifetime;
134 IN BOOLEAN IsDadPassed,
148 IP6_DAD_CALLBACK Callback;
157 IP6_DAD_CALLBACK DadCallback;
176 IP6_ARP_CALLBACK CallBack;
190 UINT32 ValidLifetime;
191 UINT32 PreferredLifetime;
211 OUT UINT32 *NeighborCount,
230 OUT UINT32 *PrefixCount,
250 IN UINT16 RouterLifetime
303 IN BOOLEAN IsDadPassed,
329 IN IP6_DAD_CALLBACK Callback OPTIONAL,
330 IN VOID *Context OPTIONAL
373 IN BOOLEAN OnLinkOrAuto,
374 IN UINT32 ValidLifetime,
375 IN UINT32 PreferredLifetime,
376 IN UINT8 PrefixLength,
396 IN BOOLEAN OnLinkOrAuto,
397 IN BOOLEAN ImmediateDelete
416 IN BOOLEAN OnLinkOrAuto,
417 IN UINT8 PrefixLength,
452 IN IP6_ARP_CALLBACK CallBack,
498 IN BOOLEAN SendIcmpError,
501 IN IP6_FRAME_TO_CANCEL FrameToCancel OPTIONAL,
502 IN VOID *Context OPTIONAL
730 IN BOOLEAN IsAnycast,
731 IN UINT8 PrefixLength,
732 IN UINT32 ValidLifetime,
733 IN UINT32 PreferredLifetime,
734 IN IP6_DAD_CALLBACK DadCallback OPTIONAL,
735 IN VOID *Context OPTIONAL
IP6_DEFAULT_ROUTER * Ip6CreateDefaultRouter(IN IP6_SERVICE *IpSb, IN EFI_IPv6_ADDRESS *Ip6Address, IN UINT16 RouterLifetime)
EFI_STATUS Ip6ProcessRedirect(IN IP6_SERVICE *IpSb, IN EFI_IP6_HEADER *Head, IN NET_BUF *Packet)
VOID Ip6DestroyDefaultRouter(IN IP6_SERVICE *IpSb, IN IP6_DEFAULT_ROUTER *DefaultRouter)
EFI_STATUS Ip6SetAddress(IN IP6_INTERFACE *Interface, IN EFI_IPv6_ADDRESS *Ip6Addr, IN BOOLEAN IsAnycast, IN UINT8 PrefixLength, IN UINT32 ValidLifetime, IN UINT32 PreferredLifetime, IN IP6_DAD_CALLBACK DadCallback OPTIONAL, IN VOID *Context OPTIONAL)
VOID Ip6OnDADFinished(IN BOOLEAN IsDadPassed, IN IP6_INTERFACE *IpIf, IN IP6_DAD_ENTRY *DadEntry)
IP6_PREFIX_LIST_ENTRY * Ip6FindPrefixListEntry(IN IP6_SERVICE *IpSb, IN BOOLEAN OnLinkOrAuto, IN UINT8 PrefixLength, IN EFI_IPv6_ADDRESS *Prefix)
VOID Ip6CleanDefaultRouterList(IN IP6_SERVICE *IpSb)
@ IP6_MAX_RTR_SOLICITATION_DELAY
1000 milliseconds
EFI_STATUS Ip6SendNeighborSolicit(IN IP6_SERVICE *IpSb, IN EFI_IPv6_ADDRESS *SourceAddress, IN EFI_IPv6_ADDRESS *DestinationAddress, IN EFI_IPv6_ADDRESS *TargetIp6Address, IN EFI_MAC_ADDRESS *SourceLinkAddress OPTIONAL)
VOID Ip6CleanPrefixListTable(IN IP6_SERVICE *IpSb, IN LIST_ENTRY *ListHead)
EFI_STATUS Ip6UpdateReachableTime(IN OUT IP6_SERVICE *IpSb)
VOID Ip6DestroyPrefixListEntry(IN IP6_SERVICE *IpSb, IN IP6_PREFIX_LIST_ENTRY *PrefixEntry, IN BOOLEAN OnLinkOrAuto, IN BOOLEAN ImmediateDelete)
EFI_STATUS Ip6SendRouterSolicit(IN IP6_SERVICE *IpSb, IN IP6_INTERFACE *Interface OPTIONAL, IN EFI_IPv6_ADDRESS *SourceAddress OPTIONAL, IN EFI_IPv6_ADDRESS *DestinationAddress OPTIONAL, IN EFI_MAC_ADDRESS *SourceLinkAddress OPTIONAL)
IP6_DEFAULT_ROUTER * Ip6FindDefaultRouter(IN IP6_SERVICE *IpSb, IN EFI_IPv6_ADDRESS *Ip6Address)
IP6_DAD_ENTRY * Ip6FindDADEntry(IN IP6_SERVICE *IpSb, IN EFI_IPv6_ADDRESS *Target, OUT IP6_INTERFACE **Interface OPTIONAL)
EFI_STATUS Ip6AddNeighbor(IN IP6_SERVICE *IpSb, IN EFI_IPv6_ADDRESS *TargetIp6Address, IN EFI_MAC_ADDRESS *TargetLinkAddress OPTIONAL, IN UINT32 Timeout, IN BOOLEAN Override)
EFI_STATUS Ip6ProcessNeighborAdvertise(IN IP6_SERVICE *IpSb, IN EFI_IP6_HEADER *Head, IN NET_BUF *Packet)
VOID Ip6OnArpResolved(IN VOID *Context)
EFI_STATUS Ip6InitDADProcess(IN IP6_INTERFACE *IpIf, IN IP6_ADDRESS_INFO *AddressInfo, IN IP6_DAD_CALLBACK Callback OPTIONAL, IN VOID *Context OPTIONAL)
EFI_STATUS Ip6DelNeighbor(IN IP6_SERVICE *IpSb, IN EFI_IPv6_ADDRESS *TargetIp6Address, IN EFI_MAC_ADDRESS *TargetLinkAddress OPTIONAL, IN UINT32 Timeout, IN BOOLEAN Override)
EFI_STATUS Ip6ProcessNeighborSolicit(IN IP6_SERVICE *IpSb, IN EFI_IP6_HEADER *Head, IN NET_BUF *Packet)
VOID Ip6NdTimerTicking(IN IP6_SERVICE *IpSb)
VOID EFIAPI Ip6NdFasterTimerTicking(IN EFI_EVENT Event, IN VOID *Context)
EFI_STATUS Ip6BuildPrefixTable(IN IP6_PROTOCOL *IpInstance, OUT UINT32 *PrefixCount, OUT EFI_IP6_ADDRESS_INFO **PrefixTable)
EFI_STATUS Ip6ProcessRouterAdvertise(IN IP6_SERVICE *IpSb, IN EFI_IP6_HEADER *Head, IN NET_BUF *Packet)
IP6_PREFIX_LIST_ENTRY * Ip6CreatePrefixListEntry(IN IP6_SERVICE *IpSb, IN BOOLEAN OnLinkOrAuto, IN UINT32 ValidLifetime, IN UINT32 PreferredLifetime, IN UINT8 PrefixLength, IN EFI_IPv6_ADDRESS *Prefix)
IP6_NEIGHBOR_ENTRY * Ip6CreateNeighborEntry(IN IP6_SERVICE *IpSb, IN IP6_ARP_CALLBACK CallBack, IN EFI_IPv6_ADDRESS *Ip6Address, IN EFI_MAC_ADDRESS *LinkAddress OPTIONAL)
EFI_STATUS Ip6FreeNeighborEntry(IN IP6_SERVICE *IpSb, IN IP6_NEIGHBOR_ENTRY *NeighborCache, IN BOOLEAN SendIcmpError, IN BOOLEAN FullFree, IN EFI_STATUS IoStatus, IN IP6_FRAME_TO_CANCEL FrameToCancel OPTIONAL, IN VOID *Context OPTIONAL)
EFI_STATUS Ip6BuildEfiNeighborCache(IN IP6_PROTOCOL *IpInstance, OUT UINT32 *NeighborCount, OUT EFI_IP6_NEIGHBOR_CACHE **NeighborCache)
IP6_NEIGHBOR_ENTRY * Ip6FindNeighborEntry(IN IP6_SERVICE *IpSb, IN EFI_IPv6_ADDRESS *Ip6Address)
#define SIGNATURE_32(A, B, C, D)
UINT32 DelayTime
in tick per 50 milliseconds