aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/NCR5380.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi/NCR5380.c')
-rw-r--r--drivers/scsi/NCR5380.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/scsi/NCR5380.c b/drivers/scsi/NCR5380.c
index 4368767929f6..cc9ecb35b412 100644
--- a/drivers/scsi/NCR5380.c
+++ b/drivers/scsi/NCR5380.c
@@ -1247,13 +1247,13 @@ static void collect_stats(struct NCR5380_hostdata *hostdata, Scsi_Cmnd * cmd)
1247 case WRITE: 1247 case WRITE:
1248 case WRITE_6: 1248 case WRITE_6:
1249 case WRITE_10: 1249 case WRITE_10:
1250 hostdata->time_write[cmd->device->id] += (jiffies - hostdata->timebase); 1250 hostdata->time_write[scmd_id(cmd)] += (jiffies - hostdata->timebase);
1251 hostdata->pendingw--; 1251 hostdata->pendingw--;
1252 break; 1252 break;
1253 case READ: 1253 case READ:
1254 case READ_6: 1254 case READ_6:
1255 case READ_10: 1255 case READ_10:
1256 hostdata->time_read[cmd->device->id] += (jiffies - hostdata->timebase); 1256 hostdata->time_read[scmd_id(cmd)] += (jiffies - hostdata->timebase);
1257 hostdata->pendingr--; 1257 hostdata->pendingr--;
1258 break; 1258 break;
1259 } 1259 }
@@ -1385,7 +1385,7 @@ static int NCR5380_select(struct Scsi_Host *instance, Scsi_Cmnd * cmd, int tag)
1385 * the host and target ID's on the SCSI bus. 1385 * the host and target ID's on the SCSI bus.
1386 */ 1386 */
1387 1387
1388 NCR5380_write(OUTPUT_DATA_REG, (hostdata->id_mask | (1 << cmd->device->id))); 1388 NCR5380_write(OUTPUT_DATA_REG, (hostdata->id_mask | (1 << scmd_id(cmd))));
1389 1389
1390 /* 1390 /*
1391 * Raise ATN while SEL is true before BSY goes false from arbitration, 1391 * Raise ATN while SEL is true before BSY goes false from arbitration,
@@ -1430,7 +1430,7 @@ static int NCR5380_select(struct Scsi_Host *instance, Scsi_Cmnd * cmd, int tag)
1430 1430
1431 udelay(1); 1431 udelay(1);
1432 1432
1433 dprintk(NDEBUG_SELECTION, ("scsi%d : selecting target %d\n", instance->host_no, cmd->device->id)); 1433 dprintk(NDEBUG_SELECTION, ("scsi%d : selecting target %d\n", instance->host_no, scmd_id(cmd)));
1434 1434
1435 /* 1435 /*
1436 * The SCSI specification calls for a 250 ms timeout for the actual 1436 * The SCSI specification calls for a 250 ms timeout for the actual
@@ -1483,7 +1483,7 @@ part2:
1483 1483
1484 if (!(NCR5380_read(STATUS_REG) & SR_BSY)) { 1484 if (!(NCR5380_read(STATUS_REG) & SR_BSY)) {
1485 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE); 1485 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE);
1486 if (hostdata->targets_present & (1 << cmd->device->id)) { 1486 if (hostdata->targets_present & (1 << scmd_id(cmd))) {
1487 printk(KERN_DEBUG "scsi%d : weirdness\n", instance->host_no); 1487 printk(KERN_DEBUG "scsi%d : weirdness\n", instance->host_no);
1488 if (hostdata->restart_select) 1488 if (hostdata->restart_select)
1489 printk(KERN_DEBUG "\trestart select\n"); 1489 printk(KERN_DEBUG "\trestart select\n");
@@ -1499,7 +1499,7 @@ part2:
1499 NCR5380_write(SELECT_ENABLE_REG, hostdata->id_mask); 1499 NCR5380_write(SELECT_ENABLE_REG, hostdata->id_mask);
1500 return 0; 1500 return 0;
1501 } 1501 }
1502 hostdata->targets_present |= (1 << cmd->device->id); 1502 hostdata->targets_present |= (1 << scmd_id(cmd));
1503 1503
1504 /* 1504 /*
1505 * Since we followed the SCSI spec, and raised ATN while SEL 1505 * Since we followed the SCSI spec, and raised ATN while SEL