diff --git a/drivers/infiniband/core/uverbs_cmd.c b/drivers/infiniband/core/uverbs_cmd.c index 4266d2e5eba423f20112d04e3a39f6262211809a..37824f68e37743f932dcd323641f47df8137379d 100644 --- a/drivers/infiniband/core/uverbs_cmd.c +++ b/drivers/infiniband/core/uverbs_cmd.c @@ -492,7 +492,6 @@ ssize_t ib_uverbs_reg_mr(struct ib_uverbs_file *file, err_unreg: ib_dereg_mr(mr); - atomic_dec(&pd->usecnt); err_up: mutex_unlock(&ib_uverbs_idr_mutex); @@ -986,11 +985,6 @@ ssize_t ib_uverbs_create_qp(struct ib_uverbs_file *file, err_destroy: ib_destroy_qp(qp); - atomic_dec(&pd->usecnt); - atomic_dec(&attr.send_cq->usecnt); - atomic_dec(&attr.recv_cq->usecnt); - if (attr.srq) - atomic_dec(&attr.srq->usecnt); err_up: mutex_unlock(&ib_uverbs_idr_mutex); @@ -1888,7 +1882,6 @@ ssize_t ib_uverbs_create_srq(struct ib_uverbs_file *file, err_destroy: ib_destroy_srq(srq); - atomic_dec(&pd->usecnt); err_up: mutex_unlock(&ib_uverbs_idr_mutex);