drivers/net/ethernet/intel/igc/igc.h
Source file repositories/reference/linux-study-clean/drivers/net/ethernet/intel/igc/igc.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/net/ethernet/intel/igc/igc.h- Extension
.h- Size
- 22963 bytes
- Lines
- 805
- Domain
- Driver Families
- Bucket
- drivers/net
- Inferred role
- Driver Families: implementation source
- Status
- source implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Touches IRQ or DMA behavior; this matters for the representative real-device path.
- Allocates kernel memory; connect allocation flags and lifetime to context constraints.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/kobject.hlinux/pci.hlinux/netdevice.hlinux/vmalloc.hlinux/ethtool.hlinux/sctp.hlinux/ptp_clock_kernel.hlinux/timecounter.hlinux/net_tstamp.hlinux/bitfield.hlinux/hrtimer.hnet/xdp.higc_hw.h
Detected Declarations
struct igc_fpe_tstruct igc_tx_queue_statsstruct igc_rx_queue_statsstruct igc_rx_packet_statsstruct igc_tx_bufferstruct igc_tx_timestamp_requeststruct igc_inline_rx_tstampsstruct igc_ring_containerstruct igc_ringstruct igc_adapterstruct igc_rx_bufferstruct igc_xdp_buffstruct igc_metadata_requeststruct igc_q_vectorstruct igc_nfc_filterstruct igc_nfc_rulestruct igc_flex_filterenum igc_mac_filter_typeenum igc_tx_buffer_typeenum igc_rss_type_numenum igc_state_tenum igc_tx_flagsenum igc_boardsenum igc_filter_match_flagsenum igc_ring_flags_tfunction igc_rss_typefunction igc_test_staterrfunction igc_desc_unusedfunction igc_get_phy_infofunction igc_reset_phyfunction igc_rx_bufszfunction igc_rx_pg_orderfunction igc_read_phy_reg
Annotated Snippet
struct igc_fpe_t {
struct ethtool_mmsv mmsv;
u32 tx_min_frag_size;
bool tx_enabled;
};
enum igc_mac_filter_type {
IGC_MAC_FILTER_TYPE_DST = 0,
IGC_MAC_FILTER_TYPE_SRC
};
struct igc_tx_queue_stats {
u64 packets;
u64 bytes;
u64 restart_queue;
u64 restart_queue2;
};
struct igc_rx_queue_stats {
u64 packets;
u64 bytes;
u64 drops;
u64 csum_err;
u64 alloc_failed;
};
struct igc_rx_packet_stats {
u64 ipv4_packets; /* IPv4 headers processed */
u64 ipv4e_packets; /* IPv4E headers with extensions processed */
u64 ipv6_packets; /* IPv6 headers processed */
u64 ipv6e_packets; /* IPv6E headers with extensions processed */
u64 tcp_packets; /* TCP headers processed */
u64 udp_packets; /* UDP headers processed */
u64 sctp_packets; /* SCTP headers processed */
u64 nfs_packets; /* NFS headers processe */
u64 other_packets;
};
enum igc_tx_buffer_type {
IGC_TX_BUFFER_TYPE_SKB,
IGC_TX_BUFFER_TYPE_XDP,
IGC_TX_BUFFER_TYPE_XSK,
};
/* wrapper around a pointer to a socket buffer,
* so a DMA handle can be stored along with the buffer
*/
struct igc_tx_buffer {
union igc_adv_tx_desc *next_to_watch;
unsigned long time_stamp;
enum igc_tx_buffer_type type;
union {
struct sk_buff *skb;
struct xdp_frame *xdpf;
};
unsigned int bytecount;
u16 gso_segs;
__be16 protocol;
DEFINE_DMA_UNMAP_ADDR(dma);
DEFINE_DMA_UNMAP_LEN(len);
u32 tx_flags;
bool xsk_pending_ts;
};
struct igc_tx_timestamp_request {
union { /* reference to the packet being timestamped */
struct sk_buff *skb;
struct igc_tx_buffer *xsk_tx_buffer;
};
enum igc_tx_buffer_type buffer_type;
unsigned long start; /* when the tstamp request started (jiffies) */
u32 mask; /* _TSYNCTXCTL_TXTT_{X} bit for this request */
u32 regl; /* which TXSTMPL_{X} register should be used */
u32 regh; /* which TXSTMPH_{X} register should be used */
u32 flags; /* flags that should be added to the tx_buffer */
u8 xsk_queue_index; /* Tx queue which requesting timestamp */
struct xsk_tx_metadata_compl xsk_meta; /* ref to xsk Tx metadata */
};
struct igc_inline_rx_tstamps {
/* Timestamps are saved in little endian at the beginning of the packet
* buffer following the layout:
*
* DWORD: | 0 | 1 | 2 | 3 |
* Field: | Timer1 SYSTIML | Timer1 SYSTIMH | Timer0 SYSTIML | Timer0 SYSTIMH |
*
* SYSTIML holds the nanoseconds part while SYSTIMH holds the seconds
* part of the timestamp.
*
Annotation
- Immediate include surface: `linux/kobject.h`, `linux/pci.h`, `linux/netdevice.h`, `linux/vmalloc.h`, `linux/ethtool.h`, `linux/sctp.h`, `linux/ptp_clock_kernel.h`, `linux/timecounter.h`.
- Detected declarations: `struct igc_fpe_t`, `struct igc_tx_queue_stats`, `struct igc_rx_queue_stats`, `struct igc_rx_packet_stats`, `struct igc_tx_buffer`, `struct igc_tx_timestamp_request`, `struct igc_inline_rx_tstamps`, `struct igc_ring_container`, `struct igc_ring`, `struct igc_adapter`.
- Atlas domain: Driver Families / drivers/net.
- Implementation status: source implementation candidate.
- IRQ or DMA behavior appears here, which is relevant to the selected PCIe/NVMe device path.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.