net/ipv4: Add extack message that dev is required for ONLINK
Subsystems (3)
[email protected]
maintainerPATCH 1/1 net/ipv4: Add extack message that dev is required for ONLINK
From: David Ahern <[email protected]>
Make IPv4 consistent with IPv6 and return an extack message that the ONLINK flag requires a nexthop device.
Signed-off-by David Ahern <[email protected]>
--- net/ipv4/fib_semantics.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
net/ipv4/fib_semantics.c +3 -1
@@ -797,8 +797,10 @@ static int fib_check_nh(struct fib_config *cfg, struct fib_nh *nh,return -EINVAL ; } dev =__dev_get_by_index (net, nh->nh_oif); -if (!dev) +if (!dev) { +NL_SET_ERR_MSG (extack,"Nexthop device required for onlink" );return -ENODEV ; + }if (!(dev->flags &IFF_UP )) {NL_SET_ERR_MSG (extack,"Nexthop device is not up" );
Signature · 1 line
2.11.0
From: [email protected]
Date: Wed, 29 Aug 2018 16:53:27 -0700
Quoted 6 lines
From: David Ahern <[email protected]>
Make IPv4 consistent with IPv6 and return an extack message that the ONLINK flag requires a nexthop device.
Signed-off-by David Ahern <[email protected]>
Applied.