Skip to content

Commit

Permalink
[PATCH] blktrace: only add a bounce trace when we really bounce
Browse files Browse the repository at this point in the history
Currently we issue a bounce trace when __blk_queue_bounce() is called,
but that merely means that the device has a lower dma mask than the
higher pages in the system. The bio itself may still be lower pages. So
move the bounce trace into __blk_queue_bounce(), when we know there will
actually be page bouncing.

Signed-off-by: Jens Axboe <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Jens Axboe authored and Linus Torvalds committed Jan 12, 2007
1 parent d39c940 commit c43a508
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions mm/bounce.c
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,8 @@ static void __blk_queue_bounce(request_queue_t *q, struct bio **bio_orig,
if (!bio)
return;

blk_add_trace_bio(q, *bio_orig, BLK_TA_BOUNCE);

/*
* at least one page was bounced, fill in possible non-highmem
* pages
Expand Down Expand Up @@ -291,8 +293,6 @@ void blk_queue_bounce(request_queue_t *q, struct bio **bio_orig)
pool = isa_page_pool;
}

blk_add_trace_bio(q, *bio_orig, BLK_TA_BOUNCE);

/*
* slow path
*/
Expand Down

0 comments on commit c43a508

Please sign in to comment.