iPXE
Data Structures | Macros | Functions | Variables
if_ether.h File Reference
#include <stdint.h>

Go to the source code of this file.

Data Structures

struct  ethhdr
 An Ethernet link-layer header. More...
 

Macros

#define ETH_ALEN   6 /* Size of Ethernet address */
 
#define ETH_HLEN   14 /* Size of ethernet header */
 
#define ETH_ZLEN   60 /* Minimum packet */
 
#define ETH_FRAME_LEN   1514 /* Maximum packet */
 
#define ETH_DATA_ALIGN   2 /* Amount needed to align the data after an ethernet header */
 
#define ETH_MAX_MTU   (ETH_FRAME_LEN-ETH_HLEN)
 
#define ETH_P_RAW   0x0000 /* Raw packet */
 
#define ETH_P_IP   0x0800 /* Internet Protocl Packet */
 
#define ETH_P_ARP   0x0806 /* Address Resolution Protocol */
 
#define ETH_P_RARP   0x8035 /* Reverse Address resolution Protocol */
 
#define ETH_P_8021Q   0x8100 /* 802.1Q VLAN Extended Header */
 
#define ETH_P_IPV6   0x86DD /* IPv6 over blueblook */
 
#define ETH_P_SLOW   0x8809 /* Ethernet slow protocols */
 
#define ETH_P_EAPOL   0x888E /* 802.1X EAP over LANs */
 
#define ETH_P_AOE   0x88A2 /* ATA over Ethernet */
 
#define ETH_P_FCOE   0x8906 /* Fibre Channel over Ethernet */
 
#define ETH_P_FIP   0x8914 /* FCoE Initialization Protocol */
 

Functions

 FILE_LICENCE (GPL2_OR_LATER_OR_UBDL)
 
struct ethhdr __attribute__ ((packed))
 

Variables

uint8_t h_dest [ETH_ALEN]
 Destination MAC address. More...
 
uint8_t h_source [ETH_ALEN]
 Source MAC address. More...
 
uint16_t h_protocol
 Protocol ID. More...
 

Macro Definition Documentation

◆ ETH_ALEN

#define ETH_ALEN   6 /* Size of Ethernet address */

Definition at line 8 of file if_ether.h.

◆ ETH_HLEN

#define ETH_HLEN   14 /* Size of ethernet header */

Definition at line 9 of file if_ether.h.

◆ ETH_ZLEN

#define ETH_ZLEN   60 /* Minimum packet */

Definition at line 10 of file if_ether.h.

◆ ETH_FRAME_LEN

#define ETH_FRAME_LEN   1514 /* Maximum packet */

Definition at line 11 of file if_ether.h.

◆ ETH_DATA_ALIGN

#define ETH_DATA_ALIGN   2 /* Amount needed to align the data after an ethernet header */

Definition at line 12 of file if_ether.h.

◆ ETH_MAX_MTU

#define ETH_MAX_MTU   (ETH_FRAME_LEN-ETH_HLEN)

Definition at line 14 of file if_ether.h.

◆ ETH_P_RAW

#define ETH_P_RAW   0x0000 /* Raw packet */

Definition at line 17 of file if_ether.h.

◆ ETH_P_IP

#define ETH_P_IP   0x0800 /* Internet Protocl Packet */

Definition at line 18 of file if_ether.h.

◆ ETH_P_ARP

#define ETH_P_ARP   0x0806 /* Address Resolution Protocol */

Definition at line 19 of file if_ether.h.

◆ ETH_P_RARP

#define ETH_P_RARP   0x8035 /* Reverse Address resolution Protocol */

Definition at line 20 of file if_ether.h.

◆ ETH_P_8021Q

#define ETH_P_8021Q   0x8100 /* 802.1Q VLAN Extended Header */

Definition at line 21 of file if_ether.h.

◆ ETH_P_IPV6

#define ETH_P_IPV6   0x86DD /* IPv6 over blueblook */

Definition at line 22 of file if_ether.h.

◆ ETH_P_SLOW

#define ETH_P_SLOW   0x8809 /* Ethernet slow protocols */

Definition at line 23 of file if_ether.h.

◆ ETH_P_EAPOL

#define ETH_P_EAPOL   0x888E /* 802.1X EAP over LANs */

Definition at line 24 of file if_ether.h.

◆ ETH_P_AOE

#define ETH_P_AOE   0x88A2 /* ATA over Ethernet */

Definition at line 25 of file if_ether.h.

◆ ETH_P_FCOE

#define ETH_P_FCOE   0x8906 /* Fibre Channel over Ethernet */

Definition at line 26 of file if_ether.h.

◆ ETH_P_FIP

#define ETH_P_FIP   0x8914 /* FCoE Initialization Protocol */

Definition at line 27 of file if_ether.h.

Function Documentation

◆ FILE_LICENCE()

FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL  )

◆ __attribute__()

struct ethhdr __attribute__ ( (packed)  )

Variable Documentation

◆ h_dest

uint8_t h_dest[ETH_ALEN]

Destination MAC address.

Definition at line 6 of file if_ether.h.

◆ h_source

uint8_t h_source[ETH_ALEN]

Source MAC address.

Definition at line 8 of file if_ether.h.

◆ h_protocol

uint16_t h_protocol

Protocol ID.

Definition at line 10 of file if_ether.h.