From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751970AbdI1QOI (ORCPT ); Thu, 28 Sep 2017 12:14:08 -0400 Received: from smtprz14.163.net ([106.3.154.247]:50388 "HELO smtp.tom.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with SMTP id S1751710AbdI1QOG (ORCPT ); Thu, 28 Sep 2017 12:14:06 -0400 Authentication-Results: my-fxspam02 smtp.user=xavier.huwei@tom.com; auth=pass (LOGIN) Subject: Re: [PATCH for-next 8/9] RDMA/hns: Remove unused struct members in hns-abi.h To: Leon Romanovsky , "Wei Hu (Xavier)" References: <1506574654-56699-1-git-send-email-xavier.huwei@huawei.com> <1506574654-56699-9-git-send-email-xavier.huwei@huawei.com> <20170928090203.GS2297@mtr-leonro.local> <59CCE378.6070209@huawei.com> <20170928130437.GV2297@mtr-leonro.local> Cc: dledford@redhat.com, linux-rdma@vger.kernel.org, lijun_nudt@163.com, oulijun@huawei.com, charles.chenxin@huawei.com, liuyixian@huawei.com, xushaobo2@huawei.com, zhangxiping3@huawei.com, linuxarm@huawei.com, linux-kernel@vger.kernel.org, shaobohsu@163.com From: "Wei Hu (Xavier)" Message-ID: <3bdd5f2d-d42a-5d54-41a3-a01abecb7a10@tom.com> Date: Fri, 29 Sep 2017 00:12:57 +0800 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: <20170928130437.GV2297@mtr-leonro.local> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2017/9/28 21:04, Leon Romanovsky wrote: > On Thu, Sep 28, 2017 at 07:56:40PM +0800, Wei Hu (Xavier) wrote: >> >> On 2017/9/28 17:02, Leon Romanovsky wrote: >>> On Thu, Sep 28, 2017 at 12:57:33PM +0800, Wei Hu (Xavier) wrote: >>>> From: Lijun Ou >>>> >>>> This patch mainly deletes some unused struct members for >>>> hns_roce_ib_create_qp in order to match libhns, because >>>> the num of struct members of hns_roce_ib_create_qp must >>>> be the same with hns_roce_create_qp in libhns. >>>> >>>> Signed-off-by: Lijun Ou >>>> Signed-off-by: Wei Hu (Xavier) >>>> Signed-off-by: Shaobo Xu >>>> --- >>>> include/uapi/rdma/hns-abi.h | 2 -- >>>> 1 file changed, 2 deletions(-) >>>> >>>> diff --git a/include/uapi/rdma/hns-abi.h b/include/uapi/rdma/hns-abi.h >>>> index 5d74019..79251b6 100644 >>>> --- a/include/uapi/rdma/hns-abi.h >>>> +++ b/include/uapi/rdma/hns-abi.h >>>> @@ -41,10 +41,8 @@ struct hns_roce_ib_create_cq { >>>> >>>> struct hns_roce_ib_create_qp { >>>> __u64 buf_addr; >>>> - __u64 db_addr; >>>> __u8 log_sq_bb_count; >>>> __u8 log_sq_stride; >>>> - __u8 sq_no_prefetch; >>>> __u8 reserved[5]; >>>> }; >>> It is classical UAPI breakage which kernel tries to avoid. >>> >>> In RDMA, we do allow rename of fields from reserved to something, but >>> don't allow binary layout change. >>> >>> NAK to this change. >>> >>> Thanks >> Hi, Leon >> Now there is an inconsistency between hns_roce_ib_create_qp in kernel >> driver and hns_roce_create_qp in libhns as below: >> >> struct hns_roce_create_qp { >> struct ibv_create_qp ibv_cmd; >> __u64 buf_addr; >> __u8 log_sq_bb_count; >> __u8 log_sq_stride; >> __u8 reserved[5]; >> }; >> It is better to modify hns_roce_create_qp in libhns, right? > Yes, it can work, because it is user space problem, where you used wrong > structure. > > Thanks Thanks, Leon I will pull it out off this series in patch v2. >> Thanks >> >> Regards >> Wei Hu >>>> -- >>>> 1.9.1 >>>> >>>> -- >>>> To unsubscribe from this list: send the line "unsubscribe linux-rdma" in >>>> the body of a message to majordomo@vger.kernel.org >>>> More majordomo info at http://vger.kernel.org/majordomo-info.html >> >> -- >> To unsubscribe from this list: send the line "unsubscribe linux-rdma" in >> the body of a message to majordomo@vger.kernel.org >> More majordomo info at http://vger.kernel.org/majordomo-info.html