• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /****************************************************************************
2  ****************************************************************************
3  ***
4  ***   This header was automatically generated from a Linux kernel header
5  ***   of the same name, to make information necessary for userspace to
6  ***   call into the kernel available to libc.  It contains only constants,
7  ***   structures, and macros generated from the original header, and thus,
8  ***   contains no copyrightable information.
9  ***
10  ***   To edit the content of this header, modify the corresponding
11  ***   source file (e.g. under external/kernel-headers/original/) then
12  ***   run bionic/libc/kernel/tools/update_all.py
13  ***
14  ***   Any manual change here will be lost the next time this script will
15  ***   be run. You've been warned!
16  ***
17  ****************************************************************************
18  ****************************************************************************/
19 #ifndef EFA_ABI_USER_H
20 #define EFA_ABI_USER_H
21 #include <linux/types.h>
22 #define EFA_UVERBS_ABI_VERSION 1
23 enum {
24   EFA_ALLOC_UCONTEXT_CMD_COMP_TX_BATCH = 1 << 0,
25   EFA_ALLOC_UCONTEXT_CMD_COMP_MIN_SQ_WR = 1 << 1,
26 };
27 struct efa_ibv_alloc_ucontext_cmd {
28   __u32 comp_mask;
29   __u8 reserved_20[4];
30 };
31 enum efa_ibv_user_cmds_supp_udata {
32   EFA_USER_CMDS_SUPP_UDATA_QUERY_DEVICE = 1 << 0,
33   EFA_USER_CMDS_SUPP_UDATA_CREATE_AH = 1 << 1,
34 };
35 struct efa_ibv_alloc_ucontext_resp {
36   __u32 comp_mask;
37   __u32 cmds_supp_udata_mask;
38   __u16 sub_cqs_per_cq;
39   __u16 inline_buf_size;
40   __u32 max_llq_size;
41   __u16 max_tx_batch;
42   __u16 min_sq_wr;
43   __u8 reserved_a0[4];
44 };
45 struct efa_ibv_alloc_pd_resp {
46   __u32 comp_mask;
47   __u16 pdn;
48   __u8 reserved_30[2];
49 };
50 enum {
51   EFA_CREATE_CQ_WITH_COMPLETION_CHANNEL = 1 << 0,
52 };
53 struct efa_ibv_create_cq {
54   __u32 comp_mask;
55   __u32 cq_entry_size;
56   __u16 num_sub_cqs;
57   __u8 flags;
58   __u8 reserved_58[5];
59 };
60 enum {
61   EFA_CREATE_CQ_RESP_DB_OFF = 1 << 0,
62 };
63 struct efa_ibv_create_cq_resp {
64   __u32 comp_mask;
65   __u8 reserved_20[4];
66   __aligned_u64 q_mmap_key;
67   __aligned_u64 q_mmap_size;
68   __u16 cq_idx;
69   __u8 reserved_d0[2];
70   __u32 db_off;
71   __aligned_u64 db_mmap_key;
72 };
73 enum {
74   EFA_QP_DRIVER_TYPE_SRD = 0,
75 };
76 struct efa_ibv_create_qp {
77   __u32 comp_mask;
78   __u32 rq_ring_size;
79   __u32 sq_ring_size;
80   __u32 driver_qp_type;
81 };
82 struct efa_ibv_create_qp_resp {
83   __u32 comp_mask;
84   __u32 rq_db_offset;
85   __u32 sq_db_offset;
86   __u32 llq_desc_offset;
87   __aligned_u64 rq_mmap_key;
88   __aligned_u64 rq_mmap_size;
89   __aligned_u64 rq_db_mmap_key;
90   __aligned_u64 sq_db_mmap_key;
91   __aligned_u64 llq_desc_mmap_key;
92   __u16 send_sub_cq_idx;
93   __u16 recv_sub_cq_idx;
94   __u8 reserved_1e0[4];
95 };
96 struct efa_ibv_create_ah_resp {
97   __u32 comp_mask;
98   __u16 efa_address_handle;
99   __u8 reserved_30[2];
100 };
101 enum {
102   EFA_QUERY_DEVICE_CAPS_RDMA_READ = 1 << 0,
103   EFA_QUERY_DEVICE_CAPS_RNR_RETRY = 1 << 1,
104   EFA_QUERY_DEVICE_CAPS_CQ_NOTIFICATIONS = 1 << 2,
105 };
106 struct efa_ibv_ex_query_device_resp {
107   __u32 comp_mask;
108   __u32 max_sq_wr;
109   __u32 max_rq_wr;
110   __u16 max_sq_sge;
111   __u16 max_rq_sge;
112   __u32 max_rdma_size;
113   __u32 device_caps;
114 };
115 #endif
116