Commit 6a87afc0 authored by David Ahern's avatar David Ahern Committed by David S. Miller

mlx5: Fail attempts to use routes with nexthop objects

Fail attempts to use nexthop objects with routes until support can be
properly added.
Signed-off-by: default avatarDavid Ahern <dsahern@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 54250805
...@@ -262,6 +262,10 @@ static int mlx5_lag_fib_event(struct notifier_block *nb, ...@@ -262,6 +262,10 @@ static int mlx5_lag_fib_event(struct notifier_block *nb,
fen_info = container_of(info, struct fib_entry_notifier_info, fen_info = container_of(info, struct fib_entry_notifier_info,
info); info);
fi = fen_info->fi; fi = fen_info->fi;
if (fi->nh) {
NL_SET_ERR_MSG_MOD(info->extack, "IPv4 route with nexthop objects is not supported");
return notifier_from_errno(-EINVAL);
}
fib_dev = fib_info_nh(fen_info->fi, 0)->fib_nh_dev; fib_dev = fib_info_nh(fen_info->fi, 0)->fib_nh_dev;
if (fib_dev != ldev->pf[0].netdev && if (fib_dev != ldev->pf[0].netdev &&
fib_dev != ldev->pf[1].netdev) { fib_dev != ldev->pf[1].netdev) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment