aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/scsi_lib.c
diff options
context:
space:
mode:
authorAlan Stern <stern@rowland.harvard.edu>2005-09-15 13:52:51 -0400
committerJames Bottomley <jejb@mulgrave.(none)>2005-09-17 16:24:53 -0400
commitb95be99d52ce4f9db9ff0bd5f10e9e2066da6d2e (patch)
tree6b01de07c638fd596cc254ca6a095aa4f5ef9ba2 /drivers/scsi/scsi_lib.c
parent1832a5862f2e1b4e5835611ee14bc30a8ed3cad5 (diff)
[SCSI] fix oops in scsi_release_buffers()
I found one other thing that needs to be fixed. The call to scsi_release_buffers in scsi_unprep_request causes an oops, because the sgtable has already been freed in scsi_io_completion. The following patch is needed. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/scsi_lib.c')
-rw-r--r--drivers/scsi/scsi_lib.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c
index 0c6924eecf59..f065cbc1a6e5 100644
--- a/drivers/scsi/scsi_lib.c
+++ b/drivers/scsi/scsi_lib.c
@@ -118,7 +118,6 @@ static void scsi_unprep_request(struct request *req)
118 req->flags &= ~REQ_DONTPREP; 118 req->flags &= ~REQ_DONTPREP;
119 req->special = (req->flags & REQ_SPECIAL) ? cmd->sc_request : NULL; 119 req->special = (req->flags & REQ_SPECIAL) ? cmd->sc_request : NULL;
120 120
121 scsi_release_buffers(cmd);
122 scsi_put_command(cmd); 121 scsi_put_command(cmd);
123} 122}
124 123
@@ -1512,7 +1511,6 @@ static void scsi_request_fn(struct request_queue *q)
1512 * cases (host limits or settings) should run the queue at some 1511 * cases (host limits or settings) should run the queue at some
1513 * later time. 1512 * later time.
1514 */ 1513 */
1515 scsi_unprep_request(req);
1516 spin_lock_irq(q->queue_lock); 1514 spin_lock_irq(q->queue_lock);
1517 blk_requeue_request(q, req); 1515 blk_requeue_request(q, req);
1518 sdev->device_busy--; 1516 sdev->device_busy--;