diff options
author | Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> | 2013-01-16 11:36:23 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-03-04 06:06:40 +0800 |
commit | c93c85196e2c7001daa8a04b83a9d6dd4febfb59 (patch) | |
tree | 64dab661cb1847cbf60d8017364ab5b2e1172d8d | |
parent | f8cf1124a8f6cdd4ebc834ec3d848508e229e1d4 (diff) | |
download | lwn-c93c85196e2c7001daa8a04b83a9d6dd4febfb59.tar.gz lwn-c93c85196e2c7001daa8a04b83a9d6dd4febfb59.zip |
xen/blkback: Don't trust the handle from the frontend.
commit 01c681d4c70d64cb72142a2823f27c4146a02e63 upstream.
The 'handle' is the device that the request is from. For the life-time
of the ring we copy it from a request to a response so that the frontend
is not surprised by it. But we do not need it - when we start processing
I/Os we have our own 'struct phys_req' which has only most essential
information about the request. In fact the 'vbd_translate' ends up
over-writing the preq.dev with a value from the backend.
This assignment of preq.dev with the 'handle' value is superfluous
so lets not do it.
Acked-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Ian Campbell <ian.campbell@citrix.com>
Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/block/xen-blkback/blkback.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/block/xen-blkback/blkback.c b/drivers/block/xen-blkback/blkback.c index c6decb901e5e..73d8c9276b9b 100644 --- a/drivers/block/xen-blkback/blkback.c +++ b/drivers/block/xen-blkback/blkback.c @@ -623,7 +623,6 @@ static int dispatch_rw_block_io(struct xen_blkif *blkif, goto fail_response; } - preq.dev = req->u.rw.handle; preq.sector_number = req->u.rw.sector_number; preq.nr_sects = 0; |