]> git.karo-electronics.de Git - karo-tx-linux.git/commit
xen-blkfront: use a different scatterlist for each request
authorRoger Pau Monne <roger.pau@citrix.com>
Thu, 2 May 2013 08:58:50 +0000 (10:58 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 12 Aug 2013 01:35:24 +0000 (18:35 -0700)
commit7b2b160da7661bb2ade3f924b1bd3e3084e53341
treec4a6be4110a7572be202ac5a3bc35765c240bfae
parentd56b0022c1cc6c63ab85f3bebcd8bf3dfe4be5ca
xen-blkfront: use a different scatterlist for each request

commit b7649158a0d241f8d53d13ff7441858539e16656 upstream.

In blkif_queue_request blkfront iterates over the scatterlist in order
to set the segments of the request, and in blkif_completion blkfront
iterates over the raw request, which makes it hard to know the exact
position of the source and destination memory positions.

This can be solved by allocating a scatterlist for each request, that
will be keep until the request is finished, allowing us to copy the
data back to the original memory without having to iterate over the
raw request.

Oracle-Bug: 16660413 - LARGE ASYNCHRONOUS READS APPEAR BROKEN ON 2.6.39-400
CC: stable@vger.kernel.org
Signed-off-by: Roger Pau Monné <roger.pau@citrix.com>
Reported-and-Tested-by: Anne Milicia <anne.milicia@oracle.com>
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/block/xen-blkfront.c