Interface Module and Data Structure Access
[IP Core Functions]

Collaboration diagram for Interface Module and Data Structure Access:


Files

file  fip_if.c
 IF Access Functions.
file  fip_if.h
 IF Access Functions Header.

Defines

#define fip_if_isForwardingEnabled()   fip_if[fip_packet_getIfNum()].forwardingEnabled
 .routingEnabled Access Function

Typedefs

typedef fip_ds6_index_t fip_if6_index_t
 Inherit size from generic data structures.
typedef fip_ds6_searchStatus_t fip_if6_searchStatus_t
 Inherit size from generic data structures.

Define Documentation

 
#define fip_if_isForwardingEnabled (  )     fip_if[fip_packet_getIfNum()].forwardingEnabled

.routingEnabled Access Function

Note:
You should not access the fip_if structure directly, but instead use any of the following access functions.

Referenced by fip_ip_process().


Function Documentation

fip_return_t fip_if6_addAutoconfAddress ( fip_ifnum_t  ifnum,
unsigned char  prefixIndex,
unsigned char  LLIndex 
)

Add an auto-configured address based on the interface number, prefix, and link-layer address.

Parameters:
ifnum 
prefixIndex 
LLIndex 
Returns:

References fip_ip6addr_t::addr, ADDR_AUTOCONF, fip_if6_addUnicastAddress(), fip_ip6addr_cpy, fip_ipUtils_generateAutoconfIID(), RV_OK, RV_PARAMETER_ERROR, and RV_UNKNOWN_ERROR.

Referenced by fip_if6_addPrefix(), and fip_if_addLLAddress().

Here is the call graph for this function:

fip_return_t fip_if6_addMulticastAddress ( fip_ifnum_t  ifnum,
const fip_ip6addr_t addr,
fip_vlifetime_t  validUntil,
unsigned char  PreferredLLAddrIndex,
fip_bool_t  hasPreferredLLAddr 
)

Add an IPv6 Unicast Address to the Addressing Table.

Parameters:
ifnum Interface number to add unicast address to
addr IPv6 Address to add
validUntil Time (in seconds) which this address expires at, 0 is infinite
hasPreferredLLAddr Does this address have a preferred link-layer address to use?
PreferredLLAddrIndex Preferred Link-Layer Address to use with this address, only valid if hasPreferredLLAddr is true
Returns:
Status in standard fip_return_t

References fip_ip6addr_t::addr, ADDR_MULTICAST, ADDR_NEW, ADDR_UNUSED, fip_ip6addr_cpy, RV_MEMORY_ERROR, and RV_OK.

fip_return_t fip_if6_addPrefix ( fip_ifnum_t  ifnum,
const fip_ip6addr_t prefix,
unsigned char  length,
fip_vlifetime_t  vlifetime,
fip_bool_t  advPrefix,
fip_bool_t  onLink 
)

Add a prefix to the active prefix list, autoconfigure addresses based on that address, and if the interface has routing enabled you have the option of advertising that prefix.

Parameters:
ifnum Interface number to add prefix to.
prefix Pointer to the prefix, must point to a full 16 bytes.
length Length of the prefix in bits, must be multiple of 8.
vlifetime Valid lifetime in seconds, zero and 0xffffffff are infinite.
advPrefix Advertise prefix in RA?
onLink Is prefix on-link?
Returns:

References fip_ip6addr_t::addr, fip_if6_addAutoconfAddress(), fip_memcpy_ucharLen, PREFIX_UNUSED, PREFIX_USED, RV_MEMORY_ERROR, RV_OK, and RV_PARAMETER_ERROR.

Referenced by fip_console_pref(), fip_if_init(), and fip_nd6_processRA().

Here is the call graph for this function:

fip_return_t fip_if6_addUnicastAddress ( fip_ifnum_t  ifnum,
const fip_ip6addr_t addr,
fip_vlifetime_t  validUntil,
fip_addrtype_t  addrtype,
unsigned char  PreferredLLAddrIndex,
fip_bool_t  hasPreferredLLAddr 
)

Add an IPv6 Unicast Address to the Addressing Table.

Parameters:
ifnum Interface number to add unicast address to
addr IPv6 Address to add
validUntil Time (in seconds) which this address expires at, 0 is infinite
addrtype Type of address
hasPreferredLLAddr Does this address have a preferred link-layer address to use?
PreferredLLAddrIndex Preferred Link-Layer Address to use with this address, only valid if hasPreferredLLAddr is true
Returns:
Status in standard fip_return_t

