fib: Return the correct errno code
authorZheng Yongjun <zhengyongjun3@huawei.com>
Wed, 2 Jun 2021 14:06:58 +0000 (22:06 +0800)
committerSasha Levin <sashal@kernel.org>
Wed, 30 Jun 2021 12:48:13 +0000 (08:48 -0400)
commit7e3f278d55b0677aa82d07ba521390c8b090ee69
tree020b89cbc4e4825859a6c1a18f28e7cfa3ca16a7
parentb966a0defc93c533c0f96410c20f50c42a5fed52
fib: Return the correct errno code

[ Upstream commit 59607863c54e9eb3f69afc5257dfe71c38bb751e ]

When kalloc or kmemdup failed, should return ENOMEM rather than ENOBUF.

Signed-off-by: Zheng Yongjun <zhengyongjun3@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
net/core/fib_rules.c