Jump to main content

##

# IPV6_PACKET Structure

## C

    typedef struct _IPV6_PACKET {
    struct _IPV6_PACKET * next;
    unsigned short payloadLen;
    unsigned short headerLen;
    unsigned short upperLayerHeaderLen;
    unsigned short upperLayerChecksumOffset;
    unsigned char upperLayerHeaderType;
    union {
        struct {
        unsigned char reserved : 3;
        unsigned char useUnspecAddr : 1;
        unsigned char sourceSpecified : 1;
        unsigned char queued : 1;
        unsigned char addressType : 2;
        }
        unsigned char val;
    } flags;
    TCPIP_MAC_ADDR remoteMACAddr;
    IPV6_PACKET_ACK_FNC ackFnc;
    TCPIP_MAC_PACKET_ACK_FUNC macAckFnc;
    void* ackParam;
    void* clientData;
    void * neighbor;
    unsigned short offsetInSegment;
    uint32_t queuedPacketTimeout;
    TCPIP_NET_HANDLE netIfH;
    IPV6_HEADER ipv6Header;
    IPV6_DATA_SEGMENT_HEADER payload;
    } IPV6_PACKET;

## Description

Structure: IPV6_PACKET.

IPv6 packets are queued for future transmission.queuedPacketTimeout is used to time-out IPv6 queued packets.

## Members

Members | Description
--- | ---
next | Next packet in a queue.
payloadLen | Amount of data in payload buffer.
headerLen | Total header length (IP header + IPv6 extension headers).
upperLayerHeaderLen | Total length of the upper layer header.
upperLayerChecksumOffset | Offset of the upper layer checksum.
upperLayerHeaderType | Type definition for the upper-layer header type.
useUnspecAddr: 1; | This packet should use the unspecified address.
sourceSpecified: 1; | The upper layer or application layer specified a source address.
queued : 1; | Packet has been queued.
addressType : 2; | IP_ADDRESS_TYPE_IPV6 or IP_ADDRESS_TYPE_IPV4.
remoteMACAddr | The packet's remote MAC address.
ackFnc | Function to be called when IPv6 is done with the packet.
macAckFnc | Function to be called when MAC is done with a TX packet.
ackParam | Parameter to be used.
clientData | Optional packet client data.
neighbor | The neighbor that the message was received from.
offsetInSegment | Offset used for storing fragment transmission information.
queuedPacketTimeout | Time out for IPv6 packets which are queued.
netIfH | Packet network interface.
ipv6Header | IPv6 header definition.
payload | IPv6 data segment payload.

## Remarks

For IPv6 queuing the time out has to be 0. The queue is processed separately by the NDP.IPV6_PACKET_ACK_FNC() is called after the successful removal and inclusion of the packet.