aboutsummaryrefslogtreecommitdiffstats
path: root/net/sched/act_mirred.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/sched/act_mirred.c')
-rw-r--r--net/sched/act_mirred.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/net/sched/act_mirred.c b/net/sched/act_mirred.c
index 4f912c0e225b..eb48306033d9 100644
--- a/net/sched/act_mirred.c
+++ b/net/sched/act_mirred.c
@@ -218,10 +218,12 @@ static int mirred_device_event(struct notifier_block *unused,
218 218
219 if (event == NETDEV_UNREGISTER) 219 if (event == NETDEV_UNREGISTER)
220 list_for_each_entry(m, &mirred_list, tcfm_list) { 220 list_for_each_entry(m, &mirred_list, tcfm_list) {
221 spin_lock_bh(&m->tcf_lock);
221 if (m->tcfm_dev == dev) { 222 if (m->tcfm_dev == dev) {
222 dev_put(dev); 223 dev_put(dev);
223 m->tcfm_dev = NULL; 224 m->tcfm_dev = NULL;
224 } 225 }
226 spin_unlock_bh(&m->tcf_lock);
225 } 227 }
226 228
227 return NOTIFY_DONE; 229 return NOTIFY_DONE;