• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * This header was generated from the Linux kernel headers by update_headers.py,
3  * to provide necessary information from kernel to userspace, such as constants,
4  * structures, and macros, and thus, contains no copyrightable information.
5  */
6 #ifndef RDMA_USER_IOCTL_CMDS_H
7 #define RDMA_USER_IOCTL_CMDS_H
8 #include <linux/types.h>
9 #include <linux/ioctl.h>
10 #define RDMA_IOCTL_MAGIC	0x1b
11 #define RDMA_VERBS_IOCTL \
12 	_IOWR(RDMA_IOCTL_MAGIC, 1, struct ib_uverbs_ioctl_hdr)
13 enum {
14 
15 	UVERBS_ATTR_F_MANDATORY = 1U << 0,
16 
17 	UVERBS_ATTR_F_VALID_OUTPUT = 1U << 1,
18 };
19 struct ib_uverbs_attr {
20 	__u16 attr_id;
21 	__u16 len;
22 	__u16 flags;
23 	union {
24 		struct {
25 			__u8 elem_id;
26 			__u8 reserved;
27 		} enum_data;
28 		__u16 reserved;
29 	} attr_data;
30 	union {
31 
32 		__aligned_u64 data;
33 
34 		__s64 data_s64;
35 	};
36 };
37 struct ib_uverbs_ioctl_hdr {
38 	__u16 length;
39 	__u16 object_id;
40 	__u16 method_id;
41 	__u16 num_attrs;
42 	__aligned_u64 reserved1;
43 	__u32 driver_id;
44 	__u32 reserved2;
45 	struct ib_uverbs_attr  attrs[0];
46 };
47 enum rdma_driver_id {
48 	RDMA_DRIVER_UNKNOWN,
49 	RDMA_DRIVER_MLX5,
50 	RDMA_DRIVER_MLX4,
51 	RDMA_DRIVER_CXGB3,
52 	RDMA_DRIVER_CXGB4,
53 	RDMA_DRIVER_MTHCA,
54 	RDMA_DRIVER_BNXT_RE,
55 	RDMA_DRIVER_OCRDMA,
56 	RDMA_DRIVER_NES,
57 	RDMA_DRIVER_I40IW,
58 	RDMA_DRIVER_VMW_PVRDMA,
59 	RDMA_DRIVER_QEDR,
60 	RDMA_DRIVER_HNS,
61 	RDMA_DRIVER_USNIC,
62 	RDMA_DRIVER_RXE,
63 	RDMA_DRIVER_HFI1,
64 	RDMA_DRIVER_QIB,
65 };
66 #endif
67