include/rdma/rdma_cm.h
Source file repositories/reference/linux-study-clean/include/rdma/rdma_cm.h
File Facts
- System
- Linux kernel
- Corpus path
include/rdma/rdma_cm.h- Extension
.h- Size
- 14621 bytes
- Lines
- 429
- Domain
- Repository Root And Misc
- Bucket
- include
- Inferred role
- Repository Root And Misc: implementation source
- Status
- source implementation candidate
Why This File Exists
Top-level or miscellaneous repository surface. Use this as map coverage unless a later manual pass promotes the file into a deeper subsystem dossier.
- Top-level or miscellaneous repository surface. Use this as map coverage unless a later manual pass promotes the file into a deeper subsystem dossier.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/socket.hlinux/in6.hrdma/ib_addr.hrdma/ib_sa.huapi/rdma/rdma_user_cm.h
Detected Declarations
struct rdma_addrstruct rdma_routestruct rdma_conn_paramstruct rdma_ud_paramstruct rdma_cm_eventstruct rdma_cm_idstruct rdma_cm_idenum rdma_cm_event_type
Annotated Snippet
struct rdma_addr {
struct sockaddr_storage src_addr;
struct sockaddr_storage dst_addr;
struct rdma_dev_addr dev_addr;
};
struct rdma_route {
struct rdma_addr addr;
struct sa_path_rec *path_rec;
/* Optional path records of primary path */
struct sa_path_rec *path_rec_inbound;
struct sa_path_rec *path_rec_outbound;
/*
* 0 - No primary nor alternate path is available
* 1 - Only primary path is available
* 2 - Both primary and alternate path are available
*/
int num_pri_alt_paths;
unsigned int num_service_recs;
struct sa_service_rec *service_recs;
};
struct rdma_conn_param {
const void *private_data;
u8 private_data_len;
u8 responder_resources;
u8 initiator_depth;
u8 flow_control;
u8 retry_count; /* ignored when accepting */
u8 rnr_retry_count;
/* Fields below ignored if a QP is created on the rdma_cm_id. */
u8 srq;
u32 qp_num;
u32 qkey;
};
struct rdma_ud_param {
const void *private_data;
u8 private_data_len;
struct rdma_ah_attr ah_attr;
u32 qp_num;
u32 qkey;
};
struct rdma_cm_event {
enum rdma_cm_event_type event;
int status;
union {
struct rdma_conn_param conn;
struct rdma_ud_param ud;
u64 arg;
} param;
struct rdma_ucm_ece ece;
};
struct rdma_cm_id;
/**
* rdma_cm_event_handler - Callback used to report user events.
*
* Notes: Users may not call rdma_destroy_id from this callback to destroy
* the passed in id, or a corresponding listen id. Returning a
* non-zero value from the callback will destroy the passed in id.
*/
typedef int (*rdma_cm_event_handler)(struct rdma_cm_id *id,
struct rdma_cm_event *event);
struct rdma_cm_id {
struct ib_device *device;
void *context;
struct ib_qp *qp;
rdma_cm_event_handler event_handler;
struct rdma_route route;
enum rdma_ucm_port_space ps;
enum ib_qp_type qp_type;
u32 port_num;
struct work_struct net_work;
};
struct rdma_cm_id *
__rdma_create_kernel_id(struct net *net, rdma_cm_event_handler event_handler,
void *context, enum rdma_ucm_port_space ps,
enum ib_qp_type qp_type, const char *caller);
struct rdma_cm_id *rdma_create_user_id(rdma_cm_event_handler event_handler,
void *context,
enum rdma_ucm_port_space ps,
enum ib_qp_type qp_type);
Annotation
- Immediate include surface: `linux/socket.h`, `linux/in6.h`, `rdma/ib_addr.h`, `rdma/ib_sa.h`, `uapi/rdma/rdma_user_cm.h`.
- Detected declarations: `struct rdma_addr`, `struct rdma_route`, `struct rdma_conn_param`, `struct rdma_ud_param`, `struct rdma_cm_event`, `struct rdma_cm_id`, `struct rdma_cm_id`, `enum rdma_cm_event_type`.
- Atlas domain: Repository Root And Misc / include.
- Implementation status: source implementation candidate.
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.