Commit 84f7a9de authored by Bart Van Assche's avatar Bart Van Assche Committed by Martin K. Petersen

scsi: sd: Remove a local variable

This patch does not change any functionality.
Reviewed-by: default avatarHannes Reinecke <hare@suse.com>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
[ bvanassche: extracted this patch from a larger patch ]
Signed-off-by: default avatarBart Van Assche <bvanassche@acm.org>
Signed-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent 326a859b
...@@ -1015,7 +1015,6 @@ static blk_status_t sd_setup_write_same_cmnd(struct scsi_cmnd *cmd) ...@@ -1015,7 +1015,6 @@ static blk_status_t sd_setup_write_same_cmnd(struct scsi_cmnd *cmd)
struct bio *bio = rq->bio; struct bio *bio = rq->bio;
sector_t sector = blk_rq_pos(rq); sector_t sector = blk_rq_pos(rq);
unsigned int nr_sectors = blk_rq_sectors(rq); unsigned int nr_sectors = blk_rq_sectors(rq);
unsigned int nr_bytes = blk_rq_bytes(rq);
blk_status_t ret; blk_status_t ret;
if (sdkp->device->no_write_same) if (sdkp->device->no_write_same)
...@@ -1055,7 +1054,7 @@ static blk_status_t sd_setup_write_same_cmnd(struct scsi_cmnd *cmd) ...@@ -1055,7 +1054,7 @@ static blk_status_t sd_setup_write_same_cmnd(struct scsi_cmnd *cmd)
*/ */
rq->__data_len = sdp->sector_size; rq->__data_len = sdp->sector_size;
ret = scsi_init_io(cmd); ret = scsi_init_io(cmd);
rq->__data_len = nr_bytes; rq->__data_len = blk_rq_bytes(rq);
return ret; return ret;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment