* [PATCH net-next] Revert "net: hns3: add void before function which don't receive ret"
@ 2021-12-05 11:51 Leon Romanovsky
2021-12-05 12:18 ` Leon Romanovsky
0 siblings, 1 reply; 6+ messages in thread
From: Leon Romanovsky @ 2021-12-05 11:51 UTC (permalink / raw)
To: David S . Miller, Jakub Kicinski
Cc: Leon Romanovsky, linux-kernel, netdev, Salil Mehta, Yisen Zhuang
From: Leon Romanovsky <leonro@nvidia.com>
There are two issues with this patch:
1. devlink_register() doesn't return any value. It is already void.
2. It is not kernel coding at all to cast return type to void.
This reverts commit 5ac4f180bd07116c1e57858bc3f6741adbca3eb6.
Link: https://lore.kernel.org/all/Yan8VDXC0BtBRVGz@unreal
Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
---
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c | 2 +-
drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c
index 9c3199d3c8ee..4c441e6a5082 100644
--- a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c
+++ b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c
@@ -120,7 +120,7 @@ int hclge_devlink_init(struct hclge_dev *hdev)
hdev->devlink = devlink;
devlink_set_features(devlink, DEVLINK_F_RELOAD);
- (void)devlink_register(devlink);
+ devlink_register(devlink);
return 0;
}
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c b/drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c
index 75d2926729d3..fdc19868b818 100644
--- a/drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c
+++ b/drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c
@@ -122,7 +122,7 @@ int hclgevf_devlink_init(struct hclgevf_dev *hdev)
hdev->devlink = devlink;
devlink_set_features(devlink, DEVLINK_F_RELOAD);
- (void)devlink_register(devlink);
+ devlink_register(devlink);
return 0;
}
--
2.33.1
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH net-next] Revert "net: hns3: add void before function which don't receive ret"
2021-12-05 11:51 [PATCH net-next] Revert "net: hns3: add void before function which don't receive ret" Leon Romanovsky
@ 2021-12-05 12:18 ` Leon Romanovsky
2021-12-07 0:34 ` Jakub Kicinski
0 siblings, 1 reply; 6+ messages in thread
From: Leon Romanovsky @ 2021-12-05 12:18 UTC (permalink / raw)
To: David S . Miller, Jakub Kicinski
Cc: linux-kernel, netdev, Salil Mehta, Yisen Zhuang
On Sun, Dec 05, 2021 at 01:51:37PM +0200, Leon Romanovsky wrote:
> From: Leon Romanovsky <leonro@nvidia.com>
>
> There are two issues with this patch:
> 1. devlink_register() doesn't return any value. It is already void.
> 2. It is not kernel coding at all to cast return type to void.
>
> This reverts commit 5ac4f180bd07116c1e57858bc3f6741adbca3eb6.
>
> Link: https://lore.kernel.org/all/Yan8VDXC0BtBRVGz@unreal
> Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
> ---
> drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c | 2 +-
> drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c | 2 +-
> 2 files changed, 2 insertions(+), 2 deletions(-)
It was already sent, but not merged yet.
https://lore.kernel.org/all/20211204012448.51360-1-huangguangbin2@huawei.com
Thanks
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH net-next] Revert "net: hns3: add void before function which don't receive ret"
2021-12-05 12:18 ` Leon Romanovsky
@ 2021-12-07 0:34 ` Jakub Kicinski
2021-12-07 1:19 ` huangguangbin (A)
0 siblings, 1 reply; 6+ messages in thread
From: Jakub Kicinski @ 2021-12-07 0:34 UTC (permalink / raw)
To: Leon Romanovsky, Guangbin Huang
Cc: David S . Miller, linux-kernel, netdev, Salil Mehta, Yisen Zhuang
On Sun, 5 Dec 2021 14:18:21 +0200 Leon Romanovsky wrote:
> On Sun, Dec 05, 2021 at 01:51:37PM +0200, Leon Romanovsky wrote:
> > From: Leon Romanovsky <leonro@nvidia.com>
> >
> > There are two issues with this patch:
> > 1. devlink_register() doesn't return any value. It is already void.
> > 2. It is not kernel coding at all to cast return type to void.
> >
> > This reverts commit 5ac4f180bd07116c1e57858bc3f6741adbca3eb6.
> >
> > Link: https://lore.kernel.org/all/Yan8VDXC0BtBRVGz@unreal
> > Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
> > ---
> > drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c | 2 +-
> > drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c | 2 +-
> > 2 files changed, 2 insertions(+), 2 deletions(-)
>
> It was already sent, but not merged yet.
> https://lore.kernel.org/all/20211204012448.51360-1-huangguangbin2@huawei.com
Indeed, Guangbin in the future please make sure to CC the person whose
feedback the patches are based on.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PATCH net-next] Revert "net: hns3: add void before function which don't receive ret"
2021-12-07 0:34 ` Jakub Kicinski
@ 2021-12-07 1:19 ` huangguangbin (A)
0 siblings, 0 replies; 6+ messages in thread
From: huangguangbin (A) @ 2021-12-07 1:19 UTC (permalink / raw)
To: Jakub Kicinski, Leon Romanovsky
Cc: David S . Miller, linux-kernel, netdev, Salil Mehta, Yisen Zhuang
On 2021/12/7 8:34, Jakub Kicinski wrote:
> On Sun, 5 Dec 2021 14:18:21 +0200 Leon Romanovsky wrote:
>> On Sun, Dec 05, 2021 at 01:51:37PM +0200, Leon Romanovsky wrote:
>>> From: Leon Romanovsky <leonro@nvidia.com>
>>>
>>> There are two issues with this patch:
>>> 1. devlink_register() doesn't return any value. It is already void.
>>> 2. It is not kernel coding at all to cast return type to void.
>>>
>>> This reverts commit 5ac4f180bd07116c1e57858bc3f6741adbca3eb6.
>>>
>>> Link: https://lore.kernel.org/all/Yan8VDXC0BtBRVGz@unreal
>>> Signed-off-by: Leon Romanovsky <leonro@nvidia.com>
>>> ---
>>> drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c | 2 +-
>>> drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c | 2 +-
>>> 2 files changed, 2 insertions(+), 2 deletions(-)
>>
>> It was already sent, but not merged yet.
>> https://lore.kernel.org/all/20211204012448.51360-1-huangguangbin2@huawei.com
>
> Indeed, Guangbin in the future please make sure to CC the person whose
> feedback the patches are based on.
> .
>
Ok.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [PATCH net-next] Revert "net: hns3: add void before function which don't receive ret"
@ 2021-12-04 1:24 Guangbin Huang
2021-12-07 0:40 ` patchwork-bot+netdevbpf
0 siblings, 1 reply; 6+ messages in thread
From: Guangbin Huang @ 2021-12-04 1:24 UTC (permalink / raw)
To: davem, kuba, wangjie125
Cc: netdev, linux-kernel, lipeng321, huangguangbin2, chenhao288
This reverts commit 5ac4f180bd07116c1e57858bc3f6741adbca3eb6.
Sorry for taking no notice that the function devlink_register() has been
already declared as void, so it is needs to revert this patch.
Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com>
---
drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c | 2 +-
drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c
index 9c3199d3c8ee..4c441e6a5082 100644
--- a/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c
+++ b/drivers/net/ethernet/hisilicon/hns3/hns3pf/hclge_devlink.c
@@ -120,7 +120,7 @@ int hclge_devlink_init(struct hclge_dev *hdev)
hdev->devlink = devlink;
devlink_set_features(devlink, DEVLINK_F_RELOAD);
- (void)devlink_register(devlink);
+ devlink_register(devlink);
return 0;
}
diff --git a/drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c b/drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c
index 75d2926729d3..fdc19868b818 100644
--- a/drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c
+++ b/drivers/net/ethernet/hisilicon/hns3/hns3vf/hclgevf_devlink.c
@@ -122,7 +122,7 @@ int hclgevf_devlink_init(struct hclgevf_dev *hdev)
hdev->devlink = devlink;
devlink_set_features(devlink, DEVLINK_F_RELOAD);
- (void)devlink_register(devlink);
+ devlink_register(devlink);
return 0;
}
--
2.33.0
^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [PATCH net-next] Revert "net: hns3: add void before function which don't receive ret"
2021-12-04 1:24 Guangbin Huang
@ 2021-12-07 0:40 ` patchwork-bot+netdevbpf
0 siblings, 0 replies; 6+ messages in thread
From: patchwork-bot+netdevbpf @ 2021-12-07 0:40 UTC (permalink / raw)
To: Guangbin Huang
Cc: davem, kuba, wangjie125, netdev, linux-kernel, lipeng321,
chenhao288
Hello:
This patch was applied to netdev/net-next.git (master)
by Jakub Kicinski <kuba@kernel.org>:
On Sat, 4 Dec 2021 09:24:48 +0800 you wrote:
> This reverts commit 5ac4f180bd07116c1e57858bc3f6741adbca3eb6.
>
> Sorry for taking no notice that the function devlink_register() has been
> already declared as void, so it is needs to revert this patch.
>
> Signed-off-by: Guangbin Huang <huangguangbin2@huawei.com>
>
> [...]
Here is the summary with links:
- [net-next] Revert "net: hns3: add void before function which don't receive ret"
https://git.kernel.org/netdev/net-next/c/364d470d5470
You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2021-12-07 1:19 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-12-05 11:51 [PATCH net-next] Revert "net: hns3: add void before function which don't receive ret" Leon Romanovsky
2021-12-05 12:18 ` Leon Romanovsky
2021-12-07 0:34 ` Jakub Kicinski
2021-12-07 1:19 ` huangguangbin (A)
-- strict thread matches above, loose matches on Subject: below --
2021-12-04 1:24 Guangbin Huang
2021-12-07 0:40 ` patchwork-bot+netdevbpf
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).