mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
net: use hlist_del_rcu() in dev_change_name()
Using plain hlist_del() in dev_change_name() is wrong since a
concurrent reader can crash trying to dereference LIST_POISON1.
Bug introduced in commit 72c9528bab
(net: Introduce
dev_get_by_name_rcu())
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
6f404e441d
commit
372b231201
1 changed files with 1 additions and 1 deletions
|
@ -1007,7 +1007,7 @@ rollback:
|
|||
}
|
||||
|
||||
write_lock_bh(&dev_base_lock);
|
||||
hlist_del(&dev->name_hlist);
|
||||
hlist_del_rcu(&dev->name_hlist);
|
||||
write_unlock_bh(&dev_base_lock);
|
||||
|
||||
synchronize_rcu();
|
||||
|
|
Loading…
Reference in a new issue