Message ID | 20211119140208.40416-8-liangwenpeng@huawei.com (mailing list archive) |
---|---|
State | Changes Requested |
Delegated to: | Jason Gunthorpe |
Headers | show |
Series | RDMA/hns: Cleanup for clearing static warnings | expand |
On Fri, Nov 19, 2021 at 10:02:06PM +0800, Wenpeng Liang wrote: > From: Xinhao Liu <liuxinhao5@hisilicon.com> > > If the return value of the function is not used, then void should be > added. AFAIK we don't do this in the kernel Jason
On 2021/11/20 1:28, Jason Gunthorpe wrote: > On Fri, Nov 19, 2021 at 10:02:06PM +0800, Wenpeng Liang wrote: >> From: Xinhao Liu <liuxinhao5@hisilicon.com> >> >> If the return value of the function is not used, then void should be >> added. > > AFAIK we don't do this in the kernel > > Jason > . > Thanks for your comments, I will fix it in v2. Thanks Wenpeng
diff --git a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c index d8788819b827..978913fc7587 100644 --- a/drivers/infiniband/hw/hns/hns_roce_hw_v2.c +++ b/drivers/infiniband/hw/hns/hns_roce_hw_v2.c @@ -1509,7 +1509,7 @@ static void hns_roce_free_vf_resource(struct hns_roce_dev *hr_dev, int vf_id) desc[0].flag |= cpu_to_le16(HNS_ROCE_CMD_FLAG_NEXT); hns_roce_cmq_setup_basic_desc(&desc[1], opcode, false); hr_reg_write(req_a, FUNC_RES_A_VF_ID, vf_id); - hns_roce_cmq_send(hr_dev, desc, 2); + (void)hns_roce_cmq_send(hr_dev, desc, 2); } static void hns_roce_function_clear(struct hns_roce_dev *hr_dev)