diff options
author | Christoph Hellwig <hch@infradead.org> | 2011-04-04 09:42:14 -0400 |
---|---|---|
committer | James Bottomley <James.Bottomley@suse.de> | 2011-05-01 11:22:40 -0400 |
commit | 5cd049a59913f359e7d30c11d2dc6187822e77b1 (patch) | |
tree | f1406a16f6f0b786857e4433467d7ad762e45186 /drivers/scsi/u14-34f.c | |
parent | f04ca1b65480df9ecbaaa797e62b063387429410 (diff) |
[SCSI] remove cmd->serial_number litter
Stop using cmd->serial_number in printks.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: James Bottomley <James.Bottomley@suse.de>
Diffstat (limited to 'drivers/scsi/u14-34f.c')
-rw-r--r-- | drivers/scsi/u14-34f.c | 61 |
1 files changed, 27 insertions, 34 deletions
diff --git a/drivers/scsi/u14-34f.c b/drivers/scsi/u14-34f.c index edfc5da8be4c..90e104d6b558 100644 --- a/drivers/scsi/u14-34f.c +++ b/drivers/scsi/u14-34f.c | |||
@@ -1256,8 +1256,8 @@ static int u14_34f_queuecommand_lck(struct scsi_cmnd *SCpnt, void (*done)(struct | |||
1256 | j = ((struct hostdata *) SCpnt->device->host->hostdata)->board_number; | 1256 | j = ((struct hostdata *) SCpnt->device->host->hostdata)->board_number; |
1257 | 1257 | ||
1258 | if (SCpnt->host_scribble) | 1258 | if (SCpnt->host_scribble) |
1259 | panic("%s: qcomm, pid %ld, SCpnt %p already active.\n", | 1259 | panic("%s: qcomm, SCpnt %p already active.\n", |
1260 | BN(j), SCpnt->serial_number, SCpnt); | 1260 | BN(j), SCpnt); |
1261 | 1261 | ||
1262 | /* i is the mailbox number, look for the first free mailbox | 1262 | /* i is the mailbox number, look for the first free mailbox |
1263 | starting from last_cp_used */ | 1263 | starting from last_cp_used */ |
@@ -1286,9 +1286,9 @@ static int u14_34f_queuecommand_lck(struct scsi_cmnd *SCpnt, void (*done)(struct | |||
1286 | cpp->cpp_index = i; | 1286 | cpp->cpp_index = i; |
1287 | SCpnt->host_scribble = (unsigned char *) &cpp->cpp_index; | 1287 | SCpnt->host_scribble = (unsigned char *) &cpp->cpp_index; |
1288 | 1288 | ||
1289 | if (do_trace) printk("%s: qcomm, mbox %d, target %d.%d:%d, pid %ld.\n", | 1289 | if (do_trace) printk("%s: qcomm, mbox %d, target %d.%d:%d.\n", |
1290 | BN(j), i, SCpnt->device->channel, SCpnt->device->id, | 1290 | BN(j), i, SCpnt->device->channel, SCpnt->device->id, |
1291 | SCpnt->device->lun, SCpnt->serial_number); | 1291 | SCpnt->device->lun); |
1292 | 1292 | ||
1293 | cpp->opcode = OP_SCSI; | 1293 | cpp->opcode = OP_SCSI; |
1294 | cpp->channel = SCpnt->device->channel; | 1294 | cpp->channel = SCpnt->device->channel; |
@@ -1315,7 +1315,7 @@ static int u14_34f_queuecommand_lck(struct scsi_cmnd *SCpnt, void (*done)(struct | |||
1315 | unmap_dma(i, j); | 1315 | unmap_dma(i, j); |
1316 | SCpnt->host_scribble = NULL; | 1316 | SCpnt->host_scribble = NULL; |
1317 | scmd_printk(KERN_INFO, SCpnt, | 1317 | scmd_printk(KERN_INFO, SCpnt, |
1318 | "qcomm, pid %ld, adapter busy.\n", SCpnt->serial_number); | 1318 | "qcomm, adapter busy.\n"); |
1319 | return 1; | 1319 | return 1; |
1320 | } | 1320 | } |
1321 | 1321 | ||
@@ -1337,14 +1337,12 @@ static int u14_34f_eh_abort(struct scsi_cmnd *SCarg) { | |||
1337 | j = ((struct hostdata *) SCarg->device->host->hostdata)->board_number; | 1337 | j = ((struct hostdata *) SCarg->device->host->hostdata)->board_number; |
1338 | 1338 | ||
1339 | if (SCarg->host_scribble == NULL) { | 1339 | if (SCarg->host_scribble == NULL) { |
1340 | scmd_printk(KERN_INFO, SCarg, "abort, pid %ld inactive.\n", | 1340 | scmd_printk(KERN_INFO, SCarg, "abort, command inactive.\n"); |
1341 | SCarg->serial_number); | ||
1342 | return SUCCESS; | 1341 | return SUCCESS; |
1343 | } | 1342 | } |
1344 | 1343 | ||
1345 | i = *(unsigned int *)SCarg->host_scribble; | 1344 | i = *(unsigned int *)SCarg->host_scribble; |
1346 | scmd_printk(KERN_INFO, SCarg, "abort, mbox %d, pid %ld.\n", | 1345 | scmd_printk(KERN_INFO, SCarg, "abort, mbox %d.\n", i); |
1347 | i, SCarg->serial_number); | ||
1348 | 1346 | ||
1349 | if (i >= sh[j]->can_queue) | 1347 | if (i >= sh[j]->can_queue) |
1350 | panic("%s: abort, invalid SCarg->host_scribble.\n", BN(j)); | 1348 | panic("%s: abort, invalid SCarg->host_scribble.\n", BN(j)); |
@@ -1387,8 +1385,7 @@ static int u14_34f_eh_abort(struct scsi_cmnd *SCarg) { | |||
1387 | SCarg->result = DID_ABORT << 16; | 1385 | SCarg->result = DID_ABORT << 16; |
1388 | SCarg->host_scribble = NULL; | 1386 | SCarg->host_scribble = NULL; |
1389 | HD(j)->cp_stat[i] = FREE; | 1387 | HD(j)->cp_stat[i] = FREE; |
1390 | printk("%s, abort, mbox %d ready, DID_ABORT, pid %ld done.\n", | 1388 | printk("%s, abort, mbox %d ready, DID_ABORT, done.\n", BN(j), i); |
1391 | BN(j), i, SCarg->serial_number); | ||
1392 | SCarg->scsi_done(SCarg); | 1389 | SCarg->scsi_done(SCarg); |
1393 | return SUCCESS; | 1390 | return SUCCESS; |
1394 | } | 1391 | } |
@@ -1403,12 +1400,12 @@ static int u14_34f_eh_host_reset(struct scsi_cmnd *SCarg) { | |||
1403 | struct scsi_cmnd *SCpnt; | 1400 | struct scsi_cmnd *SCpnt; |
1404 | 1401 | ||
1405 | j = ((struct hostdata *) SCarg->device->host->hostdata)->board_number; | 1402 | j = ((struct hostdata *) SCarg->device->host->hostdata)->board_number; |
1406 | scmd_printk(KERN_INFO, SCarg, "reset, enter, pid %ld.\n", SCarg->serial_number); | 1403 | scmd_printk(KERN_INFO, SCarg, "reset, enter.\n"); |
1407 | 1404 | ||
1408 | spin_lock_irq(sh[j]->host_lock); | 1405 | spin_lock_irq(sh[j]->host_lock); |
1409 | 1406 | ||
1410 | if (SCarg->host_scribble == NULL) | 1407 | if (SCarg->host_scribble == NULL) |
1411 | printk("%s: reset, pid %ld inactive.\n", BN(j), SCarg->serial_number); | 1408 | printk("%s: reset, inactive.\n", BN(j)); |
1412 | 1409 | ||
1413 | if (HD(j)->in_reset) { | 1410 | if (HD(j)->in_reset) { |
1414 | printk("%s: reset, exit, already in reset.\n", BN(j)); | 1411 | printk("%s: reset, exit, already in reset.\n", BN(j)); |
@@ -1445,14 +1442,12 @@ static int u14_34f_eh_host_reset(struct scsi_cmnd *SCarg) { | |||
1445 | 1442 | ||
1446 | if (HD(j)->cp_stat[i] == READY || HD(j)->cp_stat[i] == ABORTING) { | 1443 | if (HD(j)->cp_stat[i] == READY || HD(j)->cp_stat[i] == ABORTING) { |
1447 | HD(j)->cp_stat[i] = ABORTING; | 1444 | HD(j)->cp_stat[i] = ABORTING; |
1448 | printk("%s: reset, mbox %d aborting, pid %ld.\n", | 1445 | printk("%s: reset, mbox %d aborting.\n", BN(j), i); |
1449 | BN(j), i, SCpnt->serial_number); | ||
1450 | } | 1446 | } |
1451 | 1447 | ||
1452 | else { | 1448 | else { |
1453 | HD(j)->cp_stat[i] = IN_RESET; | 1449 | HD(j)->cp_stat[i] = IN_RESET; |
1454 | printk("%s: reset, mbox %d in reset, pid %ld.\n", | 1450 | printk("%s: reset, mbox %d in reset.\n", BN(j), i); |
1455 | BN(j), i, SCpnt->serial_number); | ||
1456 | } | 1451 | } |
1457 | 1452 | ||
1458 | if (SCpnt->host_scribble == NULL) | 1453 | if (SCpnt->host_scribble == NULL) |
@@ -1500,8 +1495,7 @@ static int u14_34f_eh_host_reset(struct scsi_cmnd *SCarg) { | |||
1500 | /* This mailbox is still waiting for its interrupt */ | 1495 | /* This mailbox is still waiting for its interrupt */ |
1501 | HD(j)->cp_stat[i] = LOCKED; | 1496 | HD(j)->cp_stat[i] = LOCKED; |
1502 | 1497 | ||
1503 | printk("%s, reset, mbox %d locked, DID_RESET, pid %ld done.\n", | 1498 | printk("%s, reset, mbox %d locked, DID_RESET, done.\n", BN(j), i); |
1504 | BN(j), i, SCpnt->serial_number); | ||
1505 | } | 1499 | } |
1506 | 1500 | ||
1507 | else if (HD(j)->cp_stat[i] == ABORTING) { | 1501 | else if (HD(j)->cp_stat[i] == ABORTING) { |
@@ -1513,8 +1507,7 @@ static int u14_34f_eh_host_reset(struct scsi_cmnd *SCarg) { | |||
1513 | /* This mailbox was never queued to the adapter */ | 1507 | /* This mailbox was never queued to the adapter */ |
1514 | HD(j)->cp_stat[i] = FREE; | 1508 | HD(j)->cp_stat[i] = FREE; |
1515 | 1509 | ||
1516 | printk("%s, reset, mbox %d aborting, DID_RESET, pid %ld done.\n", | 1510 | printk("%s, reset, mbox %d aborting, DID_RESET, done.\n", BN(j), i); |
1517 | BN(j), i, SCpnt->serial_number); | ||
1518 | } | 1511 | } |
1519 | 1512 | ||
1520 | else | 1513 | else |
@@ -1528,7 +1521,7 @@ static int u14_34f_eh_host_reset(struct scsi_cmnd *SCarg) { | |||
1528 | HD(j)->in_reset = FALSE; | 1521 | HD(j)->in_reset = FALSE; |
1529 | do_trace = FALSE; | 1522 | do_trace = FALSE; |
1530 | 1523 | ||
1531 | if (arg_done) printk("%s: reset, exit, pid %ld done.\n", BN(j), SCarg->serial_number); | 1524 | if (arg_done) printk("%s: reset, exit, done.\n", BN(j)); |
1532 | else printk("%s: reset, exit.\n", BN(j)); | 1525 | else printk("%s: reset, exit.\n", BN(j)); |
1533 | 1526 | ||
1534 | spin_unlock_irq(sh[j]->host_lock); | 1527 | spin_unlock_irq(sh[j]->host_lock); |
@@ -1671,10 +1664,10 @@ static int reorder(unsigned int j, unsigned long cursec, | |||
1671 | if (link_statistics && (overlap || !(flushcount % link_statistics))) | 1664 | if (link_statistics && (overlap || !(flushcount % link_statistics))) |
1672 | for (n = 0; n < n_ready; n++) { | 1665 | for (n = 0; n < n_ready; n++) { |
1673 | k = il[n]; cpp = &HD(j)->cp[k]; SCpnt = cpp->SCpnt; | 1666 | k = il[n]; cpp = &HD(j)->cp[k]; SCpnt = cpp->SCpnt; |
1674 | printk("%s %d.%d:%d pid %ld mb %d fc %d nr %d sec %ld ns %u"\ | 1667 | printk("%s %d.%d:%d mb %d fc %d nr %d sec %ld ns %u"\ |
1675 | " cur %ld s:%c r:%c rev:%c in:%c ov:%c xd %d.\n", | 1668 | " cur %ld s:%c r:%c rev:%c in:%c ov:%c xd %d.\n", |
1676 | (ihdlr ? "ihdlr" : "qcomm"), SCpnt->channel, SCpnt->target, | 1669 | (ihdlr ? "ihdlr" : "qcomm"), SCpnt->channel, SCpnt->target, |
1677 | SCpnt->lun, SCpnt->serial_number, k, flushcount, n_ready, | 1670 | SCpnt->lun, k, flushcount, n_ready, |
1678 | blk_rq_pos(SCpnt->request), blk_rq_sectors(SCpnt->request), | 1671 | blk_rq_pos(SCpnt->request), blk_rq_sectors(SCpnt->request), |
1679 | cursec, YESNO(s), YESNO(r), YESNO(rev), YESNO(input_only), | 1672 | cursec, YESNO(s), YESNO(r), YESNO(rev), YESNO(input_only), |
1680 | YESNO(overlap), cpp->xdir); | 1673 | YESNO(overlap), cpp->xdir); |
@@ -1709,9 +1702,9 @@ static void flush_dev(struct scsi_device *dev, unsigned long cursec, unsigned in | |||
1709 | 1702 | ||
1710 | if (wait_on_busy(sh[j]->io_port, MAXLOOP)) { | 1703 | if (wait_on_busy(sh[j]->io_port, MAXLOOP)) { |
1711 | scmd_printk(KERN_INFO, SCpnt, | 1704 | scmd_printk(KERN_INFO, SCpnt, |
1712 | "%s, pid %ld, mbox %d, adapter" | 1705 | "%s, mbox %d, adapter" |
1713 | " busy, will abort.\n", (ihdlr ? "ihdlr" : "qcomm"), | 1706 | " busy, will abort.\n", (ihdlr ? "ihdlr" : "qcomm"), |
1714 | SCpnt->serial_number, k); | 1707 | k); |
1715 | HD(j)->cp_stat[k] = ABORTING; | 1708 | HD(j)->cp_stat[k] = ABORTING; |
1716 | continue; | 1709 | continue; |
1717 | } | 1710 | } |
@@ -1793,12 +1786,12 @@ static irqreturn_t ihdlr(unsigned int j) | |||
1793 | if (SCpnt == NULL) panic("%s: ihdlr, mbox %d, SCpnt == NULL.\n", BN(j), i); | 1786 | if (SCpnt == NULL) panic("%s: ihdlr, mbox %d, SCpnt == NULL.\n", BN(j), i); |
1794 | 1787 | ||
1795 | if (SCpnt->host_scribble == NULL) | 1788 | if (SCpnt->host_scribble == NULL) |
1796 | panic("%s: ihdlr, mbox %d, pid %ld, SCpnt %p garbled.\n", BN(j), i, | 1789 | panic("%s: ihdlr, mbox %d, SCpnt %p garbled.\n", BN(j), i, |
1797 | SCpnt->serial_number, SCpnt); | 1790 | SCpnt); |
1798 | 1791 | ||
1799 | if (*(unsigned int *)SCpnt->host_scribble != i) | 1792 | if (*(unsigned int *)SCpnt->host_scribble != i) |
1800 | panic("%s: ihdlr, mbox %d, pid %ld, index mismatch %d.\n", | 1793 | panic("%s: ihdlr, mbox %d, index mismatch %d.\n", |
1801 | BN(j), i, SCpnt->serial_number, *(unsigned int *)SCpnt->host_scribble); | 1794 | BN(j), i, *(unsigned int *)SCpnt->host_scribble); |
1802 | 1795 | ||
1803 | sync_dma(i, j); | 1796 | sync_dma(i, j); |
1804 | 1797 | ||
@@ -1841,8 +1834,8 @@ static irqreturn_t ihdlr(unsigned int j) | |||
1841 | (!(tstatus == CHECK_CONDITION && HD(j)->iocount <= 1000 && | 1834 | (!(tstatus == CHECK_CONDITION && HD(j)->iocount <= 1000 && |
1842 | (SCpnt->sense_buffer[2] & 0xf) == NOT_READY))) | 1835 | (SCpnt->sense_buffer[2] & 0xf) == NOT_READY))) |
1843 | scmd_printk(KERN_INFO, SCpnt, | 1836 | scmd_printk(KERN_INFO, SCpnt, |
1844 | "ihdlr, pid %ld, target_status 0x%x, sense key 0x%x.\n", | 1837 | "ihdlr, target_status 0x%x, sense key 0x%x.\n", |
1845 | SCpnt->serial_number, spp->target_status, | 1838 | spp->target_status, |
1846 | SCpnt->sense_buffer[2]); | 1839 | SCpnt->sense_buffer[2]); |
1847 | 1840 | ||
1848 | HD(j)->target_to[scmd_id(SCpnt)][scmd_channel(SCpnt)] = 0; | 1841 | HD(j)->target_to[scmd_id(SCpnt)][scmd_channel(SCpnt)] = 0; |
@@ -1913,8 +1906,8 @@ static irqreturn_t ihdlr(unsigned int j) | |||
1913 | do_trace || msg_byte(spp->target_status)) | 1906 | do_trace || msg_byte(spp->target_status)) |
1914 | #endif | 1907 | #endif |
1915 | scmd_printk(KERN_INFO, SCpnt, "ihdlr, mbox %2d, err 0x%x:%x,"\ | 1908 | scmd_printk(KERN_INFO, SCpnt, "ihdlr, mbox %2d, err 0x%x:%x,"\ |
1916 | " pid %ld, reg 0x%x, count %d.\n", | 1909 | " reg 0x%x, count %d.\n", |
1917 | i, spp->adapter_status, spp->target_status, SCpnt->serial_number, | 1910 | i, spp->adapter_status, spp->target_status, |
1918 | reg, HD(j)->iocount); | 1911 | reg, HD(j)->iocount); |
1919 | 1912 | ||
1920 | unmap_dma(i, j); | 1913 | unmap_dma(i, j); |