From: Christoph Hellwig Date: Sun, 29 Jan 2017 09:12:18 +0000 (+0100) Subject: scsi: storvsc: remove bogus code to transfer struct scatterlist X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=526db94e5de8923eb293ae5e2dd6b19d75e26e4c;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git scsi: storvsc: remove bogus code to transfer struct scatterlist Remove a piece of code in storvsc_queuecommand that tries to pass the physical address of the kernel struct scatterlist pointer to the host. Fortunately the code can't ever be reached anyway. Signed-off-by: Christoph Hellwig Reviewed-by: Bart Van Assche Reviewed-by: K. Y. Srinivasan Signed-off-by: Martin K. Petersen --- diff --git a/drivers/scsi/storvsc_drv.c b/drivers/scsi/storvsc_drv.c index 888e16ec8554..ceadf6b4ebc1 100644 --- a/drivers/scsi/storvsc_drv.c +++ b/drivers/scsi/storvsc_drv.c @@ -1635,13 +1635,6 @@ static int storvsc_queuecommand(struct Scsi_Host *host, struct scsi_cmnd *scmnd) page_to_pfn(sg_page((cur_sgl))); cur_sgl = sg_next(cur_sgl); } - - } else if (scsi_sglist(scmnd)) { - payload->range.len = length; - payload->range.offset = - virt_to_phys(scsi_sglist(scmnd)) & (PAGE_SIZE-1); - payload->range.pfn_array[0] = - virt_to_phys(scsi_sglist(scmnd)) >> PAGE_SHIFT; } cmd_request->payload = payload;