aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorBart Van Assche <[email protected]>2019-02-08 13:25:03 -0800
committerMartin K. Petersen <[email protected]>2019-02-12 11:13:41 -0500
commit9fa505adf9f2914637e4e81620f62dcdaa575f71 (patch)
tree6fd5629d85871c75e33aa496da94d1dc62392d74 /include
parent80f82c169b68b2dcd5adfc4625edd93a2ab954cf (diff)
scsi: core: Move resid from scsi_data_buffer to scsi_cmnd
This patch does not change any functionality but reduces the size of struct scsi_cmnd. Cc: Douglas Gilbert <[email protected]> Cc: Hannes Reinecke <[email protected]> Cc: Christoph Hellwig <[email protected]> Signed-off-by: Bart Van Assche <[email protected]> Reviewed-by: Christoph Hellwig <[email protected]> Signed-off-by: Martin K. Petersen <[email protected]>
Diffstat (limited to 'include')
-rw-r--r--include/scsi/scsi_cmnd.h5
1 files changed, 2 insertions, 3 deletions
diff --git a/include/scsi/scsi_cmnd.h b/include/scsi/scsi_cmnd.h
index af6ae3e1eba6..6c7793c2ad01 100644
--- a/include/scsi/scsi_cmnd.h
+++ b/include/scsi/scsi_cmnd.h
@@ -35,7 +35,6 @@ struct scsi_driver;
struct scsi_data_buffer {
struct sg_table table;
unsigned length;
- int resid;
};
/* embedded in scsi_cmnd */
@@ -202,12 +201,12 @@ static inline unsigned scsi_bufflen(struct scsi_cmnd *cmd)
static inline void scsi_set_resid(struct scsi_cmnd *cmd, int resid)
{
- cmd->sdb.resid = resid;
+ cmd->req.resid_len = resid;
}
static inline int scsi_get_resid(struct scsi_cmnd *cmd)
{
- return cmd->sdb.resid;
+ return cmd->req.resid_len;
}
#define scsi_for_each_sg(cmd, sg, nseg, __i) \