Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 336269
b: refs/heads/master
c: 45c5a91
h: refs/heads/master
i:
  336267: e569b3d
v: v3
  • Loading branch information
Seungwon Jeon authored and Chris Ball committed Dec 6, 2012
1 parent 0f8980e commit 0feb3c2
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 8 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 42cd95a0603e0497e7221816bb5ddfe861ee9325
refs/heads/master: 45c5a914e68fdbbc2635c3cc197566aa24e8de5b
17 changes: 10 additions & 7 deletions trunk/drivers/mmc/card/queue.c
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,16 @@ static int mmc_queue_thread(void *d)
if (req || mq->mqrq_prev->req) {
set_current_state(TASK_RUNNING);
mq->issue_fn(mq, req);

/*
* Current request becomes previous request
* and vice versa.
*/
mq->mqrq_prev->brq.mrq.data = NULL;
mq->mqrq_prev->req = NULL;
tmp = mq->mqrq_prev;
mq->mqrq_prev = mq->mqrq_cur;
mq->mqrq_cur = tmp;
} else {
if (kthread_should_stop()) {
set_current_state(TASK_RUNNING);
Expand All @@ -77,13 +87,6 @@ static int mmc_queue_thread(void *d)
schedule();
down(&mq->thread_sem);
}

/* Current request becomes previous request and vice versa. */
mq->mqrq_prev->brq.mrq.data = NULL;
mq->mqrq_prev->req = NULL;
tmp = mq->mqrq_prev;
mq->mqrq_prev = mq->mqrq_cur;
mq->mqrq_cur = tmp;
} while (1);
up(&mq->thread_sem);

Expand Down

0 comments on commit 0feb3c2

Please sign in to comment.