History

Merge tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma

Pull rdma updates from Jason Gunthorpe: "A quiet cycle after the larger 5.8 effort. Substantially cleanup and driver work with a few smaller features this time. - Driver updates for hfi1, rxe, mlx5, hns, qedr, usnic, bnxt_re - Removal of dead or redundant code across the drivers - RAW resource tracker dumps to include a device specific data blob for device objects to aide device debugging - Further advance the IOCTL interface, remove the ability to turn it off. Add QUERY_CONTEXT, QUERY_MR, and QUERY_PD commands - Remove stubs related to devices with no pkey table - A shared CQ scheme to allow multiple ULPs to share the CQ rings of a device to give higher performance - Several more static checker, syzkaller and rare crashers fixed" * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma: (121 commits) RDMA/mlx5: Fix flow destination setting for RDMA TX flow table RDMA/rxe: Remove pkey table RDMA/umem: Add a schedule point in ib_umem_get() RDMA/hns: Fix the unneeded process when getting a general type of CQE error RDMA/hns: Fix error during modify qp RTS2RTS RDMA/hns: Delete unnecessary memset when allocating VF resource RDMA/hns: Remove redundant parameters in set_rc_wqe() RDMA/hns: Remove support for HIP08_A RDMA/hns: Refactor hns_roce_v2_set_hem() RDMA/hns: Remove redundant hardware opcode definitions RDMA/netlink: Remove CAP_NET_RAW check when dump a raw QP RDMA/include: Replace license text with SPDX tags RDMA/rtrs: remove WQ_MEM_RECLAIM for rtrs_wq RDMA/rtrs-clt: add an additional random 8 seconds before reconnecting RDMA/cma: Execute rdma_cm destruction from a handler properly RDMA/cma: Remove unneeded locking for req paths RDMA/cma: Using the standard locking pattern when delivering the removal event RDMA/cma: Simplify DEVICE_REMOVAL for internal_id RDMA/efa: Add EFA 0xefa1 PCI ID RDMA/efa: User/kernel compatibility handshake mechanism ...

Linus Torvalds committed 6 years ago

Commit d7806bb2 parents d6efb3a 23fcc7d166 files · +6945 −7569Browse files

Showing the changes to include (40 of 166 files). Show all

Unified · Split

40 files
  1. include/linux/mlx5/device.h +5 −4
  2. include/linux/mlx5/driver.h +2 −0
  3. include/linux/mlx5/mlx5_ifc.h +113 −16
  4. include/rdma/ib.h +2 −29
  5. include/rdma/ib_addr.h +2 −29
  6. include/rdma/ib_cache.h +1 −28
  7. include/rdma/ib_cm.h +1 −0
  8. include/rdma/ib_hdrs.h +1 −43
  9. include/rdma/ib_mad.h +2 −29
  10. include/rdma/ib_marshall.h +2 −29
  11. include/rdma/ib_pack.h +1 −28
  12. include/rdma/ib_pma.h +2 −29
  13. include/rdma/ib_sa.h +1 −28
  14. include/rdma/ib_smi.h +2 −29
  15. include/rdma/ib_umem.h +1 −28
  16. include/rdma/ib_umem_odp.h +1 −28
  17. include/rdma/ib_verbs.h +31 −69
  18. include/rdma/iw_cm.h +2 −28
  19. include/rdma/iw_portmap.h +2 −28
  20. include/rdma/opa_addr.h +1 −43
  21. include/rdma/opa_port_info.h +2 −29
  22. include/rdma/opa_smi.h +2 −29
  23. include/rdma/opa_vnic.h +4 −45
  24. include/rdma/rdma_cm.h +2 −29
  25. include/rdma/rdma_cm_ib.h +2 −29
  26. include/rdma/rdma_netlink.h +1 −1
  27. include/rdma/rdma_vt.h +4 −46
  28. include/rdma/rdmavt_cq.h +4 −49
  29. include/rdma/rdmavt_mr.h +4 −46
  30. include/rdma/rdmavt_qp.h +4 −46
  31. include/rdma/uverbs_ioctl.h +2 −28
  32. include/rdma/uverbs_named_ioctl.h +1 −28
  33. include/rdma/uverbs_std_types.h +15 −28
  34. include/rdma/uverbs_types.h +1 −28
  35. include/uapi/rdma/efa-abi.h +14 −1
  36. include/uapi/rdma/ib_user_ioctl_cmds.h +15 −0
  37. include/uapi/rdma/mlx5_user_ioctl_cmds.h +15 −1
  38. include/uapi/rdma/qedr-abi.h +7 −3
  39. include/uapi/rdma/rdma_netlink.h +9 −0
  40. include/uapi/rdma/rdma_user_ioctl.h +1 −1
