Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

scsi: sun3_scsi: Use scsi_cmd_to_rq() instead of scsi_cmnd.request

Prepare for removal of the request pointer by using scsi_cmd_to_rq()
instead. This patch does not change any functionality.

Link: https://lore.kernel.org/r/20210809230355.8186-46-bvanassche@acm.org
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>

authored by

Bart Van Assche and committed by
Martin K. Petersen
6c5d5422 bbfa8d7d

+1 -1
+1 -1
drivers/scsi/sun3_scsi.c
··· 336 336 { 337 337 int wanted_len = cmd->SCp.this_residual; 338 338 339 - if (wanted_len < DMA_MIN_SIZE || blk_rq_is_passthrough(cmd->request)) 339 + if (wanted_len < DMA_MIN_SIZE || blk_rq_is_passthrough(scsi_cmd_to_rq(cmd))) 340 340 return 0; 341 341 342 342 return wanted_len;