]> git.baikalelectronics.ru Git - kernel.git/commit
nexthop: Emit a notification when a nexthop group is reduced
authorIdo Schimmel <idosch@nvidia.com>
Wed, 4 Nov 2020 13:30:33 +0000 (15:30 +0200)
committerJakub Kicinski <kuba@kernel.org>
Fri, 6 Nov 2020 19:28:49 +0000 (11:28 -0800)
commit124db71228b7536c97310ac50807574c5c51c082
tree556409e1712616ad795a553fed8ff3b793bca1ca
parentd3bb819569a1171e6fe7e3faa3c4b0da4ce259d9
nexthop: Emit a notification when a nexthop group is reduced

When a single nexthop is deleted, the configuration of all the groups
using the nexthop is effectively modified. In this case, emit a
notification in the nexthop notification chain for each modified group
so that listeners would not need to keep track of which nexthops are
member in which groups.

In the rare cases where the notification fails, emit an error to the
kernel log. This is done by allocating extack on the stack and printing
the error logged by the listener that rejected the notification.

Changes since RFC:
* Allocate extack on the stack

Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/ipv4/nexthop.c