]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
RDMA/hns: Remove redundant 'attr_mask' in modify_qp_init_to_init()
authorYixing Liu <liuyixing1@huawei.com>
Thu, 22 Sep 2022 12:33:07 +0000 (20:33 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 9 Jan 2025 12:28:45 +0000 (13:28 +0100)
[ Upstream commit bb4874af19686019d0dafd58726ed7b4058663ca ]

The attr_mask variable is not used in the function,
so remove it.

Link: https://lore.kernel.org/r/20220922123315.3732205-5-xuhaoyue1@hisilicon.com
Signed-off-by: Yixing Liu <liuyixing1@huawei.com>
Signed-off-by: Haoyue Xu <xuhaoyue1@hisilicon.com>
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Stable-dep-of: 8673a6c2d9e4 ("RDMA/hns: Fix mapping error of zero-hop WQE buffer")
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/infiniband/hw/hns/hns_roce_hw_v2.c

index c013e96f956e20349482780074a2678abdad2825..6fdd563c9b9efe7fef771b5d0467fdc056a12463 100644 (file)
@@ -4073,7 +4073,6 @@ static inline int get_pdn(struct ib_pd *ib_pd)
 
 static void modify_qp_reset_to_init(struct ib_qp *ibqp,
                                    const struct ib_qp_attr *attr,
-                                   int attr_mask,
                                    struct hns_roce_v2_qp_context *context,
                                    struct hns_roce_v2_qp_context *qpc_mask)
 {
@@ -4137,7 +4136,7 @@ static void modify_qp_reset_to_init(struct ib_qp *ibqp,
 }
 
 static void modify_qp_init_to_init(struct ib_qp *ibqp,
-                                  const struct ib_qp_attr *attr, int attr_mask,
+                                  const struct ib_qp_attr *attr,
                                   struct hns_roce_v2_qp_context *context,
                                   struct hns_roce_v2_qp_context *qpc_mask)
 {
@@ -4792,11 +4791,9 @@ static int hns_roce_v2_set_abs_fields(struct ib_qp *ibqp,
 
        if (cur_state == IB_QPS_RESET && new_state == IB_QPS_INIT) {
                memset(qpc_mask, 0, hr_dev->caps.qpc_sz);
-               modify_qp_reset_to_init(ibqp, attr, attr_mask, context,
-                                       qpc_mask);
+               modify_qp_reset_to_init(ibqp, attr, context, qpc_mask);
        } else if (cur_state == IB_QPS_INIT && new_state == IB_QPS_INIT) {
-               modify_qp_init_to_init(ibqp, attr, attr_mask, context,
-                                      qpc_mask);
+               modify_qp_init_to_init(ibqp, attr, context, qpc_mask);
        } else if (cur_state == IB_QPS_INIT && new_state == IB_QPS_RTR) {
                ret = modify_qp_init_to_rtr(ibqp, attr, attr_mask, context,
                                            qpc_mask);