Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=cb8874119e9a3ec38c45942808c91cfbc014f402
Commit:     cb8874119e9a3ec38c45942808c91cfbc014f402
Parent:     1792669cc1acc2069869b7ca41a0195240de05e0
Author:     Jens Axboe <[EMAIL PROTECTED]>
AuthorDate: Fri Jan 19 12:01:16 2007 +1100
Committer:  Jens Axboe <[EMAIL PROTECTED]>
CommitDate: Sun Feb 11 23:14:45 2007 +0100

    cfq-iosched: tweak the FIFO checking
    
    We currently check the FIFO once per slice. Optimize that a bit and
    only do it as the first thing for a new slice, so we don't end up
    doing a single request and then seek to the FIFO requests.
    
    Signed-off-by: Jens Axboe <[EMAIL PROTECTED]>
---
 block/cfq-iosched.c |    7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/block/cfq-iosched.c b/block/cfq-iosched.c
index 3df41a0..03b1e47 100644
--- a/block/cfq-iosched.c
+++ b/block/cfq-iosched.c
@@ -885,16 +885,17 @@ static inline struct request *cfq_check_fifo(struct 
cfq_queue *cfqq)
 
        if (cfq_cfqq_fifo_expire(cfqq))
                return NULL;
+
+       cfq_mark_cfqq_fifo_expire(cfqq);
+
        if (list_empty(&cfqq->fifo))
                return NULL;
 
        fifo = cfq_cfqq_class_sync(cfqq);
        rq = rq_entry_fifo(cfqq->fifo.next);
 
-       if (time_after(jiffies, rq->start_time + cfqd->cfq_fifo_expire[fifo])) {
-               cfq_mark_cfqq_fifo_expire(cfqq);
+       if (time_after(jiffies, rq->start_time + cfqd->cfq_fifo_expire[fifo]))
                return rq;
-       }
 
        return NULL;
 }
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to