upgrade to linux 2.6.10-1.12_FC2
[linux-2.6.git] / net / tux / cachemiss.c
index f840583..a59c881 100644 (file)
@@ -186,6 +186,7 @@ static void __stop_cachemiss_threads (iothread_t *iot)
 {
        DECLARE_WAITQUEUE(wait, current);
 
+       __set_current_state(TASK_UNINTERRUPTIBLE);
        Dprintk("stopping async IO threads %p.\n", iot);
        add_wait_queue(&iot->wait_shutdown, &wait);
 
@@ -198,7 +199,6 @@ static void __stop_cachemiss_threads (iothread_t *iot)
        wake_up_all(&iot->async_sleep);
        spin_unlock(&iot->async_lock);
                
-       __set_current_state(TASK_UNINTERRUPTIBLE);
        Dprintk("waiting for async IO threads %p to exit.\n", iot);
        schedule();
        remove_wait_queue(&iot->wait_shutdown, &wait);