This patch does not change any functionality but reduces the size of
struct scsi_cmnd.
Cc: Douglas Gilbert <dgilbert@interlog.com>
Cc: Hannes Reinecke <hare@suse.com>
Cc: Christoph Hellwig <hch@lst.de>
Signed-off-by: Bart Van Assche <bvanassche@acm.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
                 * scsi_result_to_blk_status may have reset the host_byte
                 */
                scsi_req(req)->result = cmd->result;
-               scsi_req(req)->resid_len = scsi_get_resid(cmd);
        }
 
        /*
 
 struct scsi_data_buffer {
        struct sg_table table;
        unsigned length;
-       int resid;
 };
 
 /* embedded in scsi_cmnd */
 
 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)                   \