diff options
Diffstat (limited to 'drivers/scsi/st.c')
-rw-r--r-- | drivers/scsi/st.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/scsi/st.c b/drivers/scsi/st.c index eb24efea8f14..b33d04250bbc 100644 --- a/drivers/scsi/st.c +++ b/drivers/scsi/st.c | |||
@@ -463,7 +463,7 @@ static void st_scsi_execute_end(struct request *req, int uptodate) | |||
463 | struct scsi_tape *STp = SRpnt->stp; | 463 | struct scsi_tape *STp = SRpnt->stp; |
464 | 464 | ||
465 | STp->buffer->cmdstat.midlevel_result = SRpnt->result = req->errors; | 465 | STp->buffer->cmdstat.midlevel_result = SRpnt->result = req->errors; |
466 | STp->buffer->cmdstat.residual = req->data_len; | 466 | STp->buffer->cmdstat.residual = req->resid_len; |
467 | 467 | ||
468 | if (SRpnt->waiting) | 468 | if (SRpnt->waiting) |
469 | complete(SRpnt->waiting); | 469 | complete(SRpnt->waiting); |
@@ -2964,7 +2964,7 @@ static int st_int_ioctl(struct scsi_tape *STp, unsigned int cmd_in, unsigned lon | |||
2964 | !(STp->use_pf & PF_TESTED)) { | 2964 | !(STp->use_pf & PF_TESTED)) { |
2965 | /* Try the other possible state of Page Format if not | 2965 | /* Try the other possible state of Page Format if not |
2966 | already tried */ | 2966 | already tried */ |
2967 | STp->use_pf = !STp->use_pf | PF_TESTED; | 2967 | STp->use_pf = (STp->use_pf ^ USE_PF) | PF_TESTED; |
2968 | st_release_request(SRpnt); | 2968 | st_release_request(SRpnt); |
2969 | SRpnt = NULL; | 2969 | SRpnt = NULL; |
2970 | return st_int_ioctl(STp, cmd_in, arg); | 2970 | return st_int_ioctl(STp, cmd_in, arg); |
@@ -3983,8 +3983,8 @@ static int st_probe(struct device *dev) | |||
3983 | return -ENODEV; | 3983 | return -ENODEV; |
3984 | } | 3984 | } |
3985 | 3985 | ||
3986 | i = min(SDp->request_queue->max_hw_segments, | 3986 | i = min(queue_max_hw_segments(SDp->request_queue), |
3987 | SDp->request_queue->max_phys_segments); | 3987 | queue_max_phys_segments(SDp->request_queue)); |
3988 | if (st_max_sg_segs < i) | 3988 | if (st_max_sg_segs < i) |
3989 | i = st_max_sg_segs; | 3989 | i = st_max_sg_segs; |
3990 | buffer = new_tape_buffer((SDp->host)->unchecked_isa_dma, i); | 3990 | buffer = new_tape_buffer((SDp->host)->unchecked_isa_dma, i); |