2 * Copyright (c) 2005 Topspin Communications. All rights reserved.
3 * Copyright (c) 2005, 2006 Cisco Systems. All rights reserved.
4 * Copyright (c) 2005 PathScale, Inc. All rights reserved.
5 * Copyright (c) 2006 Mellanox Technologies. All rights reserved.
7 * This software is available to you under a choice of one of two
8 * licenses. You may choose to be licensed under the terms of the GNU
9 * General Public License (GPL) Version 2, available from the file
10 * COPYING in the main directory of this source tree, or the
11 * OpenIB.org BSD license below:
13 * Redistribution and use in source and binary forms, with or
14 * without modification, are permitted provided that the following
17 * - Redistributions of source code must retain the above
18 * copyright notice, this list of conditions and the following
21 * - Redistributions in binary form must reproduce the above
22 * copyright notice, this list of conditions and the following
23 * disclaimer in the documentation and/or other materials
24 * provided with the distribution.
26 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
27 * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
28 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
29 * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
30 * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
31 * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
32 * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
36 #ifndef IB_USER_VERBS_EXP_H
37 #define IB_USER_VERBS_EXP_H
39 #include <rdma/ib_user_verbs.h>
42 IB_USER_VERBS_EXP_CMD_FIRST = 64
46 IB_USER_VERBS_EXP_CMD_CREATE_QP,
47 IB_USER_VERBS_EXP_CMD_MODIFY_CQ,
48 IB_USER_VERBS_EXP_CMD_MODIFY_QP,
49 IB_USER_VERBS_EXP_CMD_CREATE_CQ,
50 IB_USER_VERBS_EXP_CMD_QUERY_DEVICE,
51 IB_USER_VERBS_EXP_CMD_CREATE_DCT,
52 IB_USER_VERBS_EXP_CMD_DESTROY_DCT,
53 IB_USER_VERBS_EXP_CMD_QUERY_DCT,
57 * Make sure that all structs defined in this file remain laid out so
58 * that they pack the same way on 32-bit and 64-bit architectures (to
59 * avoid incompatibility between 32-bit userspace and 64-bit kernels).
61 * - Do not use pointer types -- pass pointers in __u64 instead.
62 * - Make sure that any structure larger than 4 bytes is padded to a
63 * multiple of 8 bytes. Otherwise the structure size will be
64 * different between 32-bit and 64-bit architectures.
67 enum ib_uverbs_exp_create_qp_comp_mask {
68 IB_UVERBS_EXP_CREATE_QP_CAP_FLAGS = (1ULL << 0),
69 IB_UVERBS_EXP_CREATE_QP_INL_RECV = (1ULL << 1),
70 IB_UVERBS_EXP_CREATE_QP_QPG = (1ULL << 2)
73 struct ib_uverbs_qpg_init_attrib {
74 __u32 tss_child_count;
75 __u32 rss_child_count;
78 struct ib_uverbs_qpg {
85 struct ib_uverbs_qpg_init_attrib parent_attrib;
90 struct ib_uverbs_exp_create_qp {
101 __u32 max_inline_data;
109 struct ib_uverbs_qpg qpg;
110 __u64 driver_data[0];
113 enum ib_uverbs_exp_create_qp_resp_comp_mask {
114 IB_UVERBS_EXP_CREATE_QP_RESP_INL_RECV = (1ULL << 0),
117 struct ib_uverbs_exp_create_qp_resp {
125 __u32 max_inline_data;
129 struct ib_uverbs_create_dct {
147 __u64 driver_data[0];
150 struct ib_uverbs_create_dct_resp {
155 struct ib_uverbs_destroy_dct {
160 struct ib_uverbs_destroy_dct_resp {
164 struct ib_uverbs_query_dct {
167 __u64 driver_data[0];
170 struct ib_uverbs_query_dct_resp {
174 __u32 key_violations;
184 __u64 driver_data[0];
187 struct ib_uverbs_exp_query_device {
189 __u64 driver_data[0];
192 struct ib_uverbs_exp_query_device_resp {
194 struct ib_uverbs_query_device_resp base;
195 __u64 timestamp_mask;
196 __u64 hca_core_clock;
197 __u64 device_cap_flags2;
200 __u32 inline_recv_sz;
201 __u32 max_rss_tbl_sz;
204 #endif /* IB_USER_VERBS_EXP_H */