From: Dmitry Shmidt Date: Thu, 2 Jun 2011 23:08:37 +0000 (-0700) Subject: net: wireless: bcmdhd: Fix watchdog firing in softirq on removal X-Git-Tag: 2.1b_release~2601 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=166fb03628aebaba9a90bb1004ba50e2a911de57;p=platform%2Fkernel%2Fkernel-mfld-blackbay.git net: wireless: bcmdhd: Fix watchdog firing in softirq on removal Signed-off-by: Dmitry Shmidt --- diff --git a/drivers/net/wireless/bcmdhd/dhd_linux.c b/drivers/net/wireless/bcmdhd/dhd_linux.c index 3593845..8513fcc 100644 --- a/drivers/net/wireless/bcmdhd/dhd_linux.c +++ b/drivers/net/wireless/bcmdhd/dhd_linux.c @@ -2901,9 +2901,6 @@ dhd_bus_detach(dhd_pub_t *dhdp) /* Stop the bus module */ dhd_bus_stop(dhd->pub.bus, TRUE); - /* Clear the watchdog timer */ - dhd->wd_timer_valid = FALSE; - del_timer_sync(&dhd->timer); #if defined(OOB_INTR_ONLY) bcmsdh_unregister_oob_intr(); #endif /* defined(OOB_INTR_ONLY) */ @@ -2985,6 +2982,10 @@ void dhd_detach(dhd_pub_t *dhdp) } } + /* Clear the watchdog timer */ + dhd->wd_timer_valid = FALSE; + del_timer_sync(&dhd->timer); + if (dhd->dhd_state & DHD_ATTACH_STATE_THREADS_CREATED) { #ifdef DHDTHREAD if (dhd->thr_wdt_ctl.thr_pid >= 0) {