From 35c833afefd8b6b019696d571da09f3893872f6b Mon Sep 17 00:00:00 2001 From: Shaun Ruffell Date: Tue, 19 Jul 2011 19:45:01 +0000 Subject: [PATCH] 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 Acked-by: Russ Meyerriecks Origin: http://svnview.digium.com/svn/dahdi?view=rev&rev=10047 git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/branches/2.4@10049 a0bf4364-ded3-4de4-8d8a-66a801d63aff --- drivers/dahdi/wcte12xp/base.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/dahdi/wcte12xp/base.c b/drivers/dahdi/wcte12xp/base.c index 5f720a1..784e475 100644 --- a/drivers/dahdi/wcte12xp/base.c +++ b/drivers/dahdi/wcte12xp/base.c @@ -2381,6 +2381,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);