diff options
author | Vitaly Wool <vitalywool@gmail.com> | 2006-12-07 14:08:02 -0500 |
---|---|---|
committer | Pierre Ossman <drzeus@drzeus.cx> | 2006-12-11 03:48:16 -0500 |
commit | 7b30d281b9c115890c75d11eaf06881261c256da (patch) | |
tree | 79fa9f88fd469fb61b796a1b4d027ef2c11425e0 /drivers | |
parent | f3a8efa90b1aab16ead76ad7e22d9c5fc2045400 (diff) |
mmc: fix "prev->state: 2 != TASK_RUNNING??" problem on SD/MMC card removal
Currently on SD/MMC card removal the system exhibits the following message (the platform is ARM Versatile):
prev->state: 2 != TASK_RUNNING??
mmcqd/762[CPU#0]: BUG in __schedule at linux-2.6/kernel/sched.c:3826
(akpm: someone tried to fix this, but it's still wrong)
Signed-off-by: Vitaly Wool <vitalywool@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Pierre Ossman <drzeus@drzeus.cx>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/mmc/mmc_queue.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/mmc/mmc_queue.c b/drivers/mmc/mmc_queue.c index a17423a4ed8f..3e35a43819fb 100644 --- a/drivers/mmc/mmc_queue.c +++ b/drivers/mmc/mmc_queue.c | |||
@@ -78,8 +78,10 @@ static int mmc_queue_thread(void *d) | |||
78 | spin_unlock_irq(q->queue_lock); | 78 | spin_unlock_irq(q->queue_lock); |
79 | 79 | ||
80 | if (!req) { | 80 | if (!req) { |
81 | if (kthread_should_stop()) | 81 | if (kthread_should_stop()) { |
82 | set_current_state(TASK_RUNNING); | ||
82 | break; | 83 | break; |
84 | } | ||
83 | up(&mq->thread_sem); | 85 | up(&mq->thread_sem); |
84 | schedule(); | 86 | schedule(); |
85 | down(&mq->thread_sem); | 87 | down(&mq->thread_sem); |