diff options
author | Ido Schimmel <idosch@mellanox.com> | 2019-12-14 18:53:15 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-12-17 03:14:43 +0300 |
commit | 446f739104f4da6207230363848ec2c89dfd858d (patch) | |
tree | 7ff99a48baecd4e51909fd427386ebaf63606187 /drivers/net/netdevsim | |
parent | b6a1d871d37a8a1beffb5432631ca77ca3712c84 (diff) | |
download | linux-446f739104f4da6207230363848ec2c89dfd858d.tar.xz |
ipv4: Remove old route notifications and convert listeners
Unlike mlxsw, the other listeners to the FIB notification chain do not
require any special modifications as they never considered multiple
identical routes.
This patch removes the old route notifications and converts all the
listeners to use the new replace / delete notifications.
Signed-off-by: Ido Schimmel <idosch@mellanox.com>
Reviewed-by: David Ahern <dsahern@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/netdevsim')
-rw-r--r-- | drivers/net/netdevsim/fib.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/netdevsim/fib.c b/drivers/net/netdevsim/fib.c index 13540dee7364..4e02a4231fcb 100644 --- a/drivers/net/netdevsim/fib.c +++ b/drivers/net/netdevsim/fib.c @@ -177,10 +177,10 @@ static int nsim_fib_event_nb(struct notifier_block *nb, unsigned long event, event == FIB_EVENT_RULE_ADD); break; + case FIB_EVENT_ENTRY_REPLACE: /* fall through */ case FIB_EVENT_ENTRY_ADD: /* fall through */ case FIB_EVENT_ENTRY_DEL: - err = nsim_fib_event(data, info, - event == FIB_EVENT_ENTRY_ADD); + err = nsim_fib_event(data, info, event != FIB_EVENT_ENTRY_DEL); break; } |