From: "xuhaoyue (A)" <xuhaoyue1@hisilicon.com>
To: Jason Gunthorpe <jgg@nvidia.com>
Cc: <leon@kernel.org>, <linux-rdma@vger.kernel.org>, <linuxarm@huawei.com>
Subject: Re: [PATCH v2 for-rc 3/5] RDMA/hns: Remove enable rq inline in kernel and add compatibility handling
Date: Mon, 31 Oct 2022 16:23:14 +0800 [thread overview]
Message-ID: <9b50dae1-e448-047b-8a54-489ff120f00c@hisilicon.com> (raw)
In-Reply-To: <Y1wF68CgChG+hM87@nvidia.com>
This bit is used to prevent compatibility issues in the old kernel. It is not for compatibility with userspace.
It should be a bugfix. I will separate this into a new bugfix patch.
I will change the name to __HNS_ROCE_CAP_FLAG_RQ_INLINE in V3.
On 2022/10/29 0:40:11, Jason Gunthorpe wrote:
> On Wed, Oct 26, 2022 at 05:50:52PM +0800, Haoyue Xu wrote:
>> From: Luoyouming <luoyouming@huawei.com>
>>
>> The rq inline makes some changes as follows, Firstly, it is only
>> used in user space. Secondly, it should notify hardware in QP RTR
>> status. Thirdly, Add compatibility processing between different
>> user space and kernel space. Change the HNS_ROCE_CAP_FLAG_RQ_INLINE
>> to a new bit to prevent old kernel spaces / spaced from enabling
>> rq inline.
>>
>> Signed-off-by: Luoyouming <luoyouming@huawei.com>
>> Signed-off-by: Haoyue Xu <xuhaoyue1@hisilicon.com>
>> ---
>> drivers/infiniband/hw/hns/hns_roce_device.h | 6 +++--
>> drivers/infiniband/hw/hns/hns_roce_hw_v2.c | 28 +++++++++++++--------
>> drivers/infiniband/hw/hns/hns_roce_main.c | 5 ++++
>> drivers/infiniband/hw/hns/hns_roce_qp.c | 2 +-
>> include/uapi/rdma/hns-abi.h | 2 ++
>> 5 files changed, 30 insertions(+), 13 deletions(-)
>>
>> diff --git a/drivers/infiniband/hw/hns/hns_roce_device.h b/drivers/infiniband/hw/hns/hns_roce_device.h
>> index f701cc86896b..9ce053fe737d 100644
>> --- a/drivers/infiniband/hw/hns/hns_roce_device.h
>> +++ b/drivers/infiniband/hw/hns/hns_roce_device.h
>> @@ -132,7 +132,8 @@ enum hns_roce_event {
>> enum {
>> HNS_ROCE_CAP_FLAG_REREG_MR = BIT(0),
>> HNS_ROCE_CAP_FLAG_ROCE_V1_V2 = BIT(1),
>> - HNS_ROCE_CAP_FLAG_RQ_INLINE = BIT(2),
>> + /* discard this bit, reserved for compatibility */
>> + HNS_ROCE_CAP_FLAG_DISCARD = BIT(2),
>
> If it is for compatability with userspace why is this enum not under
> include/uapi? Something has gone wrong here, please fix it.
>
> Also, it is better to name this __HNS_ROCE_CAP_FLAG_RQ_INLINE to
> indicate it is not used instead of 'discard'
>
> Jason
> .
>
next prev parent reply other threads:[~2022-10-31 8:23 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-10-26 9:50 [PATCH v2 for-rc 0/5] Fix sge_num bug and add cqe inline, refactor rq inline Haoyue Xu
2022-10-26 9:50 ` [PATCH v2 for-rc 1/5] RDMA/hns: Fix ext_sge num error when post send Haoyue Xu
2022-10-26 9:50 ` [PATCH v2 for-rc 2/5] RDMA/hns: Fix the problem of sge nums Haoyue Xu
2022-10-28 16:42 ` Jason Gunthorpe
2022-10-29 9:47 ` xuhaoyue (A)
2022-10-26 9:50 ` [PATCH v2 for-rc 3/5] RDMA/hns: Remove enable rq inline in kernel and add compatibility handling Haoyue Xu
2022-10-28 16:40 ` Jason Gunthorpe
2022-10-31 8:23 ` xuhaoyue (A) [this message]
2022-10-31 12:07 ` Jason Gunthorpe
2022-11-03 12:50 ` xuhaoyue (A)
2022-10-26 9:50 ` [PATCH v2 for-rc 4/5] RDMA/hns: Remove rq inline in kernel Haoyue Xu
2022-10-26 9:50 ` [PATCH v2 for-rc 5/5] RDMA/hns: Support cqe inline in user space Haoyue Xu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=9b50dae1-e448-047b-8a54-489ff120f00c@hisilicon.com \
--to=xuhaoyue1@hisilicon.com \
--cc=jgg@nvidia.com \
--cc=leon@kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=linuxarm@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox