mirror of
https://github.com/torvalds/linux.git
synced 2025-12-01 07:26:02 +07:00
netfilter: nf_tables: remove NETDEV_CHANGENAME from netdev chain event handler
Originally, device name used to be stored in the basechain, but it is not the case anymore. Remove check for NETDEV_CHANGENAME. Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
This commit is contained in:
@@ -325,9 +325,6 @@ static void nft_netdev_event(unsigned long event, struct net_device *dev,
|
|||||||
struct nft_hook *hook, *found = NULL;
|
struct nft_hook *hook, *found = NULL;
|
||||||
int n = 0;
|
int n = 0;
|
||||||
|
|
||||||
if (event != NETDEV_UNREGISTER)
|
|
||||||
return;
|
|
||||||
|
|
||||||
list_for_each_entry(hook, &basechain->hook_list, list) {
|
list_for_each_entry(hook, &basechain->hook_list, list) {
|
||||||
if (hook->ops.dev == dev)
|
if (hook->ops.dev == dev)
|
||||||
found = hook;
|
found = hook;
|
||||||
@@ -367,8 +364,7 @@ static int nf_tables_netdev_event(struct notifier_block *this,
|
|||||||
.net = dev_net(dev),
|
.net = dev_net(dev),
|
||||||
};
|
};
|
||||||
|
|
||||||
if (event != NETDEV_UNREGISTER &&
|
if (event != NETDEV_UNREGISTER)
|
||||||
event != NETDEV_CHANGENAME)
|
|
||||||
return NOTIFY_DONE;
|
return NOTIFY_DONE;
|
||||||
|
|
||||||
nft_net = nft_pernet(ctx.net);
|
nft_net = nft_pernet(ctx.net);
|
||||||
|
|||||||
Reference in New Issue
Block a user