]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
[PATCH] ll_merge_requests_fn() cleanup
authorNikita Danilov <nikita@clusterfs.com>
Sat, 25 Jun 2005 21:59:20 +0000 (14:59 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Sat, 25 Jun 2005 23:25:07 +0000 (16:25 -0700)
ll_merge_requests_fn() assigns total_{phys,hw}_segments twice.  Fix this
and a typo.

Signed-off-by: Nikita Danilov <nikita@clusterfs.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
drivers/block/ll_rw_blk.c

index fc86d53fe783765c9e7c6bd77a72cd01ddbf4c6d..60e64091de1b34df8b5a0cd27c9a952b6b33ac86 100644 (file)
@@ -1344,8 +1344,8 @@ static int ll_front_merge_fn(request_queue_t *q, struct request *req,
 static int ll_merge_requests_fn(request_queue_t *q, struct request *req,
                                struct request *next)
 {
-       int total_phys_segments = req->nr_phys_segments +next->nr_phys_segments;
-       int total_hw_segments = req->nr_hw_segments + next->nr_hw_segments;
+       int total_phys_segments;
+       int total_hw_segments;
 
        /*
         * First check if the either of the requests are re-queued
@@ -1355,7 +1355,7 @@ static int ll_merge_requests_fn(request_queue_t *q, struct request *req,
                return 0;
 
        /*
-        * Will it become to large?
+        * Will it become too large?
         */
        if ((req->nr_sectors + next->nr_sectors) > q->max_sectors)
                return 0;