drivers/net/ethernet/dec/tulip/tulip.h
Source file repositories/reference/linux-study-clean/drivers/net/ethernet/dec/tulip/tulip.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/net/ethernet/dec/tulip/tulip.h- Extension
.h- Size
- 16060 bytes
- Lines
- 570
- 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.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/kernel.hlinux/types.hlinux/spinlock.hlinux/netdevice.hlinux/ethtool.hlinux/timer.hlinux/delay.hlinux/pci.hasm/io.hasm/irq.hlinux/unaligned.h
Detected Declarations
struct tulip_chip_tablestruct tulip_rx_descstruct tulip_tx_descstruct medialeafstruct mediatablestruct mediainfostruct ring_infostruct tulip_privatestruct eeprom_fixupenum tbl_flagenum chipsenum MediaIsenum tulip_offsetsenum pci_cfg_driver_regenum status_bitsenum tulip_mode_bitsenum tulip_busconfig_bitsenum desc_status_bitsenum t21143_csr6_bitsenum tulip_comet_csr13_bitsenum tulip_comet_csr18_bitsenum tulip_comet_csr20_bitsfunction tulip_start_rxtxfunction tulip_stop_rxtxfunction tulip_restart_rxtxfunction tulip_tx_timeout_complete
Annotated Snippet
struct tulip_chip_table {
char *chip_name;
int io_size;
int valid_intrs; /* CSR7 interrupt enable settings */
int flags;
void (*media_timer) (struct timer_list *);
work_func_t media_task;
};
enum tbl_flag {
HAS_MII = 0x00001,
HAS_MEDIA_TABLE = 0x00002,
CSR12_IN_SROM = 0x00004,
ALWAYS_CHECK_MII = 0x00008,
HAS_ACPI = 0x00010,
MC_HASH_ONLY = 0x00020, /* Hash-only multicast filter. */
HAS_PNICNWAY = 0x00080,
HAS_NWAY = 0x00040, /* Uses internal NWay xcvr. */
HAS_INTR_MITIGATION = 0x00100,
IS_ASIX = 0x00200,
HAS_8023X = 0x00400,
COMET_MAC_ADDR = 0x00800,
HAS_PCI_MWI = 0x01000,
HAS_PHY_IRQ = 0x02000,
HAS_SWAPPED_SEEPROM = 0x04000,
NEEDS_FAKE_MEDIA_TABLE = 0x08000,
COMET_PM = 0x10000,
};
/* chip types. careful! order is VERY IMPORTANT here, as these
* are used throughout the driver as indices into arrays */
/* Note 21142 == 21143. */
enum chips {
DC21040 = 0,
DC21041 = 1,
DC21140 = 2,
DC21142 = 3, DC21143 = 3,
LC82C168,
MX98713,
MX98715,
MX98725,
AX88140,
PNIC2,
COMET,
COMPEX9881,
I21145,
DM910X,
CONEXANT,
};
enum MediaIs {
MediaIsFD = 1,
MediaAlwaysFD = 2,
MediaIsMII = 4,
MediaIsFx = 8,
MediaIs100 = 16
};
/* Offsets to the Command and Status Registers, "CSRs". All accesses
must be longword instructions and quadword aligned. */
enum tulip_offsets {
CSR0 = 0,
CSR1 = 0x08,
CSR2 = 0x10,
CSR3 = 0x18,
CSR4 = 0x20,
CSR5 = 0x28,
CSR6 = 0x30,
CSR7 = 0x38,
CSR8 = 0x40,
CSR9 = 0x48,
CSR10 = 0x50,
CSR11 = 0x58,
CSR12 = 0x60,
CSR13 = 0x68,
CSR14 = 0x70,
CSR15 = 0x78,
CSR18 = 0x88,
CSR19 = 0x8c,
CSR20 = 0x90,
CSR27 = 0xAC,
CSR28 = 0xB0,
};
/* register offset and bits for CFDD PCI config reg */
enum pci_cfg_driver_reg {
Annotation
- Immediate include surface: `linux/kernel.h`, `linux/types.h`, `linux/spinlock.h`, `linux/netdevice.h`, `linux/ethtool.h`, `linux/timer.h`, `linux/delay.h`, `linux/pci.h`.
- Detected declarations: `struct tulip_chip_table`, `struct tulip_rx_desc`, `struct tulip_tx_desc`, `struct medialeaf`, `struct mediatable`, `struct mediainfo`, `struct ring_info`, `struct tulip_private`, `struct eeprom_fixup`, `enum tbl_flag`.
- 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.