X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=mm%2Fhighmem.c;h=c190cf80af4d5b5e80ea42a2ca79148442fde9e8;hb=c7b5ebbddf7bcd3651947760f423e3783bbe6573;hp=432da5b68baf5ae4c730610c7f69019e387a7ca0;hpb=9bf4aaab3e101692164d49b7ca357651eb691cb6;p=linux-2.6.git diff --git a/mm/highmem.c b/mm/highmem.c index 432da5b68..c190cf80a 100644 --- a/mm/highmem.c +++ b/mm/highmem.c @@ -284,7 +284,7 @@ static void copy_to_high_bio_irq(struct bio *to, struct bio *from) struct bio_vec *tovec, *fromvec; int i; - bio_for_each_segment(tovec, to, i) { + __bio_for_each_segment(tovec, to, i, 0) { fromvec = from->bi_io_vec + i; /* @@ -300,6 +300,7 @@ static void copy_to_high_bio_irq(struct bio *to, struct bio *from) */ vfrom = page_address(fromvec->bv_page) + tovec->bv_offset; + flush_dcache_page(tovec->bv_page); bounce_copy_vec(tovec, vfrom); } } @@ -316,7 +317,7 @@ static void bounce_end_io(struct bio *bio, mempool_t *pool) /* * free up bounce indirect pages used */ - bio_for_each_segment(bvec, bio, i) { + __bio_for_each_segment(bvec, bio, i, 0) { org_vec = bio_orig->bi_io_vec + i; if (bvec->bv_page == org_vec->bv_page) continue; @@ -406,6 +407,7 @@ static void __blk_queue_bounce(request_queue_t *q, struct bio **bio_orig, if (rw == WRITE) { char *vto, *vfrom; + flush_dcache_page(from->bv_page); vto = page_address(to->bv_page) + to->bv_offset; vfrom = kmap(from->bv_page) + from->bv_offset; memcpy(vto, vfrom, to->bv_len);