Skip to Content
Linux Device Drivers Development
book

Linux Device Drivers Development

by John Madieu
October 2017
Intermediate to advanced
586 pages
14h 8m
English
Packt Publishing
Content preview from Linux Device Drivers Development

Network interface structure

A network interface is represented in the kernel as an instance of the struct net_device structure, defined in include/linux/netdevice.h:

struct net_device { char name[IFNAMSIZ]; char *ifalias; unsigned long mem_end; unsigned long mem_start; unsigned long base_addr; int irq; netdev_features_t features; netdev_features_t hw_features; netdev_features_t wanted_features; int ifindex; struct net_device_stats stats; atomic_long_t rx_dropped; atomic_long_t tx_dropped; const struct net_device_ops *netdev_ops; const struct ethtool_ops *ethtool_ops; unsigned int flags; unsigned int priv_flags; unsigned char link_mode; unsigned char if_port; unsigned char dma; unsigned int mtu; unsigned short type; /* Interface address info. ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Linux Device Drivers, Second Edition

Linux Device Drivers, Second Edition

Jonathan Corbet, Alessandro Rubini
Linux Device Drivers, 3rd Edition

Linux Device Drivers, 3rd Edition

Jonathan Corbet, Alessandro Rubini, Greg Kroah-Hartman

Publisher Resources

ISBN: 9781785280009Supplemental Content