* [PATCH net-next] net: sched: Return the correct errno code
@ 2021-02-04 7:39 Zheng Yongjun
2021-02-06 19:20 ` patchwork-bot+netdevbpf
0 siblings, 1 reply; 2+ messages in thread
From: Zheng Yongjun @ 2021-02-04 7:39 UTC (permalink / raw)
To: jhs, xiyou.wangcong, jiri, davem, kuba, netdev, linux-kernel
Cc: Zheng Yongjun
When kalloc or kmemdup failed, should return ENOMEM rather than ENOBUF.
Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
---
net/sched/em_nbyte.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/sched/em_nbyte.c b/net/sched/em_nbyte.c
index 2c1192a2ee5e..a83b237cbeb0 100644
--- a/net/sched/em_nbyte.c
+++ b/net/sched/em_nbyte.c
@@ -31,7 +31,7 @@ static int em_nbyte_change(struct net *net, void *data, int data_len,
em->datalen = sizeof(*nbyte) + nbyte->len;
em->data = (unsigned long)kmemdup(data, em->datalen, GFP_KERNEL);
if (em->data == 0UL)
- return -ENOBUFS;
+ return -ENOMEM;
return 0;
}
--
2.22.0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH net-next] net: sched: Return the correct errno code
2021-02-04 7:39 [PATCH net-next] net: sched: Return the correct errno code Zheng Yongjun
@ 2021-02-06 19:20 ` patchwork-bot+netdevbpf
0 siblings, 0 replies; 2+ messages in thread
From: patchwork-bot+netdevbpf @ 2021-02-06 19:20 UTC (permalink / raw)
To: Zheng Yongjun
Cc: jhs, xiyou.wangcong, jiri, davem, kuba, netdev, linux-kernel
Hello:
This patch was applied to netdev/net-next.git (refs/heads/master):
On Thu, 4 Feb 2021 15:39:50 +0800 you wrote:
> When kalloc or kmemdup failed, should return ENOMEM rather than ENOBUF.
>
> Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
> ---
> net/sched/em_nbyte.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
Here is the summary with links:
- [net-next] net: sched: Return the correct errno code
https://git.kernel.org/netdev/net-next/c/a64566a22b6a
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] 2+ messages in thread
end of thread, other threads:[~2021-02-06 19:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-04 7:39 [PATCH net-next] net: sched: Return the correct errno code Zheng Yongjun
2021-02-06 19:20 ` 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
all inboxes | Powered by JetHome®