patch-2.1.102 linux/drivers/scsi/ide-scsi.c
Next file: linux/drivers/scsi/in2000.c
Previous file: linux/drivers/scsi/ibmmca.c
Back to the patch index
Back to the overall index
- Lines: 28
- Date:
Thu May 14 09:07:33 1998
- Orig file:
v2.1.101/linux/drivers/scsi/ide-scsi.c
- Orig date:
Thu May 7 22:51:51 1998
diff -u --recursive --new-file v2.1.101/linux/drivers/scsi/ide-scsi.c linux/drivers/scsi/ide-scsi.c
@@ -261,6 +261,7 @@
idescsi_pc_t *pc = (idescsi_pc_t *) rq->buffer;
int log = test_bit(IDESCSI_LOG_CMD, &scsi->log);
u8 *scsi_buf;
+ unsigned long flags;
if (rq->cmd != IDESCSI_PC_RQ) {
ide_end_request (uptodate, hwgroup);
@@ -287,7 +288,9 @@
} else printk("\n");
}
}
+ spin_lock_irqsave(&io_request_lock,flags);
pc->done(pc->scsi_cmd);
+ spin_unlock_irqrestore(&io_request_lock,flags);
idescsi_free_bh (rq->bh);
kfree(pc); kfree(rq);
scsi->pc = NULL;
@@ -767,7 +770,9 @@
rq->buffer = (char *) pc;
rq->bh = idescsi_dma_bh (drive, pc);
rq->cmd = IDESCSI_PC_RQ;
+ spin_unlock(&io_request_lock);
(void) ide_do_drive_cmd (drive, rq, ide_end);
+ spin_lock(&io_request_lock);
return 0;
abort:
if (pc) kfree (pc);
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov