drivers/infiniband/hw/irdma/main.h
Source file repositories/reference/linux-study-clean/drivers/infiniband/hw/irdma/main.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/infiniband/hw/irdma/main.h- Extension
.h- Size
- 16674 bytes
- Lines
- 580
- Domain
- Driver Families
- Bucket
- drivers/infiniband
- 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.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- 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/ip.hlinux/tcp.hlinux/if_vlan.hnet/addrconf.hnet/netevent.hnet/tcp.hnet/ip6_route.hnet/flow.hnet/secure_seq.hlinux/netdevice.hlinux/etherdevice.hlinux/inetdevice.hlinux/spinlock.hlinux/kernel.hlinux/delay.hlinux/pci.hlinux/dma-mapping.hlinux/workqueue.hlinux/slab.hlinux/io.hlinux/iopoll.hlinux/crc32c.hlinux/kthread.hlinux/io-64-nonatomic-lo-hi.hlinux/auxiliary_bus.hlinux/net/intel/iidc_rdma.hrdma/ib_smi.hrdma/ib_verbs.hrdma/ib_pack.hrdma/rdma_cm.hrdma/iw_cm.hrdma/ib_user_verbs.h
Detected Declarations
struct irdma_rsrc_limitsstruct irdma_cqp_err_infostruct irdma_cqp_compl_infostruct irdma_cqp_requeststruct irdma_cqpstruct irdma_ccqstruct irdma_ceqstruct irdma_aeqstruct irdma_arp_entrystruct irdma_msix_vectorstruct irdma_mc_table_infostruct mc_table_liststruct irdma_qv_infostruct irdma_qvlist_infostruct irdma_gen_opsstruct irdma_pci_fstruct irdma_deviceenum init_completion_statefunction to_irdma_mmap_entryfunction irdma_alloc_rsrcfunction irdma_free_rsrc
Annotated Snippet
struct irdma_rsrc_limits {
u32 qplimit;
u32 mrlimit;
u32 cqlimit;
};
struct irdma_cqp_err_info {
u16 maj;
u16 min;
const char *desc;
};
struct irdma_cqp_compl_info {
u32 op_ret_val;
u16 maj_err_code;
u16 min_err_code;
bool error;
u8 op_code;
};
struct irdma_cqp_request {
struct cqp_cmds_info info;
struct completion comp;
struct list_head list;
refcount_t refcnt;
void (*callback_fcn)(struct irdma_cqp_request *cqp_request);
void *param;
struct irdma_cqp_compl_info compl_info;
bool waiting:1;
bool dynamic:1;
bool pending:1;
};
struct irdma_cqp {
struct irdma_sc_cqp sc_cqp;
spinlock_t req_lock; /* protect CQP request list */
spinlock_t compl_lock; /* protect CQP completion processing */
wait_queue_head_t waitq;
wait_queue_head_t remove_wq;
struct irdma_dma_mem sq;
struct irdma_dma_mem host_ctx;
u64 *scratch_array;
struct irdma_cqp_request *cqp_requests;
struct irdma_ooo_cqp_op *oop_op_array;
struct list_head cqp_avail_reqs;
struct list_head cqp_pending_reqs;
};
struct irdma_ccq {
struct irdma_sc_cq sc_cq;
struct irdma_dma_mem mem_cq;
struct irdma_dma_mem shadow_area;
};
struct irdma_ceq {
struct irdma_sc_ceq sc_ceq;
struct irdma_dma_mem mem;
u32 irq;
u32 msix_idx;
struct irdma_pci_f *rf;
struct tasklet_struct dpc_tasklet;
spinlock_t ce_lock; /* sync cq destroy with cq completion event notification */
};
struct irdma_aeq {
struct irdma_sc_aeq sc_aeq;
struct irdma_dma_mem mem;
struct irdma_pble_alloc palloc;
bool virtual_map;
};
struct irdma_arp_entry {
u32 ip_addr[4];
u8 mac_addr[ETH_ALEN];
};
struct irdma_msix_vector {
u32 idx;
u32 irq;
u32 cpu_affinity;
u32 ceq_id;
cpumask_t mask;
char name[IRDMA_IRQ_NAME_STR_LEN];
};
struct irdma_mc_table_info {
u32 mgn;
u32 dest_ip[4];
bool lan_fwd:1;
bool ipv4_valid:1;
Annotation
- Immediate include surface: `linux/ip.h`, `linux/tcp.h`, `linux/if_vlan.h`, `net/addrconf.h`, `net/netevent.h`, `net/tcp.h`, `net/ip6_route.h`, `net/flow.h`.
- Detected declarations: `struct irdma_rsrc_limits`, `struct irdma_cqp_err_info`, `struct irdma_cqp_compl_info`, `struct irdma_cqp_request`, `struct irdma_cqp`, `struct irdma_ccq`, `struct irdma_ceq`, `struct irdma_aeq`, `struct irdma_arp_entry`, `struct irdma_msix_vector`.
- Atlas domain: Driver Families / drivers/infiniband.
- Implementation status: source implementation candidate.
- Synchronization appears in or near this file; preserve lock ordering, sleepability, and interrupt-context constraints.
- 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.