Commit dfd11c2e authored by Linus Torvalds's avatar Linus Torvalds
parents 794f5bfa db3b5848
...@@ -1202,14 +1202,17 @@ retry: ...@@ -1202,14 +1202,17 @@ retry:
if (new_cfqq) { if (new_cfqq) {
cfqq = new_cfqq; cfqq = new_cfqq;
new_cfqq = NULL; new_cfqq = NULL;
} else if (gfp_mask & __GFP_WAIT) { } else {
spin_unlock_irq(cfqd->queue->queue_lock); spin_unlock_irq(cfqd->queue->queue_lock);
new_cfqq = kmem_cache_alloc(cfq_pool, gfp_mask); new_cfqq = kmem_cache_alloc(cfq_pool, gfp_mask);
spin_lock_irq(cfqd->queue->queue_lock); spin_lock_irq(cfqd->queue->queue_lock);
goto retry;
} else if (!new_cfqq && !(gfp_mask & __GFP_WAIT))
goto out; goto out;
goto retry;
}
memset(cfqq, 0, sizeof(*cfqq)); memset(cfqq, 0, sizeof(*cfqq));
INIT_HLIST_NODE(&cfqq->cfq_hash); INIT_HLIST_NODE(&cfqq->cfq_hash);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment