]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/block/cfq-iosched.c
[PATCH] cfq-iosched: move tasklist walk to elevator.c
[linux-2.6-omap-h63xx.git] / drivers / block / cfq-iosched.c
index 94690e4d41e096b4a988eb5a27f76d8d1925fc72..5281f8e70510cda1717f2bd385e0c19353476fdd 100644 (file)
@@ -2418,28 +2418,8 @@ static int __init cfq_init(void)
 
 static void __exit cfq_exit(void)
 {
-       struct task_struct *g, *p;
-       unsigned long flags;
-
-       read_lock_irqsave(&tasklist_lock, flags);
-
-       /*
-        * iterate each process in the system, removing our io_context
-        */
-       do_each_thread(g, p) {
-               struct io_context *ioc = p->io_context;
-
-               if (ioc && ioc->cic) {
-                       ioc->cic->exit(ioc->cic);
-                       cfq_free_io_context(ioc->cic);
-                       ioc->cic = NULL;
-               }
-       } while_each_thread(g, p);
-
-       read_unlock_irqrestore(&tasklist_lock, flags);
-
-       cfq_slab_kill();
        elv_unregister(&iosched_cfq);
+       cfq_slab_kill();
 }
 
 module_init(cfq_init);