* [PATCH net-next] bonding: remove print in bond_verify_device_path
@ 2023-11-23 1:55 Zhengchao Shao
2023-11-23 2:13 ` Hangbin Liu
2023-11-24 15:30 ` patchwork-bot+netdevbpf
0 siblings, 2 replies; 3+ messages in thread
From: Zhengchao Shao @ 2023-11-23 1:55 UTC (permalink / raw)
To: netdev, davem, edumazet, kuba, pabeni
Cc: j.vosburgh, andy, weiyongjun1, yuehaibing, shaozhengchao
As suggested by Paolo in link[1], if the memory allocation fails, the mm
layer will emit a lot warning comprising the backtrace, so remove the
print.
[1] https://lore.kernel.org/all/20231118081653.1481260-1-shaozhengchao@huawei.com/
Suggested-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Zhengchao Shao <shaozhengchao@huawei.com>
---
drivers/net/bonding/bond_main.c | 5 +----
1 file changed, 1 insertion(+), 4 deletions(-)
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
index d987432cee3b..4e0600c7b050 100644
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@ -2973,11 +2973,8 @@ struct bond_vlan_tag *bond_verify_device_path(struct net_device *start_dev,
if (start_dev == end_dev) {
tags = kcalloc(level + 1, sizeof(*tags), GFP_ATOMIC);
- if (!tags) {
- net_err_ratelimited("%s: %s: Failed to allocate tags\n",
- __func__, start_dev->name);
+ if (!tags)
return ERR_PTR(-ENOMEM);
- }
tags[level].vlan_proto = BOND_VLAN_PROTO_NONE;
return tags;
}
--
2.34.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH net-next] bonding: remove print in bond_verify_device_path
2023-11-23 1:55 [PATCH net-next] bonding: remove print in bond_verify_device_path Zhengchao Shao
@ 2023-11-23 2:13 ` Hangbin Liu
2023-11-24 15:30 ` patchwork-bot+netdevbpf
1 sibling, 0 replies; 3+ messages in thread
From: Hangbin Liu @ 2023-11-23 2:13 UTC (permalink / raw)
To: Zhengchao Shao
Cc: netdev, davem, edumazet, kuba, pabeni, j.vosburgh, andy,
weiyongjun1, yuehaibing
On Thu, Nov 23, 2023 at 09:55:15AM +0800, Zhengchao Shao wrote:
> As suggested by Paolo in link[1], if the memory allocation fails, the mm
> layer will emit a lot warning comprising the backtrace, so remove the
> print.
>
> [1] https://lore.kernel.org/all/20231118081653.1481260-1-shaozhengchao@huawei.com/
>
> Suggested-by: Paolo Abeni <pabeni@redhat.com>
> Signed-off-by: Zhengchao Shao <shaozhengchao@huawei.com>
> ---
> drivers/net/bonding/bond_main.c | 5 +----
> 1 file changed, 1 insertion(+), 4 deletions(-)
>
> diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
> index d987432cee3b..4e0600c7b050 100644
> --- a/drivers/net/bonding/bond_main.c
> +++ b/drivers/net/bonding/bond_main.c
> @@ -2973,11 +2973,8 @@ struct bond_vlan_tag *bond_verify_device_path(struct net_device *start_dev,
>
> if (start_dev == end_dev) {
> tags = kcalloc(level + 1, sizeof(*tags), GFP_ATOMIC);
> - if (!tags) {
> - net_err_ratelimited("%s: %s: Failed to allocate tags\n",
> - __func__, start_dev->name);
> + if (!tags)
> return ERR_PTR(-ENOMEM);
> - }
> tags[level].vlan_proto = BOND_VLAN_PROTO_NONE;
> return tags;
> }
> --
> 2.34.1
>
Reviewed-by: Hangbin Liu <liuhangbin@gmail.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH net-next] bonding: remove print in bond_verify_device_path
2023-11-23 1:55 [PATCH net-next] bonding: remove print in bond_verify_device_path Zhengchao Shao
2023-11-23 2:13 ` Hangbin Liu
@ 2023-11-24 15:30 ` patchwork-bot+netdevbpf
1 sibling, 0 replies; 3+ messages in thread
From: patchwork-bot+netdevbpf @ 2023-11-24 15:30 UTC (permalink / raw)
To: Zhengchao Shao
Cc: netdev, davem, edumazet, kuba, pabeni, j.vosburgh, andy,
weiyongjun1, yuehaibing
Hello:
This patch was applied to netdev/net-next.git (main)
by David S. Miller <davem@davemloft.net>:
On Thu, 23 Nov 2023 09:55:15 +0800 you wrote:
> As suggested by Paolo in link[1], if the memory allocation fails, the mm
> layer will emit a lot warning comprising the backtrace, so remove the
> print.
>
> [1] https://lore.kernel.org/all/20231118081653.1481260-1-shaozhengchao@huawei.com/
>
> Suggested-by: Paolo Abeni <pabeni@redhat.com>
> Signed-off-by: Zhengchao Shao <shaozhengchao@huawei.com>
>
> [...]
Here is the summary with links:
- [net-next] bonding: remove print in bond_verify_device_path
https://git.kernel.org/netdev/net-next/c/486058f42a47
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] 3+ messages in thread
end of thread, other threads:[~2023-11-24 15:30 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-23 1:55 [PATCH net-next] bonding: remove print in bond_verify_device_path Zhengchao Shao
2023-11-23 2:13 ` Hangbin Liu
2023-11-24 15:30 ` 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).