drivers/infiniband/core/cm_trace.h

Source file repositories/reference/linux-study-clean/drivers/infiniband/core/cm_trace.h

File Facts

System
Linux kernel
Corpus path
drivers/infiniband/core/cm_trace.h
Extension
.h
Size
9906 bytes
Lines
415
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.

Dependency Surface

Detected Declarations

Annotated Snippet

#undef TRACE_SYSTEM
#define TRACE_SYSTEM ib_cma

#if !defined(_TRACE_IB_CMA_H) || defined(TRACE_HEADER_MULTI_READ)

#define _TRACE_IB_CMA_H

#include <linux/tracepoint.h>
#include <rdma/ib_cm.h>
#include <trace/misc/rdma.h>

/*
 * enum ib_cm_state, from include/rdma/ib_cm.h
 */
#define IB_CM_STATE_LIST					\
	ib_cm_state(IDLE)					\
	ib_cm_state(LISTEN)					\
	ib_cm_state(REQ_SENT)					\
	ib_cm_state(REQ_RCVD)					\
	ib_cm_state(MRA_REQ_SENT)				\
	ib_cm_state(MRA_REQ_RCVD)				\
	ib_cm_state(REP_SENT)					\
	ib_cm_state(REP_RCVD)					\
	ib_cm_state(MRA_REP_SENT)				\
	ib_cm_state(MRA_REP_RCVD)				\
	ib_cm_state(ESTABLISHED)				\
	ib_cm_state(DREQ_SENT)					\
	ib_cm_state(DREQ_RCVD)					\
	ib_cm_state(TIMEWAIT)					\
	ib_cm_state(SIDR_REQ_SENT)				\
	ib_cm_state_end(SIDR_REQ_RCVD)

#undef  ib_cm_state
#undef  ib_cm_state_end
#define ib_cm_state(x)		TRACE_DEFINE_ENUM(IB_CM_##x);
#define ib_cm_state_end(x)	TRACE_DEFINE_ENUM(IB_CM_##x);

IB_CM_STATE_LIST

#undef  ib_cm_state
#undef  ib_cm_state_end
#define ib_cm_state(x)		{ IB_CM_##x, #x },
#define ib_cm_state_end(x)	{ IB_CM_##x, #x }

#define show_ib_cm_state(x) \
		__print_symbolic(x, IB_CM_STATE_LIST)

/*
 * enum ib_cm_lap_state, from include/rdma/ib_cm.h
 */
#define IB_CM_LAP_STATE_LIST					\
	ib_cm_lap_state(LAP_UNINIT)				\
	ib_cm_lap_state(LAP_IDLE)				\
	ib_cm_lap_state(LAP_SENT)				\
	ib_cm_lap_state(LAP_RCVD)				\
	ib_cm_lap_state(MRA_LAP_SENT)				\
	ib_cm_lap_state_end(MRA_LAP_RCVD)

#undef  ib_cm_lap_state
#undef  ib_cm_lap_state_end
#define ib_cm_lap_state(x)	TRACE_DEFINE_ENUM(IB_CM_##x);
#define ib_cm_lap_state_end(x)	TRACE_DEFINE_ENUM(IB_CM_##x);

IB_CM_LAP_STATE_LIST

#undef  ib_cm_lap_state
#undef  ib_cm_lap_state_end
#define ib_cm_lap_state(x)	{ IB_CM_##x, #x },
#define ib_cm_lap_state_end(x)	{ IB_CM_##x, #x }

#define show_ib_cm_lap_state(x) \
		__print_symbolic(x, IB_CM_LAP_STATE_LIST)

/*
 * enum ib_cm_rej_reason, from include/rdma/ib_cm.h
 */
#define IB_CM_REJ_REASON_LIST					\
	ib_cm_rej_reason(REJ_NO_QP)				\
	ib_cm_rej_reason(REJ_NO_EEC)				\
	ib_cm_rej_reason(REJ_NO_RESOURCES)			\
	ib_cm_rej_reason(REJ_TIMEOUT)				\
	ib_cm_rej_reason(REJ_UNSUPPORTED)			\
	ib_cm_rej_reason(REJ_INVALID_COMM_ID)			\
	ib_cm_rej_reason(REJ_INVALID_COMM_INSTANCE)		\
	ib_cm_rej_reason(REJ_INVALID_SERVICE_ID)		\
	ib_cm_rej_reason(REJ_INVALID_TRANSPORT_TYPE)		\
	ib_cm_rej_reason(REJ_STALE_CONN)			\
	ib_cm_rej_reason(REJ_RDC_NOT_EXIST)			\
	ib_cm_rej_reason(REJ_INVALID_GID)			\
	ib_cm_rej_reason(REJ_INVALID_LID)			\

Annotation

Implementation Notes