Name

eth_header — create the Ethernet header

Synopsis

int eth_header (struct sk_buff *  skb,
 struct net_device *  dev,
 unsigned short  type,
 const void *  daddr,
 const void *  saddr,
 unsigned  len);

Arguments

skb

buffer to alter

dev

source device

type

Ethernet type field

daddr

destination address (NULL leave destination address)

saddr

source address (NULL use device source address)

len

packet length (<= skb->len)

Description

Set the protocol type. For a packet of type ETH_P_802_3 we put the length in here instead. It is up to the 802.2 layer to carry protocol information.