RDMA/hns: Fix cqn type and init resp

This patch changes the type of cqn from u32 to u64 to keep
userspace and kernel consistent, initializes resp both for
cq and qp to zeros, and also changes the condition judgment
of outlen considering future caps extension.

Suggested-by: Jason Gunthorpe <jgg@mellanox.com>
Fixes: e088a685ea (hns: Support rq record doorbell for the user space)
Fixes: 9b44703d0a (hns: Support cq record doorbell for the user space)
Signed-off-by: Yixian Liu <liuyixian@huawei.com>
Signed-off-by: Lijun Ou <oulijun@huawei.com>
Signed-off-by: Wei Hu (Xavier) <xavier.huwei@huawei.com>
Signed-off-by: Shaobo Xu <xushaobo2@huawei.com>
Signed-off-by: Jason Gunthorpe <jgg@mellanox.com>
This commit is contained in:
Yixian Liu
2018-03-15 15:23:14 +08:00
committed by Jason Gunthorpe
parent e41a7c4194
commit 7b48221cf4
3 changed files with 12 additions and 14 deletions

View File

@@ -42,8 +42,7 @@ struct hns_roce_ib_create_cq {
};
struct hns_roce_ib_create_cq_resp {
__u32 cqn;
__u32 reserved;
__u64 cqn; /* Only 32 bits used, 64 for compat */
__u64 cap_flags;
};