Pull rdma updates from Jason Gunthorpe: "Quite a small cycle this time, even with the rc8. I suppose everyone went to sleep over xmas. - Minor driver updates for hfi1, cxgb4, erdma, hns, irdma, mlx5, siw, mana - inline CQE support for hns - Have mlx5 display device error codes - Pinned DMABUF support for irdma - Continued rxe cleanups, particularly converting the MRs to use xarray - Improvements to what can be cached in the mlx5 mkey cache" * tag 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rdma/rdma: (61 commits) IB/mlx5: Extend debug control for CC parameters IB/hfi1: Fix sdma.h tx->num_descs off-by-one errors IB/hfi1: Fix math bugs in hfi1_can_pin_pages() RDMA/irdma: Add support for dmabuf pin memory regions RDMA/mlx5: Use query_special_contexts for mkeys net/mlx5e: Use query_special_contexts for mkeys net/mlx5: Change define name for 0x100 lkey value net/mlx5: Expose bits for querying special mkeys RDMA/rxe: Fix missing memory barriers in rxe_queue.h RDMA/mana_ib: Fix a bug when the PF indicates more entries for registering memory on first packet RDMA/rxe: Remove rxe_alloc() RDMA/cma: Distinguish between sockaddr_in and sockaddr_in6 by size Subject: RDMA/rxe: Handle zero length rdma iw_cxgb4: Fix potential NULL dereference in c4iw_fill_res_cm_id_entry() RDMA/mlx5: Use rdma_umem_for_each_dma_block() RDMA/umem: Remove unused 'work' member from struct ib_umem RDMA/irdma: Cap MSIX used to online CPUs + 1 RDMA/mlx5: Check reg_create() create for errors RDMA/restrack: Correct spelling RDMA/cxgb4: Fix potential null-ptr-deref in pass_establish() ...
Showing the changes to include (10 of 65 files). Show all
Unified · Split
| @@ -504,4 +504,5 @@ static inline u16 folded_qp(u32 q) · 503 unmodified lines | |||
| 504 | 504 | ||
| 505 | u16 mlx4_qp_roce_entropy(struct mlx4_dev *dev, u32 qpn); | 505 | u16 mlx4_qp_roce_entropy(struct mlx4_dev *dev, u32 qpn); |
| 506 | 506 | ||
| 507 | void mlx4_put_qp(struct mlx4_qp *qp); | ||
| 507 | #endif /* MLX4_QP_H */ | 508 | #endif /* MLX4_QP_H */ |
| @@ -742,7 +742,6 @@ enum { · 741 unmodified lines | |||
| 742 | 742 | ||
| 743 | enum { | 743 | enum { |
| 744 | MKEY_CACHE_LAST_STD_ENTRY = 20, | 744 | MKEY_CACHE_LAST_STD_ENTRY = 20, |
| 745 | MLX5_IMR_MTT_CACHE_ENTRY, | ||
| 746 | MLX5_IMR_KSM_CACHE_ENTRY, | 745 | MLX5_IMR_KSM_CACHE_ENTRY, |
| 747 | MAX_MKEY_CACHE_ENTRIES | 746 | MAX_MKEY_CACHE_ENTRIES |
| 748 | }; | 747 | }; |
| @@ -1510,7 +1510,9 @@ struct mlx5_ifc_cmd_hca_cap_bits { · 1509 unmodified lines | |||
| 1510 | u8 relaxed_ordering_write[0x1]; | 1510 | u8 relaxed_ordering_write[0x1]; |
| 1511 | u8 relaxed_ordering_read[0x1]; | 1511 | u8 relaxed_ordering_read[0x1]; |
| 1512 | u8 log_max_mkey[0x6]; | 1512 | u8 log_max_mkey[0x6]; |
| 1513 | u8 reserved_at_f0[0x8]; | 1513 | u8 reserved_at_f0[0x6]; |
| 1514 | u8 terminate_scatter_list_mkey[0x1]; | ||
| 1515 | u8 repeated_mkey[0x1]; | ||
| 1514 | u8 dump_fill_mkey[0x1]; | 1516 | u8 dump_fill_mkey[0x1]; |
| 1515 | u8 reserved_at_f9[0x2]; | 1517 | u8 reserved_at_f9[0x2]; |
| 1516 | u8 fast_teardown[0x1]; | 1518 | u8 fast_teardown[0x1]; |
| @@ -2183,6 +2185,17 @@ struct mlx5_ifc_cong_control_r_roce_ecn_rp_bits { · 666 unmodified lines | |||
| 2183 | u8 reserved_at_360[0x4a0]; | 2185 | u8 reserved_at_360[0x4a0]; |
| 2184 | }; | 2186 | }; |
| 2185 | 2187 | ||
| 2188 | struct mlx5_ifc_cong_control_r_roce_general_bits { | ||
| 2189 | u8 reserved_at_0[0x80]; | ||
| 2190 | |||
| 2191 | u8 reserved_at_80[0x10]; | ||
| 2192 | u8 rtt_resp_dscp_valid[0x1]; | ||
| 2193 | u8 reserved_at_91[0x9]; | ||
| 2194 | u8 rtt_resp_dscp[0x6]; | ||
| 2195 | |||
| 2196 | u8 reserved_at_a0[0x760]; | ||
| 2197 | }; | ||
| 2198 | |||
| 2186 | struct mlx5_ifc_cong_control_802_1qau_rp_bits { | 2199 | struct mlx5_ifc_cong_control_802_1qau_rp_bits { |
| 2187 | u8 reserved_at_0[0x80]; | 2200 | u8 reserved_at_0[0x80]; |
| 2188 | 2201 | ||
| @@ -4353,6 +4366,7 @@ union mlx5_ifc_cong_control_roce_ecn_auto_bits { · 2164 unmodified lines | |||
| 4353 | struct mlx5_ifc_cong_control_802_1qau_rp_bits cong_control_802_1qau_rp; | 4366 | struct mlx5_ifc_cong_control_802_1qau_rp_bits cong_control_802_1qau_rp; |
| 4354 | struct mlx5_ifc_cong_control_r_roce_ecn_rp_bits cong_control_r_roce_ecn_rp; | 4367 | struct mlx5_ifc_cong_control_r_roce_ecn_rp_bits cong_control_r_roce_ecn_rp; |
| 4355 | struct mlx5_ifc_cong_control_r_roce_ecn_np_bits cong_control_r_roce_ecn_np; | 4368 | struct mlx5_ifc_cong_control_r_roce_ecn_np_bits cong_control_r_roce_ecn_np; |
| 4369 | struct mlx5_ifc_cong_control_r_roce_general_bits cong_control_r_roce_general; | ||
| 4356 | u8 reserved_at_0[0x800]; | 4370 | u8 reserved_at_0[0x800]; |
| 4357 | }; | 4371 | }; |
| 4358 | 4372 | ||
| @@ -5261,7 +5275,11 @@ struct mlx5_ifc_query_special_contexts_out_bits { · 902 unmodified lines | |||
| 5261 | 5275 | ||
| 5262 | u8 null_mkey[0x20]; | 5276 | u8 null_mkey[0x20]; |
| 5263 | 5277 | ||
| 5264 | u8 reserved_at_a0[0x60]; | 5278 | u8 terminate_scatter_list_mkey[0x20]; |
| 5279 | |||
| 5280 | u8 repeated_mkey[0x20]; | ||
| 5281 | |||
| 5282 | u8 reserved_at_a0[0x20]; | ||
| 5265 | }; | 5283 | }; |
| 5266 | 5284 | ||
| 5267 | struct mlx5_ifc_query_special_contexts_in_bits { | 5285 | struct mlx5_ifc_query_special_contexts_in_bits { |
| @@ -36,7 +36,7 @@ · 35 unmodified lines | |||
| 36 | #include <linux/mlx5/device.h> | 36 | #include <linux/mlx5/device.h> |
| 37 | #include <linux/mlx5/driver.h> | 37 | #include <linux/mlx5/driver.h> |
| 38 | 38 | ||
| 39 | #define MLX5_INVALID_LKEY 0x100 | 39 | #define MLX5_TERMINATE_SCATTER_LIST_LKEY cpu_to_be32(0x100) |
| 40 | /* UMR (3 WQE_BB's) + SIG (3 WQE_BB's) + PSV (mem) + PSV (wire) */ | 40 | /* UMR (3 WQE_BB's) + SIG (3 WQE_BB's) + PSV (mem) + PSV (wire) */ |
| 41 | #define MLX5_SIG_WQE_SIZE (MLX5_SEND_WQE_BB * 8) | 41 | #define MLX5_SIG_WQE_SIZE (MLX5_SEND_WQE_BB * 8) |
| 42 | #define MLX5_DIF_SIZE 8 | 42 | #define MLX5_DIF_SIZE 8 |
| @@ -414,7 +414,7 @@ int ib_sa_path_rec_get(struct ib_sa_client *client, struct ib_device *device, · 413 unmodified lines | |||
| 414 | ib_sa_comp_mask comp_mask, unsigned long timeout_ms, | 414 | ib_sa_comp_mask comp_mask, unsigned long timeout_ms, |
| 415 | gfp_t gfp_mask, | 415 | gfp_t gfp_mask, |
| 416 | void (*callback)(int status, struct sa_path_rec *resp, | 416 | void (*callback)(int status, struct sa_path_rec *resp, |
| 417 | int num_prs, void *context), | 417 | unsigned int num_prs, void *context), |
| 418 | void *context, struct ib_sa_query **query); | 418 | void *context, struct ib_sa_query **query); |
| 419 | 419 | ||
| 420 | struct ib_sa_multicast { | 420 | struct ib_sa_multicast { |
| @@ -25,7 +25,6 @@ struct ib_umem { · 24 unmodified lines | |||
| 25 | u32 writable : 1; | 25 | u32 writable : 1; |
| 26 | u32 is_odp : 1; | 26 | u32 is_odp : 1; |
| 27 | u32 is_dmabuf : 1; | 27 | u32 is_dmabuf : 1; |
| 28 | struct work_struct work; | ||
| 29 | struct sg_append_table sgt_append; | 28 | struct sg_append_table sgt_append; |
| 30 | }; | 29 | }; |
| 31 | 30 | ||
| @@ -1168,7 +1168,7 @@ enum ib_qp_create_flags { · 1167 unmodified lines | |||
| 1168 | */ | 1168 | */ |
| 1169 | 1169 | ||
| 1170 | struct ib_qp_init_attr { | 1170 | struct ib_qp_init_attr { |
| 1171 | /* Consumer's event_handler callback must not block */ | 1171 | /* This callback occurs in workqueue context */ |
| 1172 | void (*event_handler)(struct ib_event *, void *); | 1172 | void (*event_handler)(struct ib_event *, void *); |
| 1173 | 1173 | ||
| 1174 | void *qp_context; | 1174 | void *qp_context; |
| @@ -49,7 +49,6 @@ struct rdma_addr { · 48 unmodified lines | |||
| 49 | struct rdma_dev_addr dev_addr; | 49 | struct rdma_dev_addr dev_addr; |
| 50 | }; | 50 | }; |
| 51 | 51 | ||
| 52 | #define RDMA_PRIMARY_PATH_MAX_REC_NUM 3 | ||
| 53 | struct rdma_route { | 52 | struct rdma_route { |
| 54 | struct rdma_addr addr; | 53 | struct rdma_addr addr; |
| 55 | struct sa_path_rec *path_rec; | 54 | struct sa_path_rec *path_rec; |
| @@ -162,8 +162,8 @@ struct rdma_restrack_entry *rdma_restrack_get_byid(struct ib_device *dev, · 161 unmodified lines | |||
| 162 | * rdma_restrack_no_track() - don't add resource to the DB | 162 | * rdma_restrack_no_track() - don't add resource to the DB |
| 163 | * @res: resource entry | 163 | * @res: resource entry |
| 164 | * | 164 | * |
| 165 | * Every user of thie API should be cross examined. | 165 | * Every user of this API should be cross examined. |
| 166 | * Probaby you don't need to use this function. | 166 | * Probably you don't need to use this function. |
| 167 | */ | 167 | */ |
| 168 | static inline void rdma_restrack_no_track(struct rdma_restrack_entry *res) | 168 | static inline void rdma_restrack_no_track(struct rdma_restrack_entry *res) |
| 169 | { | 169 | { |
| @@ -87,10 +87,14 @@ struct hns_roce_ib_create_qp_resp { · 86 unmodified lines | |||
| 87 | 87 | ||
| 88 | enum { | 88 | enum { |
| 89 | HNS_ROCE_EXSGE_FLAGS = 1 << 0, | 89 | HNS_ROCE_EXSGE_FLAGS = 1 << 0, |
| 90 | HNS_ROCE_RQ_INLINE_FLAGS = 1 << 1, | ||
| 91 | HNS_ROCE_CQE_INLINE_FLAGS = 1 << 2, | ||
| 90 | }; | 92 | }; |
| 91 | 93 | ||
| 92 | enum { | 94 | enum { |
| 93 | HNS_ROCE_RSP_EXSGE_FLAGS = 1 << 0, | 95 | HNS_ROCE_RSP_EXSGE_FLAGS = 1 << 0, |
| 96 | HNS_ROCE_RSP_RQ_INLINE_FLAGS = 1 << 1, | ||
| 97 | HNS_ROCE_RSP_CQE_INLINE_FLAGS = 1 << 2, | ||
| 94 | }; | 98 | }; |
| 95 | 99 | ||
| 96 | struct hns_roce_ib_alloc_ucontext_resp { | 100 | struct hns_roce_ib_alloc_ucontext_resp { |