[SCSI] block: fix the partial mappings with struct rq_map_data
authorFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Thu, 18 Dec 2008 05:49:37 +0000 (14:49 +0900)
committerJames Bottomley <James.Bottomley@HansenPartnership.com>
Fri, 2 Jan 2009 17:10:08 +0000 (11:10 -0600)
commit56c451f4b583ccdf80c9e676179c9cb49de86745
tree7ad9daeafb88e3c4390bf7a2db0c203fe2642728
parente623ddb4e940b266adc77ba1cc28a3554aa90e79
[SCSI] block: fix the partial mappings with struct rq_map_data

This fixes bio_copy_user_iov to properly handle the partial mappings
with struct rq_map_data (which only sg uses for now but st and osst
will shortly). It adds the offset member to struct rq_map_data and
changes blk_rq_map_user to update it so that bio_copy_user_iov can add
an appropriate page frame via bio_add_pc_page().

Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
Acked-by: Jens Axboe <jens.axboe@oracle.com>
Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
block/blk-map.c
drivers/scsi/sg.c
fs/bio.c
include/linux/blkdev.h