summaryrefslogtreecommitdiff
path: root/net/ipv4
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2025-10-02 14:44:15 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2025-10-02 14:44:15 +0300
commit2844b98acb6112cf1eb7a16bbdc7fe9b319c17d4 (patch)
treedca5ec4aeb4edeb0cbe0e04a4b24f7cc91f7a2e1 /net/ipv4
parent56fb05093756ed55ba1cdf5d432a68004da67860 (diff)
parent72b82d56b82137a92a20e5584029d35408d810c2 (diff)
downloadlinux-rolling-lts.tar.xz
Merge v6.12.50linux-rolling-lts
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/ipv4')
-rw-r--r--net/ipv4/nexthop.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/net/ipv4/nexthop.c b/net/ipv4/nexthop.c
index 93aaea0006ba..c52ff9364ae8 100644
--- a/net/ipv4/nexthop.c
+++ b/net/ipv4/nexthop.c
@@ -2375,6 +2375,13 @@ static int replace_nexthop_single(struct net *net, struct nexthop *old,
return -EINVAL;
}
+ if (!list_empty(&old->grp_list) &&
+ rtnl_dereference(new->nh_info)->fdb_nh !=
+ rtnl_dereference(old->nh_info)->fdb_nh) {
+ NL_SET_ERR_MSG(extack, "Cannot change nexthop FDB status while in a group");
+ return -EINVAL;
+ }
+
err = call_nexthop_notifiers(net, NEXTHOP_EVENT_REPLACE, new, extack);
if (err)
return err;