1 #ifndef _GPXE_ETHERNET_H
2 #define _GPXE_ETHERNET_H
11 #include <gpxe/netdevice.h>
12 #include <gpxe/if_ether.h>
14 extern struct ll_protocol ethernet_protocol
;
16 extern const char * eth_ntoa ( const void *ll_addr
);
19 * Allocate Ethernet device
21 * @v priv_size Size of driver private data
22 * @ret netdev Network device, or NULL
24 static inline struct net_device
* alloc_etherdev ( size_t priv_size
) {
25 struct net_device
*netdev
;
27 netdev
= alloc_netdev ( priv_size
);
29 netdev
->ll_protocol
= ðernet_protocol
;
30 netdev
->max_pkt_len
= ETH_FRAME_LEN
;
35 #endif /* _GPXE_ETHERNET_H */