compat: fix system crash on 2.6.35 when flushing work
authorZefir Kurtisi <zefir.kurtisi@neratec.com>
Fri, 13 Jul 2012 08:38:34 +0000 (10:38 +0200)
committerLuis R. Rodriguez <mcgrof@frijolero.org>
Wed, 18 Jul 2012 15:22:08 +0000 (08:22 -0700)
Ubuntu 10.10 stock kernel (2.6.35-22-generic) crashes in
compat_flush_scheduled_work(), that is called e.g. when
mac80211 module is unloaded.

The problem was introduced with 80bf8a83
compat: backport system work queues system_wq and system_long_wq

The crash happens in compat_flush_scheduled_work() where both
flush_workqueue() and flush_scheduled_work() are called successively.
Removing one of them resolves the issue.

All compat-wireless tarballs after 2012-03-18 are affected.

Signed-off-by: Zefir Kurtisi <zefir.kurtisi@neratec.com>
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
compat/compat-2.6.36.c

index 9190ecd8b0a1aa43c4bb90e03e07a63dc7b54787..8f25be0a1e35aca65588f2942ec55b92471880ba 100644 (file)
@@ -140,7 +140,6 @@ void compat_flush_scheduled_work(void)
         * go with the old kernel's one first for now (keventd_wq) and
         * if think its reasonable later we can flip this around.
         */
-       flush_workqueue(system_wq);
        flush_scheduled_work();
 }
 EXPORT_SYMBOL_GPL(compat_flush_scheduled_work);