References fip_ip6addr_t::addr, ADDR_NEW, ADDR_UNUSED, fip_ip6addr_cpy, RV_MEMORY_ERROR, and RV_OK.

Referenced by fip_console_addr(), and fip_if6_addAutoconfAddress().

fip_bool_t fip_if6_isDestMyMulticast ( fip_ifnum_t  ifnum  ) 

Check if the destination IPv6 address in the active packet is one of our multicast addresses.

This checks against any assigned multicast addresses, addresses we must be part of (ie: all-routers, all-hosts), and solicited node multicast addresses.

Returns:
a boolean type of true or false

References ADDR_UNUSED, fip_packet_getAttr, fip_packet_getFromIP6Hdr_destPtr, fip_packet_getFromIP6Hdr_isDestMulticast, and fip_packet_setAddrFlags.

Referenced by fip_ip_process().

fip_bool_t fip_if6_isDestMyUnicast ( fip_ifnum_t  ifnum  ) 

Check if the destination IPv6 address in the active packet is one of our unicast addresses.

Returns:
a boolean type of true or false

References ADDR_OPTIMISTIC, ADDR_PREFERRED, fip_packet_getFromIP6Hdr_destPtr, and fip_packet_setAttr.

Referenced by fip_ip_process(), and fip_route6_getNextHop().

void fip_if6_periodic ( fip_ifnum_t  ifnum  ) 

Perform periodic maintenance such as expiring IP addresses, running ND when required on our IP addresses, etc.

Parameters:
ifnum Interface number to perform this maintenance on.

References ADDR_DELETE, ADDR_NEW, ADDR_PREFERRED, fip_hostInterface_getSeconds32(), fip_nd6_periodicIf(), fip_nd6_periodicUnicast(), fip_timer_isExpired32, PREFIX_UNUSED, PREFIX_USED, and ROUTE_UNUSED.

Referenced by fip_task().

Here is the call graph for this function:

fip_return_t fip_if_addLLAddress ( fip_ifnum_t  ifnum,
fip_llptraddr_t  lladdr,
fip_bool_t  preferred,
fip_bool_t  validForGPAutoconf 
)

Add a link-layer address to an interface.

Parameters:
ifnum Interface Number to add the link-layer address
lladdr Link-layer address to add
preferred Is preferred address to send from on this interface
validForGPAutoconf Should autoconfigure a global prefix address from this LL address if possible
Returns:

References fip_if6_addAutoconfAddress(), fip_ll_addrLenInvalid, fip_memcpy_ucharLen, PREFIX_USED, RV_OK, RV_PARAMETER_ERROR, and RV_UNHANDLED.

Referenced by fip_console_link(), and fip_if_init().

Here is the call graph for this function:

void fip_if_init ( fip_ifnum_t  ifnum,
fip_llptraddr_t  lladdr,
uint16_t  defaultPacketBufSizes[],
unsigned char  LLHdrSrcOffset,
unsigned char  LLHdrDestOffset,
char *  name,
void(*)(void)  ifProcess,
const fip_nd6_if_t nd6ptr,
const unsigned char  validLLLengths[] 
)

Initilize an Interface.

Parameters:
ifnum Interface number to initilize
lladdr Primary Link-Layer Address of Interface
defaultPacketBufSizes An array of length FIP_NUMBUFS which indicates by default the amount of data to allocate for each buffer in the PacketBuf
LLHdrSrcOffset Offset from start of FIP_LLBUF to Source LL Addr
LLHdrDestOffset Offset from start of FIP_LLBUF to Destination LL Addr
name Name of interface, not bigger than FIP_CONF_MAX_IFNAME-1
ifProcess A pointer to the periodic process to call for this function, which will be responsible for sending data out at minimum
validLLLengths A pointer to an array of unsigned chars which indicates permissible Link-Layer address lengths, array is of size FIP_CONF_MAX_LLADDRS

References fip_if6_addPrefix(), fip_if_addLLAddress(), fip_timer_getExpireTime32miliS(), RV_OK, and fip_nd6_if_t::using6LPND.

Here is the call graph for this function:


Generated on Wed Dec 8 13:00:33 2010 for FIP by  doxygen 1.5.7.1