]> git.baikalelectronics.ru Git - kernel.git/commit
bio: always copy back data for copied kernel requests
authorTejun Heo <tj@kernel.org>
Tue, 19 May 2009 09:33:06 +0000 (18:33 +0900)
committerJens Axboe <jens.axboe@oracle.com>
Tue, 19 May 2009 09:36:08 +0000 (11:36 +0200)
commitf0eeb50bcf8e4663853da89ff82a093b1d91b234
tree9efb7d762e51cb92dcee0e90ebdb76185aadebb4
parent3db08632078721470d60e769c90015f858baea23
bio: always copy back data for copied kernel requests

When a read bio_copy_kern() request fails, the content of the bounce
buffer is not copied back.  However, as request failure doesn't
necessarily mean complete failure, the buffer state can be useful.
This behavior is also inconsistent with the user map counterpart and
causes the subtle difference between bounced and unbounced IO causes
confusion.

This patch makes bio_copy_kern_endio() ignore @err and always copy
back data on request completion.

Signed-off-by: Tejun Heo <tj@kernel.org>
Cc: Boaz Harrosh <bharrosh@panasas.com>
Cc: James Bottomley <James.Bottomley@HansenPartnership.com>
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
fs/bio.c