Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 761fc376 authored by Jason Gunthorpe's avatar Jason Gunthorpe
Browse files

RDMA/cxgb3: Use structs to describe the uABI instead of opencoding



Open coding a loose value is not acceptable for describing the uABI in
RDMA. Provide the missing struct.

Acked-by: default avatarSteve Wise <swise@opengridcomputing.com>
Signed-off-by: default avatarJason Gunthorpe <jgg@mellanox.com>
parent 97d82a48
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -440,7 +440,9 @@ static struct ib_pd *iwch_allocate_pd(struct ib_device *ibdev,
	php->pdid = pdid;
	php->rhp = rhp;
	if (context) {
		if (ib_copy_to_udata(udata, &php->pdid, sizeof (__u32))) {
		struct iwch_alloc_pd_resp resp = {.pdid = php->pdid};

		if (ib_copy_to_udata(udata, &resp, sizeof(resp))) {
			iwch_deallocate_pd(&php->ibpd);
			return ERR_PTR(-EFAULT);
		}
+5 −0
Original line number Diff line number Diff line
@@ -74,4 +74,9 @@ struct iwch_create_qp_resp {
struct iwch_reg_user_mr_resp {
	__u32 pbl_addr;
};

struct iwch_alloc_pd_resp {
	__u32 pdid;
};

#endif /* CXGB3_ABI_USER_H */