include/linux/mlx5/device.h+5−4
@@ -276,7 +276,9 @@ enum { · 275 unmodified lines
276276 MLX5_MKEY_MASK_RW = 1ull << 20,
277277 MLX5_MKEY_MASK_A = 1ull << 21,
278278 MLX5_MKEY_MASK_SMALL_FENCE = 1ull << 23,
279− MLX5_MKEY_MASK_FREE = 1ull << 29,
279+ MLX5_MKEY_MASK_RELAXED_ORDERING_WRITE = 1ull << 25,
280+ MLX5_MKEY_MASK_FREE = 1ull << 29,
281+ MLX5_MKEY_MASK_RELAXED_ORDERING_READ = 1ull << 47,
280282 };
281283
282284 enum {
@@ -1007,7 +1009,6 @@ enum { · 724 unmodified lines
10071009 MLX5_MKEY_REMOTE_INVAL = 1 << 24,
10081010 MLX5_MKEY_FLAG_SYNC_UMR = 1 << 29,
10091011 MLX5_MKEY_BSF_EN = 1 << 30,
1010− MLX5_MKEY_LEN64 = 1 << 31,
10111012 };
10121013
10131014 struct mlx5_mkey_seg {
@@ -1361,11 +1362,11 @@ enum mlx5_qcam_feature_groups { · 347 unmodified lines
13611362 MLX5_ADDR_OF(device_event_cap, (mdev)->caps.hca_cur[MLX5_CAP_DEV_EVENT], cap)
13621363
13631364 #define MLX5_CAP_DEV_VDPA_EMULATION(mdev, cap)\
1364− MLX5_GET(device_virtio_emulation_cap, \
1365+ MLX5_GET(virtio_emulation_cap, \
13651366 (mdev)->caps.hca_cur[MLX5_CAP_VDPA_EMULATION], cap)
13661367
13671368 #define MLX5_CAP64_DEV_VDPA_EMULATION(mdev, cap)\
1368− MLX5_GET64(device_virtio_emulation_cap, \
1369+ MLX5_GET64(virtio_emulation_cap, \
13691370 (mdev)->caps.hca_cur[MLX5_CAP_VDPA_EMULATION], cap)
13701371
13711372 #define MLX5_CAP_IPSEC(mdev, cap)\
include/linux/mlx5/driver.h+2−0
@@ -975,6 +975,7 @@ void mlx5_register_debugfs(void); · 974 unmodified lines
975975 void mlx5_unregister_debugfs(void);
976976
977977 void mlx5_fill_page_array(struct mlx5_frag_buf *buf, __be64 *pas);
978+void mlx5_fill_page_frag_array_perm(struct mlx5_frag_buf *buf, __be64 *pas, u8 perm);
978979 void mlx5_fill_page_frag_array(struct mlx5_frag_buf *frag_buf, __be64 *pas);
979980 int mlx5_vector2eqn(struct mlx5_core_dev *dev, int vector, int *eqn,
980981 unsigned int *irqn);
@@ -1057,6 +1058,7 @@ enum { · 76 unmodified lines
10571058 enum {
10581059 MLX5_INTERFACE_PROTOCOL_IB = 0,
10591060 MLX5_INTERFACE_PROTOCOL_ETH = 1,
1061+ MLX5_INTERFACE_PROTOCOL_VDPA = 2,
10601062 };
10611063
10621064 struct mlx5_interface {
include/linux/mlx5/mlx5_ifc.h+113−16
@@ -93,6 +93,7 @@ enum { · 92 unmodified lines
9393
9494 enum {
9595 MLX5_OBJ_TYPE_GENEVE_TLV_OPT = 0x000b,
96+ MLX5_OBJ_TYPE_VIRTIO_NET_Q = 0x000d,
9697 MLX5_OBJ_TYPE_MKEY = 0xff01,
9798 MLX5_OBJ_TYPE_QP = 0xff02,
9899 MLX5_OBJ_TYPE_PSV = 0xff03,
@@ -985,17 +986,40 @@ struct mlx5_ifc_device_event_cap_bits { · 886 unmodified lines
985986 u8 user_unaffiliated_events[4][0x40];
986987 };
987988
988−struct mlx5_ifc_device_virtio_emulation_cap_bits {
989− u8 reserved_at_0[0x20];
989+struct mlx5_ifc_virtio_emulation_cap_bits {
990+ u8 desc_tunnel_offload_type[0x1];
991+ u8 eth_frame_offload_type[0x1];
992+ u8 virtio_version_1_0[0x1];
993+ u8 device_features_bits_mask[0xd];
994+ u8 event_mode[0x8];
995+ u8 virtio_queue_type[0x8];
990996
991− u8 reserved_at_20[0x13];
997+ u8 max_tunnel_desc[0x10];
998+ u8 reserved_at_30[0x3];
992999 u8 log_doorbell_stride[0x5];
9931000 u8 reserved_at_38[0x3];
9941001 u8 log_doorbell_bar_size[0x5];
9951002
9961003 u8 doorbell_bar_offset[0x40];
9971004
998− u8 reserved_at_80[0x780];
1005+ u8 max_emulated_devices[0x8];
1006+ u8 max_num_virtio_queues[0x18];
1007+
1008+ u8 reserved_at_a0[0x60];
1009+
1010+ u8 umem_1_buffer_param_a[0x20];
1011+
1012+ u8 umem_1_buffer_param_b[0x20];
1013+
1014+ u8 umem_2_buffer_param_a[0x20];
1015+
1016+ u8 umem_2_buffer_param_b[0x20];
1017+
1018+ u8 umem_3_buffer_param_a[0x20];
1019+
1020+ u8 umem_3_buffer_param_b[0x20];
1021+
1022+ u8 reserved_at_1c0[0x640];
9991023 };
10001024
10011025 enum {
@@ -1220,7 +1244,11 @@ struct mlx5_ifc_cmd_hca_cap_bits { · 218 unmodified lines
12201244
12211245 u8 max_sgl_for_optimized_performance[0x8];
12221246 u8 log_max_cq_sz[0x8];
1223− u8 reserved_at_d0[0xb];
1247+ u8 relaxed_ordering_write_umr[0x1];
1248+ u8 relaxed_ordering_read_umr[0x1];
1249+ u8 reserved_at_d2[0x7];
1250+ u8 virtio_net_device_emualtion_manager[0x1];
1251+ u8 virtio_blk_device_emualtion_manager[0x1];
12241252 u8 log_max_cq[0x5];
12251253
12261254 u8 log_max_eq_sz[0x8];
@@ -1396,7 +1424,10 @@ struct mlx5_ifc_cmd_hca_cap_bits { · 169 unmodified lines
13961424 u8 bf[0x1];
13971425 u8 driver_version[0x1];
13981426 u8 pad_tx_eth_packet[0x1];
1399− u8 reserved_at_263[0x8];
1427+ u8 reserved_at_263[0x3];
1428+ u8 mkey_by_name[0x1];
1429+ u8 reserved_at_267[0x4];
1430+
14001431 u8 log_bf_reg_size[0x5];
14011432
14021433 u8 reserved_at_270[0x8];
@@ -2953,7 +2984,7 @@ union mlx5_ifc_hca_cap_union_bits { · 1550 unmodified lines
29532984 struct mlx5_ifc_fpga_cap_bits fpga_cap;
29542985 struct mlx5_ifc_tls_cap_bits tls_cap;
29552986 struct mlx5_ifc_device_mem_cap_bits device_mem_cap;
2956− struct mlx5_ifc_device_virtio_emulation_cap_bits virtio_emulation_cap;
2987+ struct mlx5_ifc_virtio_emulation_cap_bits virtio_emulation_cap;
29572988 u8 reserved_at_0[0x8000];
29582989 };
29592990
@@ -3302,15 +3333,18 @@ struct mlx5_ifc_scheduling_context_bits { · 342 unmodified lines
33023333 };
33033334
33043335 struct mlx5_ifc_rqtc_bits {
3305− u8 reserved_at_0[0xa0];
3336+ u8 reserved_at_0[0xa0];
33063337
3307− u8 reserved_at_a0[0x10];
3308− u8 rqt_max_size[0x10];
3338+ u8 reserved_at_a0[0x5];
3339+ u8 list_q_type[0x3];
3340+ u8 reserved_at_a8[0x8];
3341+ u8 rqt_max_size[0x10];
33093342
3310− u8 reserved_at_c0[0x10];
3311− u8 rqt_actual_size[0x10];
3343+ u8 rq_vhca_id_format[0x1];
3344+ u8 reserved_at_c1[0xf];
3345+ u8 rqt_actual_size[0x10];
33123346
3313− u8 reserved_at_e0[0x6a0];
3347+ u8 reserved_at_e0[0x6a0];
33143348
33153349 struct mlx5_ifc_rq_num_bits rq_num[];
33163350 };
@@ -7092,7 +7126,7 @@ struct mlx5_ifc_destroy_mkey_out_bits { · 3775 unmodified lines
70927126
70937127 struct mlx5_ifc_destroy_mkey_in_bits {
70947128 u8 opcode[0x10];
7095− u8 reserved_at_10[0x10];
7129+ u8 uid[0x10];
70967130
70977131 u8 reserved_at_20[0x10];
70987132 u8 op_mod[0x10];
@@ -7723,8 +7757,10 @@ struct mlx5_ifc_create_qp_in_bits { · 624 unmodified lines
77237757 u8 reserved_at_20[0x10];
77247758 u8 op_mod[0x10];
77257759
7726− u8 reserved_at_40[0x40];
7760+ u8 reserved_at_40[0x8];
7761+ u8 input_qpn[0x18];
77277762
7763+ u8 reserved_at_60[0x20];
77287764 u8 opt_param_mask[0x20];
77297765
77307766 u8 ece[0x20];
@@ -7788,7 +7824,7 @@ struct mlx5_ifc_create_mkey_out_bits { · 57 unmodified lines
77887824
77897825 struct mlx5_ifc_create_mkey_in_bits {
77907826 u8 opcode[0x10];
7791− u8 reserved_at_10[0x10];
7827+ u8 uid[0x10];
77927828
77937829 u8 reserved_at_20[0x10];
77947830 u8 op_mod[0x10];
@@ -10346,6 +10382,40 @@ struct mlx5_ifc_create_umem_in_bits { · 2551 unmodified lines
1034610382 struct mlx5_ifc_umem_bits umem;
1034710383 };
1034810384
10385+struct mlx5_ifc_create_umem_out_bits {
10386+ u8 status[0x8];
10387+ u8 reserved_at_8[0x18];
10388+
10389+ u8 syndrome[0x20];
10390+
10391+ u8 reserved_at_40[0x8];
10392+ u8 umem_id[0x18];
10393+
10394+ u8 reserved_at_60[0x20];
10395+};
10396+
10397+struct mlx5_ifc_destroy_umem_in_bits {
10398+ u8 opcode[0x10];
10399+ u8 uid[0x10];
10400+
10401+ u8 reserved_at_20[0x10];
10402+ u8 op_mod[0x10];
10403+
10404+ u8 reserved_at_40[0x8];
10405+ u8 umem_id[0x18];
10406+
10407+ u8 reserved_at_60[0x20];
10408+};
10409+
10410+struct mlx5_ifc_destroy_umem_out_bits {
10411+ u8 status[0x8];
10412+ u8 reserved_at_8[0x18];
10413+
10414+ u8 syndrome[0x20];
10415+
10416+ u8 reserved_at_40[0x40];
10417+};
10418+
1034910419 struct mlx5_ifc_create_uctx_in_bits {
1035010420 u8 opcode[0x10];
1035110421 u8 reserved_at_10[0x10];
@@ -10358,6 +10428,18 @@ struct mlx5_ifc_create_uctx_in_bits { · 6 unmodified lines
1035810428 struct mlx5_ifc_uctx_bits uctx;
1035910429 };
1036010430
10431+struct mlx5_ifc_create_uctx_out_bits {
10432+ u8 status[0x8];
10433+ u8 reserved_at_8[0x18];
10434+
10435+ u8 syndrome[0x20];
10436+
10437+ u8 reserved_at_40[0x10];
10438+ u8 uid[0x10];
10439+
10440+ u8 reserved_at_60[0x20];
10441+};
10442+
1036110443 struct mlx5_ifc_destroy_uctx_in_bits {
1036210444 u8 opcode[0x10];
1036310445 u8 reserved_at_10[0x10];
@@ -10371,6 +10453,15 @@ struct mlx5_ifc_destroy_uctx_in_bits { · 7 unmodified lines
1037110453 u8 reserved_at_60[0x20];
1037210454 };
1037310455
10456+struct mlx5_ifc_destroy_uctx_out_bits {
10457+ u8 status[0x8];
10458+ u8 reserved_at_8[0x18];
10459+
10460+ u8 syndrome[0x20];
10461+
10462+ u8 reserved_at_40[0x40];
10463+};
10464+
1037410465 struct mlx5_ifc_create_sw_icm_in_bits {
1037510466 struct mlx5_ifc_general_obj_in_cmd_hdr_bits hdr;
1037610467 struct mlx5_ifc_sw_icm_bits sw_icm;
@@ -10687,4 +10778,10 @@ struct mlx5_ifc_tls_progress_params_bits { · 310 unmodified lines
1068710778 u8 hw_offset_record_number[0x18];
1068810779 };
1068910780
10781+enum {
10782+ MLX5_MTT_PERM_READ = 1 << 0,
10783+ MLX5_MTT_PERM_WRITE = 1 << 1,
10784+ MLX5_MTT_PERM_RW = MLX5_MTT_PERM_READ | MLX5_MTT_PERM_WRITE,
10785+};
10786+
1069010787 #endif /* MLX5_IFC_H */
include/rdma/ib.h+2−29
@@ -1,36 +1,9 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2010 Intel Corporation. All rights reserved.
3− *
4− * This software is available to you under a choice of one of two
5− * licenses. You may choose to be licensed under the terms of the GNU
6− * General Public License (GPL) Version 2, available from the file
7− * COPYING in the main directory of this source tree, or the
8− * OpenIB.org BSD license below:
9− *
10− * Redistribution and use in source and binary forms, with or
11− * without modification, are permitted provided that the following
12− * conditions are met:
13− *
14− * - Redistributions of source code must retain the above
15− * copyright notice, this list of conditions and the following
16− * disclaimer.
17− *
18− * - Redistributions in binary form must reproduce the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer in the documentation and/or other materials
21− * provided with the distribution.
22− *
23− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30− * SOFTWARE.
314 */
325
33−#if !defined(_RDMA_IB_H)
6+#ifndef _RDMA_IB_H
347 #define _RDMA_IB_H
358
369 #include <linux/types.h>
include/rdma/ib_addr.h+2−29
@@ -1,37 +1,10 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2005 Voltaire Inc. All rights reserved.
34 * Copyright (c) 2005 Intel Corporation. All rights reserved.
4− *
5− * This software is available to you under a choice of one of two
6− * licenses. You may choose to be licensed under the terms of the GNU
7− * General Public License (GPL) Version 2, available from the file
8− * COPYING in the main directory of this source tree, or the
9− * OpenIB.org BSD license below:
10− *
11− * Redistribution and use in source and binary forms, with or
12− * without modification, are permitted provided that the following
13− * conditions are met:
14− *
15− * - Redistributions of source code must retain the above
16− * copyright notice, this list of conditions and the following
17− * disclaimer.
18− *
19− * - Redistributions in binary form must reproduce the above
20− * copyright notice, this list of conditions and the following
21− * disclaimer in the documentation and/or other materials
22− * provided with the distribution.
23− *
24− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
25− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
26− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
27− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
28− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
29− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
30− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
31− * SOFTWARE.
325 */
336
34−#if !defined(IB_ADDR_H)
7+#ifndef IB_ADDR_H
358 #define IB_ADDR_H
369
3710 #include <linux/in.h>
include/rdma/ib_cache.h+1−28
@@ -1,35 +1,8 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2004 Topspin Communications. All rights reserved.
34 * Copyright (c) 2005 Intel Corporation. All rights reserved.
45 * Copyright (c) 2005 Sun Microsystems, Inc. All rights reserved.
5− *
6− * This software is available to you under a choice of one of two
7− * licenses. You may choose to be licensed under the terms of the GNU
8− * General Public License (GPL) Version 2, available from the file
9− * COPYING in the main directory of this source tree, or the
10− * OpenIB.org BSD license below:
11− *
12− * Redistribution and use in source and binary forms, with or
13− * without modification, are permitted provided that the following
14− * conditions are met:
15− *
16− * - Redistributions of source code must retain the above
17− * copyright notice, this list of conditions and the following
18− * disclaimer.
19− *
20− * - Redistributions in binary form must reproduce the above
21− * copyright notice, this list of conditions and the following
22− * disclaimer in the documentation and/or other materials
23− * provided with the distribution.
24− *
25− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
26− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
27− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
28− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
29− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
30− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
31− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
32− * SOFTWARE.
336 */
347
358 #ifndef _IB_CACHE_H
include/rdma/ib_cm.h+1−0
@@ -6,6 +6,7 @@ · 5 unmodified lines
66 * Copyright (c) 2005 Sun Microsystems, Inc. All rights reserved.
77 * Copyright (c) 2019, Mellanox Technologies inc. All rights reserved.
88 */
9+
910 #ifndef IB_CM_H
1011 #define IB_CM_H
1112
include/rdma/ib_hdrs.h+1−43
@@ -1,48 +1,6 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */
12 /*
23 * Copyright(c) 2016 - 2018 Intel Corporation.
3− *
4− * This file is provided under a dual BSD/GPLv2 license. When using or
5− * redistributing this file, you may do so under either license.
6− *
7− * GPL LICENSE SUMMARY
8− *
9− * This program is free software; you can redistribute it and/or modify
10− * it under the terms of version 2 of the GNU General Public License as
11− * published by the Free Software Foundation.
12− *
13− * This program is distributed in the hope that it will be useful, but
14− * WITHOUT ANY WARRANTY; without even the implied warranty of
15− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16− * General Public License for more details.
17− *
18− * BSD LICENSE
19− *
20− * Redistribution and use in source and binary forms, with or without
21− * modification, are permitted provided that the following conditions
22− * are met:
23− *
24− * - Redistributions of source code must retain the above copyright
25− * notice, this list of conditions and the following disclaimer.
26− * - Redistributions in binary form must reproduce the above copyright
27− * notice, this list of conditions and the following disclaimer in
28− * the documentation and/or other materials provided with the
29− * distribution.
30− * - Neither the name of Intel Corporation nor the names of its
31− * contributors may be used to endorse or promote products derived
32− * from this software without specific prior written permission.
33− *
34− * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
35− * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
36− * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
37− * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
38− * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
39− * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
40− * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
41− * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
42− * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
43− * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
44− * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
45− *
464 */
475
486 #ifndef IB_HDRS_H
include/rdma/ib_mad.h+2−29
@@ -1,40 +1,13 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2004 Mellanox Technologies Ltd. All rights reserved.
34 * Copyright (c) 2004 Infinicon Corporation. All rights reserved.
45 * Copyright (c) 2004 Intel Corporation. All rights reserved.
56 * Copyright (c) 2004 Topspin Corporation. All rights reserved.
67 * Copyright (c) 2004-2006 Voltaire Corporation. All rights reserved.
7− *
8− * This software is available to you under a choice of one of two
9− * licenses. You may choose to be licensed under the terms of the GNU
10− * General Public License (GPL) Version 2, available from the file
11− * COPYING in the main directory of this source tree, or the
12− * OpenIB.org BSD license below:
13− *
14− * Redistribution and use in source and binary forms, with or
15− * without modification, are permitted provided that the following
16− * conditions are met:
17− *
18− * - Redistributions of source code must retain the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer.
21− *
22− * - Redistributions in binary form must reproduce the above
23− * copyright notice, this list of conditions and the following
24− * disclaimer in the documentation and/or other materials
25− * provided with the distribution.
26− *
27− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
28− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
29− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
30− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
31− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
32− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
33− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
34− * SOFTWARE.
358 */
369
37−#if !defined(IB_MAD_H)
10+#ifndef IB_MAD_H
3811 #define IB_MAD_H
3912
4013 #include <linux/list.h>
include/rdma/ib_marshall.h+2−29
@@ -1,36 +1,9 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2005-2006 Intel Corporation. All rights reserved.
3− *
4− * This software is available to you under a choice of one of two
5− * licenses. You may choose to be licensed under the terms of the GNU
6− * General Public License (GPL) Version 2, available from the file
7− * COPYING in the main directory of this source tree, or the
8− * OpenIB.org BSD license below:
9− *
10− * Redistribution and use in source and binary forms, with or
11− * without modification, are permitted provided that the following
12− * conditions are met:
13− *
14− * - Redistributions of source code must retain the above
15− * copyright notice, this list of conditions and the following
16− * disclaimer.
17− *
18− * - Redistributions in binary form must reproduce the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer in the documentation and/or other materials
21− * provided with the distribution.
22− *
23− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30− * SOFTWARE.
314 */
325
33−#if !defined(IB_USER_MARSHALL_H)
6+#ifndef IB_USER_MARSHALL_H
347 #define IB_USER_MARSHALL_H
358
369 #include <rdma/ib_verbs.h>
include/rdma/ib_pack.h+1−28
@@ -1,33 +1,6 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2004 Topspin Corporation. All rights reserved.
3− *
4− * This software is available to you under a choice of one of two
5− * licenses. You may choose to be licensed under the terms of the GNU
6− * General Public License (GPL) Version 2, available from the file
7− * COPYING in the main directory of this source tree, or the
8− * OpenIB.org BSD license below:
9− *
10− * Redistribution and use in source and binary forms, with or
11− * without modification, are permitted provided that the following
12− * conditions are met:
13− *
14− * - Redistributions of source code must retain the above
15− * copyright notice, this list of conditions and the following
16− * disclaimer.
17− *
18− * - Redistributions in binary form must reproduce the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer in the documentation and/or other materials
21− * provided with the distribution.
22− *
23− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30− * SOFTWARE.
314 */
325
336 #ifndef IB_PACK_H
include/rdma/ib_pma.h+2−29
@@ -1,38 +1,11 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2006, 2007, 2008, 2009, 2010 QLogic Corporation.
34 * All rights reserved.
45 * Copyright (c) 2005, 2006 PathScale, Inc. All rights reserved.
5− *
6− * This software is available to you under a choice of one of two
7− * licenses. You may choose to be licensed under the terms of the GNU
8− * General Public License (GPL) Version 2, available from the file
9− * COPYING in the main directory of this source tree, or the
10− * OpenIB.org BSD license below:
11− *
12− * Redistribution and use in source and binary forms, with or
13− * without modification, are permitted provided that the following
14− * conditions are met:
15− *
16− * - Redistributions of source code must retain the above
17− * copyright notice, this list of conditions and the following
18− * disclaimer.
19− *
20− * - Redistributions in binary form must reproduce the above
21− * copyright notice, this list of conditions and the following
22− * disclaimer in the documentation and/or other materials
23− * provided with the distribution.
24− *
25− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
26− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
27− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
28− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
29− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
30− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
31− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
32− * SOFTWARE.
336 */
347
35−#if !defined(IB_PMA_H)
8+#ifndef IB_PMA_H
369 #define IB_PMA_H
3710
3811 #include <rdma/ib_mad.h>
include/rdma/ib_sa.h+1−28
@@ -1,35 +1,8 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2004 Topspin Communications. All rights reserved.
34 * Copyright (c) 2005 Voltaire, Inc. All rights reserved.
45 * Copyright (c) 2006 Intel Corporation. All rights reserved.
5− *
6− * This software is available to you under a choice of one of two
7− * licenses. You may choose to be licensed under the terms of the GNU
8− * General Public License (GPL) Version 2, available from the file
9− * COPYING in the main directory of this source tree, or the
10− * OpenIB.org BSD license below:
11− *
12− * Redistribution and use in source and binary forms, with or
13− * without modification, are permitted provided that the following
14− * conditions are met:
15− *
16− * - Redistributions of source code must retain the above
17− * copyright notice, this list of conditions and the following
18− * disclaimer.
19− *
20− * - Redistributions in binary form must reproduce the above
21− * copyright notice, this list of conditions and the following
22− * disclaimer in the documentation and/or other materials
23− * provided with the distribution.
24− *
25− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
26− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
27− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
28− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
29− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
30− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
31− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
32− * SOFTWARE.
336 */
347
358 #ifndef IB_SA_H
include/rdma/ib_smi.h+2−29
@@ -1,40 +1,13 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2004 Mellanox Technologies Ltd. All rights reserved.
34 * Copyright (c) 2004 Infinicon Corporation. All rights reserved.
45 * Copyright (c) 2004 Intel Corporation. All rights reserved.
56 * Copyright (c) 2004 Topspin Corporation. All rights reserved.
67 * Copyright (c) 2004 Voltaire Corporation. All rights reserved.
7− *
8− * This software is available to you under a choice of one of two
9− * licenses. You may choose to be licensed under the terms of the GNU
10− * General Public License (GPL) Version 2, available from the file
11− * COPYING in the main directory of this source tree, or the
12− * OpenIB.org BSD license below:
13− *
14− * Redistribution and use in source and binary forms, with or
15− * without modification, are permitted provided that the following
16− * conditions are met:
17− *
18− * - Redistributions of source code must retain the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer.
21− *
22− * - Redistributions in binary form must reproduce the above
23− * copyright notice, this list of conditions and the following
24− * disclaimer in the documentation and/or other materials
25− * provided with the distribution.
26− *
27− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
28− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
29− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
30− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
31− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
32− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
33− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
34− * SOFTWARE.
358 */
369
37−#if !defined(IB_SMI_H)
10+#ifndef IB_SMI_H
3811 #define IB_SMI_H
3912
4013 #include <rdma/ib_mad.h>
include/rdma/ib_umem.h+1−28
@@ -1,33 +1,6 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2007 Cisco Systems. All rights reserved.
3− *
4− * This software is available to you under a choice of one of two
5− * licenses. You may choose to be licensed under the terms of the GNU
6− * General Public License (GPL) Version 2, available from the file
7− * COPYING in the main directory of this source tree, or the
8− * OpenIB.org BSD license below:
9− *
10− * Redistribution and use in source and binary forms, with or
11− * without modification, are permitted provided that the following
12− * conditions are met:
13− *
14− * - Redistributions of source code must retain the above
15− * copyright notice, this list of conditions and the following
16− * disclaimer.
17− *
18− * - Redistributions in binary form must reproduce the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer in the documentation and/or other materials
21− * provided with the distribution.
22− *
23− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30− * SOFTWARE.
314 */
325
336 #ifndef IB_UMEM_H
include/rdma/ib_umem_odp.h+1−28
@@ -1,33 +1,6 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2014 Mellanox Technologies. All rights reserved.
3− *
4− * This software is available to you under a choice of one of two
5− * licenses. You may choose to be licensed under the terms of the GNU
6− * General Public License (GPL) Version 2, available from the file
7− * COPYING in the main directory of this source tree, or the
8− * OpenIB.org BSD license below:
9− *
10− * Redistribution and use in source and binary forms, with or
11− * without modification, are permitted provided that the following
12− * conditions are met:
13− *
14− * - Redistributions of source code must retain the above
15− * copyright notice, this list of conditions and the following
16− * disclaimer.
17− *
18− * - Redistributions in binary form must reproduce the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer in the documentation and/or other materials
21− * provided with the distribution.
22− *
23− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30− * SOFTWARE.
314 */
325
336 #ifndef IB_UMEM_ODP_H
include/rdma/ib_verbs.h+31−69
@@ -1,3 +1,4 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2004 Mellanox Technologies Ltd. All rights reserved.
34 * Copyright (c) 2004 Infinicon Corporation. All rights reserved.
@@ -6,37 +7,9 @@ · 2 unmodified lines
67 * Copyright (c) 2004 Voltaire Corporation. All rights reserved.
78 * Copyright (c) 2005 Sun Microsystems, Inc. All rights reserved.
89 * Copyright (c) 2005, 2006, 2007 Cisco Systems. All rights reserved.
9− *
10− * This software is available to you under a choice of one of two
11− * licenses. You may choose to be licensed under the terms of the GNU
12− * General Public License (GPL) Version 2, available from the file
13− * COPYING in the main directory of this source tree, or the
14− * OpenIB.org BSD license below:
15− *
16− * Redistribution and use in source and binary forms, with or
17− * without modification, are permitted provided that the following
18− * conditions are met:
19− *
20− * - Redistributions of source code must retain the above
21− * copyright notice, this list of conditions and the following
22− * disclaimer.
23− *
24− * - Redistributions in binary form must reproduce the above
25− * copyright notice, this list of conditions and the following
26− * disclaimer in the documentation and/or other materials
27− * provided with the distribution.
28− *
29− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
30− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
31− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
32− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
33− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
34− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
35− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
36− * SOFTWARE.
3710 */
3811
39−#if !defined(IB_VERBS_H)
12+#ifndef IB_VERBS_H
4013 #define IB_VERBS_H
4114
4215 #include <linux/types.h>
@@ -75,6 +48,7 @@ struct ib_umem_odp; · 32 unmodified lines
7548 struct ib_uqp_object;
7649 struct ib_usrq_object;
7750 struct ib_uwq_object;
51+struct rdma_cm_id;
7852
7953 extern struct workqueue_struct *ib_wq;
8054 extern struct workqueue_struct *ib_comp_wq;
@@ -1566,9 +1540,8 @@ struct ib_xrcd { · 1485 unmodified lines
15661540 struct ib_device *device;
15671541 atomic_t usecnt; /* count all exposed resources */
15681542 struct inode *inode;
1569−
1570− struct mutex tgt_qp_mutex;
1571− struct list_head tgt_qp_list;
1543+ struct rw_semaphore tgt_qps_rwsem;
1544+ struct xarray tgt_qps;
15721545 };
15731546
15741547 struct ib_ah {
@@ -2270,6 +2243,7 @@ struct rdma_netdev_alloc_params { · 695 unmodified lines
22702243 struct ib_odp_counters {
22712244 atomic64_t faults;
22722245 atomic64_t invalidations;
2246+ atomic64_t prefetch;
22732247 };
22742248
22752249 struct ib_counters {
@@ -2476,7 +2450,7 @@ struct ib_device_ops { · 200 unmodified lines
24762450 struct ib_pd *pd, struct ib_udata *udata);
24772451 int (*dereg_mr)(struct ib_mr *mr, struct ib_udata *udata);
24782452 struct ib_mr *(*alloc_mr)(struct ib_pd *pd, enum ib_mr_type mr_type,
2479− u32 max_num_sg, struct ib_udata *udata);
2453+ u32 max_num_sg);
24802454 struct ib_mr *(*alloc_mr_integrity)(struct ib_pd *pd,
24812455 u32 max_num_data_sg,
24822456 u32 max_num_meta_sg);
@@ -2493,9 +2467,8 @@ struct ib_device_ops { · 10 unmodified lines
24932467 int (*dealloc_mw)(struct ib_mw *mw);
24942468 int (*attach_mcast)(struct ib_qp *qp, union ib_gid *gid, u16 lid);
24952469 int (*detach_mcast)(struct ib_qp *qp, union ib_gid *gid, u16 lid);
2496− struct ib_xrcd *(*alloc_xrcd)(struct ib_device *device,
2497− struct ib_udata *udata);
2498− int (*dealloc_xrcd)(struct ib_xrcd *xrcd, struct ib_udata *udata);
2470+ int (*alloc_xrcd)(struct ib_xrcd *xrcd, struct ib_udata *udata);
2471+ void (*dealloc_xrcd)(struct ib_xrcd *xrcd, struct ib_udata *udata);
24992472 struct ib_flow *(*create_flow)(struct ib_qp *qp,
25002473 struct ib_flow_attr *flow_attr,
25012474 int domain, struct ib_udata *udata);
@@ -2539,9 +2512,9 @@ struct ib_device_ops { · 37 unmodified lines
25392512 struct ib_mr *(*reg_dm_mr)(struct ib_pd *pd, struct ib_dm *dm,
25402513 struct ib_dm_mr_attr *attr,
25412514 struct uverbs_attr_bundle *attrs);
2542− struct ib_counters *(*create_counters)(
2543− struct ib_device *device, struct uverbs_attr_bundle *attrs);
2544− int (*destroy_counters)(struct ib_counters *counters);
2515+ int (*create_counters)(struct ib_counters *counters,
2516+ struct uverbs_attr_bundle *attrs);
2517+ void (*destroy_counters)(struct ib_counters *counters);
25452518 int (*read_counters)(struct ib_counters *counters,
25462519 struct ib_counters_read_attr *counters_read_attr,
25472520 struct uverbs_attr_bundle *attrs);
@@ -2581,8 +2554,13 @@ struct ib_device_ops { · 33 unmodified lines
25812554 /**
25822555 * Allows rdma drivers to add their own restrack attributes.
25832556 */
2584− int (*fill_res_entry)(struct sk_buff *msg,
2585− struct rdma_restrack_entry *entry);
2557+ int (*fill_res_mr_entry)(struct sk_buff *msg, struct ib_mr *ibmr);
2558+ int (*fill_res_mr_entry_raw)(struct sk_buff *msg, struct ib_mr *ibmr);
2559+ int (*fill_res_cq_entry)(struct sk_buff *msg, struct ib_cq *ibcq);
2560+ int (*fill_res_cq_entry_raw)(struct sk_buff *msg, struct ib_cq *ibcq);
2561+ int (*fill_res_qp_entry)(struct sk_buff *msg, struct ib_qp *ibqp);
2562+ int (*fill_res_qp_entry_raw)(struct sk_buff *msg, struct ib_qp *ibqp);
2563+ int (*fill_res_cm_id_entry)(struct sk_buff *msg, struct rdma_cm_id *id);
25862564
25872565 /* Device lifecycle callbacks */
25882566 /*
@@ -2637,14 +2615,19 @@ struct ib_device_ops { · 48 unmodified lines
26372615 * Allows rdma drivers to add their own restrack attributes
26382616 * dumped via 'rdma stat' iproute2 command.
26392617 */
2640− int (*fill_stat_entry)(struct sk_buff *msg,
2641− struct rdma_restrack_entry *entry);
2618+ int (*fill_stat_mr_entry)(struct sk_buff *msg, struct ib_mr *ibmr);
2619+
2620+ /* query driver for its ucontext properties */
2621+ int (*query_ucontext)(struct ib_ucontext *context,
2622+ struct uverbs_attr_bundle *attrs);
26422623
26432624 DECLARE_RDMA_OBJ_SIZE(ib_ah);
2625+ DECLARE_RDMA_OBJ_SIZE(ib_counters);
26442626 DECLARE_RDMA_OBJ_SIZE(ib_cq);
26452627 DECLARE_RDMA_OBJ_SIZE(ib_pd);
26462628 DECLARE_RDMA_OBJ_SIZE(ib_srq);
26472629 DECLARE_RDMA_OBJ_SIZE(ib_ucontext);
2630+ DECLARE_RDMA_OBJ_SIZE(ib_xrcd);
26482631 };
26492632
26502633 struct ib_core_device {
@@ -4263,14 +4246,8 @@ static inline int ib_dereg_mr(struct ib_mr *mr) · 1612 unmodified lines
42634246 return ib_dereg_mr_user(mr, NULL);
42644247 }
42654248
4266−struct ib_mr *ib_alloc_mr_user(struct ib_pd *pd, enum ib_mr_type mr_type,
4267− u32 max_num_sg, struct ib_udata *udata);
4268−
4269−static inline struct ib_mr *ib_alloc_mr(struct ib_pd *pd,
4270− enum ib_mr_type mr_type, u32 max_num_sg)
4271−{
4272− return ib_alloc_mr_user(pd, mr_type, max_num_sg, NULL);
4273−}
4249+struct ib_mr *ib_alloc_mr(struct ib_pd *pd, enum ib_mr_type mr_type,
4250+ u32 max_num_sg);
42744251
42754252 struct ib_mr *ib_alloc_mr_integrity(struct ib_pd *pd,
42764253 u32 max_num_data_sg,
@@ -4321,21 +4298,9 @@ int ib_attach_mcast(struct ib_qp *qp, union ib_gid *gid, u16 lid); · 44 unmodified lines
43214298 */
43224299 int ib_detach_mcast(struct ib_qp *qp, union ib_gid *gid, u16 lid);
43234300
4324−/**
4325− * ib_alloc_xrcd - Allocates an XRC domain.
4326− * @device: The device on which to allocate the XRC domain.
4327− * @caller: Module name for kernel consumers
4328− */
4329−struct ib_xrcd *__ib_alloc_xrcd(struct ib_device *device, const char *caller);
4330−#define ib_alloc_xrcd(device) \
4331− __ib_alloc_xrcd((device), KBUILD_MODNAME)
4332−
4333−/**
4334− * ib_dealloc_xrcd - Deallocates an XRC domain.
4335− * @xrcd: The XRC domain to deallocate.
4336− * @udata: Valid user data or NULL for kernel object
4337− */
4338−int ib_dealloc_xrcd(struct ib_xrcd *xrcd, struct ib_udata *udata);
4301+struct ib_xrcd *ib_alloc_xrcd_user(struct ib_device *device,
4302+ struct inode *inode, struct ib_udata *udata);
4303+int ib_dealloc_xrcd_user(struct ib_xrcd *xrcd, struct ib_udata *udata);
43394304
43404305 static inline int ib_check_mr_access(int flags)
43414306 {
@@ -4417,9 +4382,6 @@ struct ib_wq *ib_create_wq(struct ib_pd *pd, · 75 unmodified lines
44174382 int ib_destroy_wq(struct ib_wq *wq, struct ib_udata *udata);
44184383 int ib_modify_wq(struct ib_wq *wq, struct ib_wq_attr *attr,
44194384 u32 wq_attr_mask);
4420−struct ib_rwq_ind_table *ib_create_rwq_ind_table(struct ib_device *device,
4421− struct ib_rwq_ind_table_init_attr*
4422− wq_ind_table_init_attr);
44234385 int ib_destroy_rwq_ind_table(struct ib_rwq_ind_table *wq_ind_table);
44244386
44254387 int ib_map_mr_sg(struct ib_mr *mr, struct scatterlist *sg, int sg_nents,
include/rdma/iw_cm.h+2−28
@@ -1,35 +1,9 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2005 Network Appliance, Inc. All rights reserved.
34 * Copyright (c) 2005 Open Grid Computing, Inc. All rights reserved.
4− *
5− * This software is available to you under a choice of one of two
6− * licenses. You may choose to be licensed under the terms of the GNU
7− * General Public License (GPL) Version 2, available from the file
8− * COPYING in the main directory of this source tree, or the
9− * OpenIB.org BSD license below:
10− *
11− * Redistribution and use in source and binary forms, with or
12− * without modification, are permitted provided that the following
13− * conditions are met:
14− *
15− * - Redistributions of source code must retain the above
16− * copyright notice, this list of conditions and the following
17− * disclaimer.
18− *
19− * - Redistributions in binary form must reproduce the above
20− * copyright notice, this list of conditions and the following
21− * disclaimer in the documentation and/or other materials
22− * provided with the distribution.
23− *
24− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
25− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
26− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
27− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
28− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
29− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
30− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
31− * SOFTWARE.
325 */
6+
337 #ifndef IW_CM_H
348 #define IW_CM_H
359
include/rdma/iw_portmap.h+2−28
@@ -1,35 +1,9 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2014 Intel Corporation. All rights reserved.
34 * Copyright (c) 2014 Chelsio, Inc. All rights reserved.
4− *
5− * This software is available to you under a choice of one of two
6− * licenses. You may choose to be licensed under the terms of the GNU
7− * General Public License (GPL) Version 2, available from the file
8− * COPYING in the main directory of this source tree, or the
9− * OpenIB.org BSD license below:
10− *
11− * Redistribution and use in source and binary forms, with or
12− * without modification, are permitted provided that the following
13− * conditions are met:
14− *
15− * - Redistributions of source code must retain the above
16− * copyright notice, this list of conditions and the following
17− * disclaimer.
18− *
19− * - Redistributions in binary form must reproduce the above
20− * copyright notice, this list of conditions and the following
21− * disclaimer in the documentation and/or other materials
22− * provided with the distribution.
23− *
24− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
25− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
26− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
27− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
28− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
29− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
30− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
31− * SOFTWARE.
325 */
6+
337 #ifndef _IW_PORTMAP_H
348 #define _IW_PORTMAP_H
359
include/rdma/opa_addr.h+1−43
@@ -1,48 +1,6 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */
12 /*
23 * Copyright(c) 2017 Intel Corporation.
3− *
4− * This file is provided under a dual BSD/GPLv2 license. When using or
5− * redistributing this file, you may do so under either license.
6− *
7− * GPL LICENSE SUMMARY
8− *
9− * This program is free software; you can redistribute it and/or modify
10− * it under the terms of version 2 of the GNU General Public License as
11− * published by the Free Software Foundation.
12− *
13− * This program is distributed in the hope that it will be useful, but
14− * WITHOUT ANY WARRANTY; without even the implied warranty of
15− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16− * General Public License for more details.
17− *
18− * BSD LICENSE
19− *
20− * Redistribution and use in source and binary forms, with or without
21− * modification, are permitted provided that the following conditions
22− * are met:
23− *
24− * - Redistributions of source code must retain the above copyright
25− * notice, this list of conditions and the following disclaimer.
26− * - Redistributions in binary form must reproduce the above copyright
27− * notice, this list of conditions and the following disclaimer in
28− * the documentation and/or other materials provided with the
29− * distribution.
30− * - Neither the name of Intel Corporation nor the names of its
31− * contributors may be used to endorse or promote products derived
32− * from this software without specific prior written permission.
33− *
34− * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
35− * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
36− * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
37− * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
38− * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
39− * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
40− * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
41− * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
42− * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
43− * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
44− * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
45− *
464 */
475
486 #ifndef OPA_ADDR_H
include/rdma/opa_port_info.h+2−29
@@ -1,36 +1,9 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2014-2020 Intel Corporation. All rights reserved.
3− *
4− * This software is available to you under a choice of one of two
5− * licenses. You may choose to be licensed under the terms of the GNU
6− * General Public License (GPL) Version 2, available from the file
7− * COPYING in the main directory of this source tree, or the
8− * OpenIB.org BSD license below:
9− *
10− * Redistribution and use in source and binary forms, with or
11− * without modification, are permitted provided that the following
12− * conditions are met:
13− *
14− * - Redistributions of source code must retain the above
15− * copyright notice, this list of conditions and the following
16− * disclaimer.
17− *
18− * - Redistributions in binary form must reproduce the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer in the documentation and/or other materials
21− * provided with the distribution.
22− *
23− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30− * SOFTWARE.
314 */
325
33−#if !defined(OPA_PORT_INFO_H)
6+#ifndef OPA_PORT_INFO_H
347 #define OPA_PORT_INFO_H
358
369 #include <rdma/opa_smi.h>
include/rdma/opa_smi.h+2−29
@@ -1,36 +1,9 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2014 Intel Corporation. All rights reserved.
3− *
4− * This software is available to you under a choice of one of two
5− * licenses. You may choose to be licensed under the terms of the GNU
6− * General Public License (GPL) Version 2, available from the file
7− * COPYING in the main directory of this source tree, or the
8− * OpenIB.org BSD license below:
9− *
10− * Redistribution and use in source and binary forms, with or
11− * without modification, are permitted provided that the following
12− * conditions are met:
13− *
14− * - Redistributions of source code must retain the above
15− * copyright notice, this list of conditions and the following
16− * disclaimer.
17− *
18− * - Redistributions in binary form must reproduce the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer in the documentation and/or other materials
21− * provided with the distribution.
22− *
23− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30− * SOFTWARE.
314 */
325
33−#if !defined(OPA_SMI_H)
6+#ifndef OPA_SMI_H
347 #define OPA_SMI_H
358
369 #include <rdma/ib_mad.h>
include/rdma/opa_vnic.h+4−45
@@ -1,52 +1,11 @@
1−#ifndef _OPA_VNIC_H
2−#define _OPA_VNIC_H
1+/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */
32 /*
43 * Copyright(c) 2017 - 2020 Intel Corporation.
5− *
6− * This file is provided under a dual BSD/GPLv2 license. When using or
7− * redistributing this file, you may do so under either license.
8− *
9− * GPL LICENSE SUMMARY
10− *
11− * This program is free software; you can redistribute it and/or modify
12− * it under the terms of version 2 of the GNU General Public License as
13− * published by the Free Software Foundation.
14− *
15− * This program is distributed in the hope that it will be useful, but
16− * WITHOUT ANY WARRANTY; without even the implied warranty of
17− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
18− * General Public License for more details.
19− *
20− * BSD LICENSE
21− *
22− * Redistribution and use in source and binary forms, with or without
23− * modification, are permitted provided that the following conditions
24− * are met:
25− *
26− * - Redistributions of source code must retain the above copyright
27− * notice, this list of conditions and the following disclaimer.
28− * - Redistributions in binary form must reproduce the above copyright
29− * notice, this list of conditions and the following disclaimer in
30− * the documentation and/or other materials provided with the
31− * distribution.
32− * - Neither the name of Intel Corporation nor the names of its
33− * contributors may be used to endorse or promote products derived
34− * from this software without specific prior written permission.
35− *
36− * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
37− * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
38− * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
39− * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
40− * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
41− * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
42− * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
43− * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
44− * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
45− * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
46− * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
47− *
484 */
495
6+#ifndef _OPA_VNIC_H
7+#define _OPA_VNIC_H
8+
509 /*
5110 * This file contains Intel Omni-Path (OPA) Virtual Network Interface
5211 * Controller (VNIC) specific declarations.
include/rdma/rdma_cm.h+2−29
@@ -1,37 +1,10 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2005 Voltaire Inc. All rights reserved.
34 * Copyright (c) 2005 Intel Corporation. All rights reserved.
4− *
5− * This software is available to you under a choice of one of two
6− * licenses. You may choose to be licensed under the terms of the GNU
7− * General Public License (GPL) Version 2, available from the file
8− * COPYING in the main directory of this source tree, or the
9− * OpenIB.org BSD license below:
10− *
11− * Redistribution and use in source and binary forms, with or
12− * without modification, are permitted provided that the following
13− * conditions are met:
14− *
15− * - Redistributions of source code must retain the above
16− * copyright notice, this list of conditions and the following
17− * disclaimer.
18− *
19− * - Redistributions in binary form must reproduce the above
20− * copyright notice, this list of conditions and the following
21− * disclaimer in the documentation and/or other materials
22− * provided with the distribution.
23− *
24− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
25− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
26− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
27− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
28− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
29− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
30− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
31− * SOFTWARE.
325 */
336
34−#if !defined(RDMA_CM_H)
7+#ifndef RDMA_CM_H
358 #define RDMA_CM_H
369
3710 #include <linux/socket.h>
include/rdma/rdma_cm_ib.h+2−29
@@ -1,36 +1,9 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2006 Intel Corporation. All rights reserved.
3− *
4− * This software is available to you under a choice of one of two
5− * licenses. You may choose to be licensed under the terms of the GNU
6− * General Public License (GPL) Version 2, available from the file
7− * COPYING in the main directory of this source tree, or the
8− * OpenIB.org BSD license below:
9− *
10− * Redistribution and use in source and binary forms, with or
11− * without modification, are permitted provided that the following
12− * conditions are met:
13− *
14− * - Redistributions of source code must retain the above
15− * copyright notice, this list of conditions and the following
16− * disclaimer.
17− *
18− * - Redistributions in binary form must reproduce the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer in the documentation and/or other materials
21− * provided with the distribution.
22− *
23− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30− * SOFTWARE.
314 */
325
33−#if !defined(RDMA_CM_IB_H)
6+#ifndef RDMA_CM_IB_H
347 #define RDMA_CM_IB_H
358
369 #include <rdma/rdma_cm.h>
include/rdma/rdma_netlink.h+1−1
@@ -1,8 +1,8 @@
11 /* SPDX-License-Identifier: GPL-2.0 */
2+
23 #ifndef _RDMA_NETLINK_H
34 #define _RDMA_NETLINK_H
45
5−
66 #include <linux/netlink.h>
77 #include <uapi/rdma/rdma_netlink.h>
88
include/rdma/rdma_vt.h+4−46
@@ -1,53 +1,11 @@
1−#ifndef DEF_RDMA_VT_H
2−#define DEF_RDMA_VT_H
3−
1+/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */
42 /*
53 * Copyright(c) 2016 - 2019 Intel Corporation.
6− *
7− * This file is provided under a dual BSD/GPLv2 license. When using or
8− * redistributing this file, you may do so under either license.
9− *
10− * GPL LICENSE SUMMARY
11− *
12− * This program is free software; you can redistribute it and/or modify
13− * it under the terms of version 2 of the GNU General Public License as
14− * published by the Free Software Foundation.
15− *
16− * This program is distributed in the hope that it will be useful, but
17− * WITHOUT ANY WARRANTY; without even the implied warranty of
18− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19− * General Public License for more details.
20− *
21− * BSD LICENSE
22− *
23− * Redistribution and use in source and binary forms, with or without
24− * modification, are permitted provided that the following conditions
25− * are met:
26− *
27− * - Redistributions of source code must retain the above copyright
28− * notice, this list of conditions and the following disclaimer.
29− * - Redistributions in binary form must reproduce the above copyright
30− * notice, this list of conditions and the following disclaimer in
31− * the documentation and/or other materials provided with the
32− * distribution.
33− * - Neither the name of Intel Corporation nor the names of its
34− * contributors may be used to endorse or promote products derived
35− * from this software without specific prior written permission.
36− *
37− * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
38− * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
39− * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
40− * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
41− * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
42− * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
43− * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
44− * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
45− * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
46− * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
47− * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
48− *
494 */
505
6+#ifndef DEF_RDMA_VT_H
7+#define DEF_RDMA_VT_H
8+
519 /*
5210 * Structure that low level drivers will populate in order to register with the
5311 * rdmavt layer.
include/rdma/rdmavt_cq.h+4−49
@@ -1,56 +1,11 @@
1−#ifndef DEF_RDMAVT_INCCQ_H
2−#define DEF_RDMAVT_INCCQ_H
3−
1+/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */
42 /*
5− *
6− * This file is provided under a dual BSD/GPLv2 license. When using or
7− * redistributing this file, you may do so under either license.
8− *
9− * GPL LICENSE SUMMARY
10− *
113 * Copyright(c) 2016 - 2018 Intel Corporation.
12− *
13− * This program is free software; you can redistribute it and/or modify
14− * it under the terms of version 2 of the GNU General Public License as
15− * published by the Free Software Foundation.
16− *
17− * This program is distributed in the hope that it will be useful, but
18− * WITHOUT ANY WARRANTY; without even the implied warranty of
19− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20− * General Public License for more details.
21− *
22− * BSD LICENSE
23− *
24− * Copyright(c) 2015 Intel Corporation.
25− *
26− * Redistribution and use in source and binary forms, with or without
27− * modification, are permitted provided that the following conditions
28− * are met:
29− *
30− * - Redistributions of source code must retain the above copyright
31− * notice, this list of conditions and the following disclaimer.
32− * - Redistributions in binary form must reproduce the above copyright
33− * notice, this list of conditions and the following disclaimer in
34− * the documentation and/or other materials provided with the
35− * distribution.
36− * - Neither the name of Intel Corporation nor the names of its
37− * contributors may be used to endorse or promote products derived
38− * from this software without specific prior written permission.
39− *
40− * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
41− * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
42− * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
43− * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
44− * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
45− * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
46− * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
47− * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
48− * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
49− * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
50− * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
51− *
524 */
535
6+#ifndef DEF_RDMAVT_INCCQ_H
7+#define DEF_RDMAVT_INCCQ_H
8+
549 #include <linux/kthread.h>
5510 #include <rdma/ib_user_verbs.h>
5611 #include <rdma/ib_verbs.h>
include/rdma/rdmavt_mr.h+4−46
@@ -1,53 +1,11 @@
1−#ifndef DEF_RDMAVT_INCMR_H
2−#define DEF_RDMAVT_INCMR_H
3−
1+/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */
42 /*
53 * Copyright(c) 2016 Intel Corporation.
6− *
7− * This file is provided under a dual BSD/GPLv2 license. When using or
8− * redistributing this file, you may do so under either license.
9− *
10− * GPL LICENSE SUMMARY
11− *
12− * This program is free software; you can redistribute it and/or modify
13− * it under the terms of version 2 of the GNU General Public License as
14− * published by the Free Software Foundation.
15− *
16− * This program is distributed in the hope that it will be useful, but
17− * WITHOUT ANY WARRANTY; without even the implied warranty of
18− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19− * General Public License for more details.
20− *
21− * BSD LICENSE
22− *
23− * Redistribution and use in source and binary forms, with or without
24− * modification, are permitted provided that the following conditions
25− * are met:
26− *
27− * - Redistributions of source code must retain the above copyright
28− * notice, this list of conditions and the following disclaimer.
29− * - Redistributions in binary form must reproduce the above copyright
30− * notice, this list of conditions and the following disclaimer in
31− * the documentation and/or other materials provided with the
32− * distribution.
33− * - Neither the name of Intel Corporation nor the names of its
34− * contributors may be used to endorse or promote products derived
35− * from this software without specific prior written permission.
36− *
37− * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
38− * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
39− * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
40− * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
41− * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
42− * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
43− * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
44− * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
45− * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
46− * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
47− * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
48− *
494 */
505
6+#ifndef DEF_RDMAVT_INCMR_H
7+#define DEF_RDMAVT_INCMR_H
8+
519 /*
5210 * For Memory Regions. This stuff should probably be moved into rdmavt/mr.h once
5311 * drivers no longer need access to the MR directly.
include/rdma/rdmavt_qp.h+4−46
@@ -1,53 +1,11 @@
1−#ifndef DEF_RDMAVT_INCQP_H
2−#define DEF_RDMAVT_INCQP_H
3−
1+/* SPDX-License-Identifier: GPL-2.0 OR BSD-3-Clause */
42 /*
53 * Copyright(c) 2016 - 2020 Intel Corporation.
6− *
7− * This file is provided under a dual BSD/GPLv2 license. When using or
8− * redistributing this file, you may do so under either license.
9− *
10− * GPL LICENSE SUMMARY
11− *
12− * This program is free software; you can redistribute it and/or modify
13− * it under the terms of version 2 of the GNU General Public License as
14− * published by the Free Software Foundation.
15− *
16− * This program is distributed in the hope that it will be useful, but
17− * WITHOUT ANY WARRANTY; without even the implied warranty of
18− * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19− * General Public License for more details.
20− *
21− * BSD LICENSE
22− *
23− * Redistribution and use in source and binary forms, with or without
24− * modification, are permitted provided that the following conditions
25− * are met:
26− *
27− * - Redistributions of source code must retain the above copyright
28− * notice, this list of conditions and the following disclaimer.
29− * - Redistributions in binary form must reproduce the above copyright
30− * notice, this list of conditions and the following disclaimer in
31− * the documentation and/or other materials provided with the
32− * distribution.
33− * - Neither the name of Intel Corporation nor the names of its
34− * contributors may be used to endorse or promote products derived
35− * from this software without specific prior written permission.
36− *
37− * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
38− * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
39− * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
40− * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
41− * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
42− * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
43− * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
44− * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
45− * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
46− * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
47− * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
48− *
494 */
505
6+#ifndef DEF_RDMAVT_INCQP_H
7+#define DEF_RDMAVT_INCQP_H
8+
519 #include <rdma/rdma_vt.h>
5210 #include <rdma/ib_pack.h>
5311 #include <rdma/ib_verbs.h>
include/rdma/uverbs_ioctl.h+2−28
@@ -1,33 +1,6 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2017, Mellanox Technologies inc. All rights reserved.
3− *
4− * This software is available to you under a choice of one of two
5− * licenses. You may choose to be licensed under the terms of the GNU
6− * General Public License (GPL) Version 2, available from the file
7− * COPYING in the main directory of this source tree, or the
8− * OpenIB.org BSD license below:
9− *
10− * Redistribution and use in source and binary forms, with or
11− * without modification, are permitted provided that the following
12− * conditions are met:
13− *
14− * - Redistributions of source code must retain the above
15− * copyright notice, this list of conditions and the following
16− * disclaimer.
17− *
18− * - Redistributions in binary form must reproduce the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer in the documentation and/or other materials
21− * provided with the distribution.
22− *
23− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30− * SOFTWARE.
314 */
325
336 #ifndef _UVERBS_IOCTL_
@@ -652,6 +625,7 @@ struct uverbs_attr_bundle { · 618 unmodified lines
652625 struct ib_udata ucore;
653626 struct ib_uverbs_file *ufile;
654627 struct ib_ucontext *context;
628+ struct ib_uobject *uobject;
655629 DECLARE_BITMAP(attr_present, UVERBS_API_ATTR_BKEY_LEN);
656630 struct uverbs_attr attrs[];
657631 };
include/rdma/uverbs_named_ioctl.h+1−28
@@ -1,33 +1,6 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2018, Mellanox Technologies inc. All rights reserved.
3− *
4− * This software is available to you under a choice of one of two
5− * licenses. You may choose to be licensed under the terms of the GNU
6− * General Public License (GPL) Version 2, available from the file
7− * COPYING in the main directory of this source tree, or the
8− * OpenIB.org BSD license below:
9− *
10− * Redistribution and use in source and binary forms, with or
11− * without modification, are permitted provided that the following
12− * conditions are met:
13− *
14− * - Redistributions of source code must retain the above
15− * copyright notice, this list of conditions and the following
16− * disclaimer.
17− *
18− * - Redistributions in binary form must reproduce the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer in the documentation and/or other materials
21− * provided with the distribution.
22− *
23− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30− * SOFTWARE.
314 */
325
336 #ifndef _UVERBS_NAMED_IOCTL_
include/rdma/uverbs_std_types.h+15−28
@@ -1,33 +1,6 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2017, Mellanox Technologies inc. All rights reserved.
3− *
4− * This software is available to you under a choice of one of two
5− * licenses. You may choose to be licensed under the terms of the GNU
6− * General Public License (GPL) Version 2, available from the file
7− * COPYING in the main directory of this source tree, or the
8− * OpenIB.org BSD license below:
9− *
10− * Redistribution and use in source and binary forms, with or
11− * without modification, are permitted provided that the following
12− * conditions are met:
13− *
14− * - Redistributions of source code must retain the above
15− * copyright notice, this list of conditions and the following
16− * disclaimer.
17− *
18− * - Redistributions in binary form must reproduce the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer in the documentation and/or other materials
21− * provided with the distribution.
22− *
23− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30− * SOFTWARE.
314 */
325
336 #ifndef _UVERBS_STD_TYPES__
@@ -110,6 +83,20 @@ static inline void uobj_alloc_abort(struct ib_uobject *uobj, · 76 unmodified lines
11083 rdma_alloc_abort_uobject(uobj, attrs, false);
11184 }
11285
86+static inline void uobj_finalize_uobj_create(struct ib_uobject *uobj,
87+ struct uverbs_attr_bundle *attrs)
88+{
89+ /*
90+ * Tell the core code that the write() handler has completed
91+ * initializing the object and that the core should commit or
92+ * abort this object based upon the return code from the write()
93+ * method. Similar to what uverbs_finalize_uobj_create() does for
94+ * ioctl()
95+ */
96+ WARN_ON(attrs->uobject);
97+ attrs->uobject = uobj;
98+}
99+
113100 static inline struct ib_uobject *
114101 __uobj_alloc(const struct uverbs_api_object *obj,
115102 struct uverbs_attr_bundle *attrs, struct ib_device **ib_dev)
include/rdma/uverbs_types.h+1−28
@@ -1,33 +1,6 @@
1+/* SPDX-License-Identifier: GPL-2.0 OR Linux-OpenIB */
12 /*
23 * Copyright (c) 2017, Mellanox Technologies inc. All rights reserved.
3− *
4− * This software is available to you under a choice of one of two
5− * licenses. You may choose to be licensed under the terms of the GNU
6− * General Public License (GPL) Version 2, available from the file
7− * COPYING in the main directory of this source tree, or the
8− * OpenIB.org BSD license below:
9− *
10− * Redistribution and use in source and binary forms, with or
11− * without modification, are permitted provided that the following
12− * conditions are met:
13− *
14− * - Redistributions of source code must retain the above
15− * copyright notice, this list of conditions and the following
16− * disclaimer.
17− *
18− * - Redistributions in binary form must reproduce the above
19− * copyright notice, this list of conditions and the following
20− * disclaimer in the documentation and/or other materials
21− * provided with the distribution.
22− *
23− * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
24− * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
25− * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
26− * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS
27− * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
28− * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
29− * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
30− * SOFTWARE.
314 */
325
336 #ifndef _UVERBS_TYPES_
include/uapi/rdma/efa-abi.h+14−1
@@ -1,6 +1,6 @@
11 /* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-2-Clause) */
22 /*
3− * Copyright 2018-2019 Amazon.com, Inc. or its affiliates. All rights reserved.
3+ * Copyright 2018-2020 Amazon.com, Inc. or its affiliates. All rights reserved.
44 */
55
66 #ifndef EFA_ABI_USER_H
@@ -20,6 +20,16 @@ · 13 unmodified lines
2020 * hex bit offset of the field.
2121 */
2222
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+
28+struct efa_ibv_alloc_ucontext_cmd {
29+ __u32 comp_mask;
30+ __u8 reserved_20[4];
31+};
32+
2333 enum efa_ibv_user_cmds_supp_udata {
2434 EFA_USER_CMDS_SUPP_UDATA_QUERY_DEVICE = 1 << 0,
2535 EFA_USER_CMDS_SUPP_UDATA_CREATE_AH = 1 << 1,
@@ -31,6 +41,9 @@ struct efa_ibv_alloc_ucontext_resp { · 5 unmodified lines
3141 __u16 sub_cqs_per_cq;
3242 __u16 inline_buf_size;
3343 __u32 max_llq_size; /* bytes */
44+ __u16 max_tx_batch; /* units of 64 bytes */
45+ __u16 min_sq_wr;
46+ __u8 reserved_a0[4];
3447 };
3548
3649 struct efa_ibv_alloc_pd_resp {
include/uapi/rdma/ib_user_ioctl_cmds.h+15−0
@@ -69,6 +69,7 @@ enum uverbs_methods_device { · 68 unmodified lines
6969 UVERBS_METHOD_INFO_HANDLES,
7070 UVERBS_METHOD_QUERY_PORT,
7171 UVERBS_METHOD_GET_CONTEXT,
72+ UVERBS_METHOD_QUERY_CONTEXT,
7273 };
7374
7475 enum uverbs_attrs_invoke_write_cmd_attr_ids {
@@ -87,6 +88,11 @@ enum uverbs_attrs_get_context_attr_ids { · 12 unmodified lines
8788 UVERBS_ATTR_GET_CONTEXT_CORE_SUPPORT,
8889 };
8990
91+enum uverbs_attrs_query_context_attr_ids {
92+ UVERBS_ATTR_QUERY_CONTEXT_NUM_COMP_VECTORS,
93+ UVERBS_ATTR_QUERY_CONTEXT_CORE_SUPPORT,
94+};
95+
9096 enum uverbs_attrs_create_cq_cmd_attr_ids {
9197 UVERBS_ATTR_CREATE_CQ_HANDLE,
9298 UVERBS_ATTR_CREATE_CQ_CQE,
@@ -242,6 +248,7 @@ enum uverbs_methods_mr { · 149 unmodified lines
242248 UVERBS_METHOD_DM_MR_REG,
243249 UVERBS_METHOD_MR_DESTROY,
244250 UVERBS_METHOD_ADVISE_MR,
251+ UVERBS_METHOD_QUERY_MR,
245252 };
246253
247254 enum uverbs_attrs_mr_destroy_ids {
@@ -255,6 +262,14 @@ enum uverbs_attrs_advise_mr_cmd_attr_ids { · 7 unmodified lines
255262 UVERBS_ATTR_ADVISE_MR_SGE_LIST,
256263 };
257264
265+enum uverbs_attrs_query_mr_cmd_attr_ids {
266+ UVERBS_ATTR_QUERY_MR_HANDLE,
267+ UVERBS_ATTR_QUERY_MR_RESP_LKEY,
268+ UVERBS_ATTR_QUERY_MR_RESP_RKEY,
269+ UVERBS_ATTR_QUERY_MR_RESP_LENGTH,
270+ UVERBS_ATTR_QUERY_MR_RESP_IOVA,
271+};
272+
258273 enum uverbs_attrs_create_counters_cmd_attr_ids {
259274 UVERBS_ATTR_CREATE_COUNTERS_HANDLE,
260275 };
include/uapi/rdma/mlx5_user_ioctl_cmds.h+15−1
@@ -228,6 +228,10 @@ enum mlx5_ib_flow_matcher_methods { · 227 unmodified lines
228228 MLX5_IB_METHOD_FLOW_MATCHER_DESTROY,
229229 };
230230
231+enum mlx5_ib_device_query_context_attrs {
232+ MLX5_IB_ATTR_QUERY_CONTEXT_RESP_UCTX = (1U << UVERBS_ID_NS_SHIFT),
233+};
234+
231235 #define MLX5_IB_DW_MATCH_PARAM 0x80
232236
233237 struct mlx5_ib_match_params {
@@ -259,7 +263,7 @@ enum mlx5_ib_create_flow_attrs { · 25 unmodified lines
259263 MLX5_IB_ATTR_CREATE_FLOW_FLAGS,
260264 };
261265
262−enum mlx5_ib_destoy_flow_attrs {
266+enum mlx5_ib_destroy_flow_attrs {
263267 MLX5_IB_ATTR_DESTROY_FLOW_HANDLE = (1U << UVERBS_ID_NS_SHIFT),
264268 };
265269
@@ -286,4 +290,14 @@ enum mlx5_ib_create_flow_action_create_packet_reformat_attrs { · 20 unmodified lines
286290 MLX5_IB_ATTR_CREATE_PACKET_REFORMAT_DATA_BUF,
287291 };
288292
293+enum mlx5_ib_query_pd_attrs {
294+ MLX5_IB_ATTR_QUERY_PD_HANDLE = (1U << UVERBS_ID_NS_SHIFT),
295+ MLX5_IB_ATTR_QUERY_PD_RESP_PDN,
296+};
297+
298+enum mlx5_ib_pd_methods {
299+ MLX5_IB_METHOD_PD_QUERY = (1U << UVERBS_ID_NS_SHIFT),
300+
301+};
302+
289303 #endif
include/uapi/rdma/qedr-abi.h+7−3
@@ -39,8 +39,9 @@ · 38 unmodified lines
3939
4040 /* user kernel communication data structures. */
4141 enum qedr_alloc_ucontext_flags {
42− QEDR_ALLOC_UCTX_RESERVED = 1 << 0,
43− QEDR_ALLOC_UCTX_DB_REC = 1 << 1
42+ QEDR_ALLOC_UCTX_EDPM_MODE = 1 << 0,
43+ QEDR_ALLOC_UCTX_DB_REC = 1 << 1,
44+ QEDR_SUPPORT_DPM_SIZES = 1 << 2,
4445 };
4546
4647 struct qedr_alloc_ucontext_req {
@@ -50,13 +51,14 @@ struct qedr_alloc_ucontext_req { · 3 unmodified lines
5051
5152 #define QEDR_LDPM_MAX_SIZE (8192)
5253 #define QEDR_EDPM_TRANS_SIZE (64)
54+#define QEDR_EDPM_MAX_SIZE (ROCE_REQ_MAX_INLINE_DATA_SIZE)
5355
5456 enum qedr_rdma_dpm_type {
5557 QEDR_DPM_TYPE_NONE = 0,
5658 QEDR_DPM_TYPE_ROCE_ENHANCED = 1 << 0,
5759 QEDR_DPM_TYPE_ROCE_LEGACY = 1 << 1,
5860 QEDR_DPM_TYPE_IWARP_LEGACY = 1 << 2,
59− QEDR_DPM_TYPE_RESERVED = 1 << 3,
61+ QEDR_DPM_TYPE_ROCE_EDPM_MODE = 1 << 3,
6062 QEDR_DPM_SIZES_SET = 1 << 4,
6163 };
6264
@@ -77,6 +79,8 @@ struct qedr_alloc_ucontext_resp { · 14 unmodified lines
7779 __u16 ldpm_limit_size;
7880 __u8 edpm_trans_size;
7981 __u8 reserved;
82+ __u16 edpm_limit_size;
83+ __u8 padding[6];
8084 };
8185
8286 struct qedr_alloc_pd_ureq {
include/uapi/rdma/rdma_netlink.h+9−0
@@ -287,6 +287,12 @@ enum rdma_nldev_command { · 286 unmodified lines
287287
288288 RDMA_NLDEV_CMD_STAT_DEL,
289289
290+ RDMA_NLDEV_CMD_RES_QP_GET_RAW,
291+
292+ RDMA_NLDEV_CMD_RES_CQ_GET_RAW,
293+
294+ RDMA_NLDEV_CMD_RES_MR_GET_RAW,
295+
290296 RDMA_NLDEV_NUM_OPS
291297 };
292298
@@ -525,6 +531,8 @@ enum rdma_nldev_attr { · 232 unmodified lines
525531 */
526532 RDMA_NLDEV_ATTR_DEV_DIM, /* u8 */
527533
534+ RDMA_NLDEV_ATTR_RES_RAW, /* binary */
535+
528536 /*
529537 * Always the end
530538 */
@@ -561,5 +569,6 @@ enum rdma_nl_counter_mode { · 30 unmodified lines
561569 */
562570 enum rdma_nl_counter_mask {
563571 RDMA_COUNTER_MASK_QP_TYPE = 1,
572+ RDMA_COUNTER_MASK_PID = 1 << 1,
564573 };
565574 #endif /* _UAPI_RDMA_NETLINK_H */
include/uapi/rdma/rdma_user_ioctl.h+1−1
@@ -43,7 +43,7 @@ · 42 unmodified lines
4343
4444 /*
4545 * General blocks assignments
46− * It is closed on purpose do not expose it it user space
46+ * It is closed on purpose - do not expose it to user space
4747 * #define MAD_CMD_BASE 0x00
4848 * #define HFI1_CMD_BAS 0xE0
4949 */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t