wcte12xp: Close a potential race on driver unload.
The shutdown logic requires that all CPUs see that the INITIALIZED bit has been cleared. Otherwise it may be possible for the workqueue to run after the hardware resources have been released. Signed-off-by: Shaun Ruffell <sruffell@digium.com> Acked-by: Russ Meyerriecks <rmeyerriecks@digium.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@10047 a0bf4364-ded3-4de4-8d8a-66a801d63aff
This commit is contained in:
parent
74ce1b7f9a
commit
643b60ffb0
@ -2686,6 +2686,7 @@ static void __devexit te12xp_remove_one(struct pci_dev *pdev)
|
||||
remove_sysfs_files(wc);
|
||||
|
||||
clear_bit(INITIALIZED, &wc->bit_flags);
|
||||
smp_mb__after_clear_bit();
|
||||
|
||||
del_timer_sync(&wc->timer);
|
||||
flush_workqueue(wc->wq);
|
||||
|
Loading…
Reference in New Issue
Block a user