diff options
Diffstat (limited to 'drivers/scsi/wd7000.c')
| -rw-r--r-- | drivers/scsi/wd7000.c | 41 |
1 files changed, 19 insertions, 22 deletions
diff --git a/drivers/scsi/wd7000.c b/drivers/scsi/wd7000.c index f94d73611ab4..2d7c62f3a7cc 100644 --- a/drivers/scsi/wd7000.c +++ b/drivers/scsi/wd7000.c | |||
| @@ -1295,9 +1295,6 @@ static void wd7000_revision(Adapter * host) | |||
| 1295 | } | 1295 | } |
| 1296 | 1296 | ||
| 1297 | 1297 | ||
| 1298 | #undef SPRINTF | ||
| 1299 | #define SPRINTF(args...) { seq_printf(m, ## args); } | ||
| 1300 | |||
| 1301 | static int wd7000_set_info(struct Scsi_Host *host, char *buffer, int length) | 1298 | static int wd7000_set_info(struct Scsi_Host *host, char *buffer, int length) |
| 1302 | { | 1299 | { |
| 1303 | dprintk("Buffer = <%.*s>, length = %d\n", length, buffer, length); | 1300 | dprintk("Buffer = <%.*s>, length = %d\n", length, buffer, length); |
| @@ -1320,43 +1317,43 @@ static int wd7000_show_info(struct seq_file *m, struct Scsi_Host *host) | |||
| 1320 | #endif | 1317 | #endif |
| 1321 | 1318 | ||
| 1322 | spin_lock_irqsave(host->host_lock, flags); | 1319 | spin_lock_irqsave(host->host_lock, flags); |
| 1323 | SPRINTF("Host scsi%d: Western Digital WD-7000 (rev %d.%d)\n", host->host_no, adapter->rev1, adapter->rev2); | 1320 | seq_printf(m, "Host scsi%d: Western Digital WD-7000 (rev %d.%d)\n", host->host_no, adapter->rev1, adapter->rev2); |
| 1324 | SPRINTF(" IO base: 0x%x\n", adapter->iobase); | 1321 | seq_printf(m, " IO base: 0x%x\n", adapter->iobase); |
| 1325 | SPRINTF(" IRQ: %d\n", adapter->irq); | 1322 | seq_printf(m, " IRQ: %d\n", adapter->irq); |
| 1326 | SPRINTF(" DMA channel: %d\n", adapter->dma); | 1323 | seq_printf(m, " DMA channel: %d\n", adapter->dma); |
| 1327 | SPRINTF(" Interrupts: %d\n", adapter->int_counter); | 1324 | seq_printf(m, " Interrupts: %d\n", adapter->int_counter); |
| 1328 | SPRINTF(" BUS_ON time: %d nanoseconds\n", adapter->bus_on * 125); | 1325 | seq_printf(m, " BUS_ON time: %d nanoseconds\n", adapter->bus_on * 125); |
| 1329 | SPRINTF(" BUS_OFF time: %d nanoseconds\n", adapter->bus_off * 125); | 1326 | seq_printf(m, " BUS_OFF time: %d nanoseconds\n", adapter->bus_off * 125); |
| 1330 | 1327 | ||
| 1331 | #ifdef WD7000_DEBUG | 1328 | #ifdef WD7000_DEBUG |
| 1332 | ogmbs = adapter->mb.ogmb; | 1329 | ogmbs = adapter->mb.ogmb; |
| 1333 | icmbs = adapter->mb.icmb; | 1330 | icmbs = adapter->mb.icmb; |
| 1334 | 1331 | ||
| 1335 | SPRINTF("\nControl port value: 0x%x\n", adapter->control); | 1332 | seq_printf(m, "\nControl port value: 0x%x\n", adapter->control); |
| 1336 | SPRINTF("Incoming mailbox:\n"); | 1333 | seq_printf(m, "Incoming mailbox:\n"); |
| 1337 | SPRINTF(" size: %d\n", ICMB_CNT); | 1334 | seq_printf(m, " size: %d\n", ICMB_CNT); |
| 1338 | SPRINTF(" queued messages: "); | 1335 | seq_printf(m, " queued messages: "); |
| 1339 | 1336 | ||
| 1340 | for (i = count = 0; i < ICMB_CNT; i++) | 1337 | for (i = count = 0; i < ICMB_CNT; i++) |
| 1341 | if (icmbs[i].status) { | 1338 | if (icmbs[i].status) { |
| 1342 | count++; | 1339 | count++; |
| 1343 | SPRINTF("0x%x ", i); | 1340 | seq_printf(m, "0x%x ", i); |
| 1344 | } | 1341 | } |
| 1345 | 1342 | ||
| 1346 | SPRINTF(count ? "\n" : "none\n"); | 1343 | seq_printf(m, count ? "\n" : "none\n"); |
| 1347 | 1344 | ||
| 1348 | SPRINTF("Outgoing mailbox:\n"); | 1345 | seq_printf(m, "Outgoing mailbox:\n"); |
| 1349 | SPRINTF(" size: %d\n", OGMB_CNT); | 1346 | seq_printf(m, " size: %d\n", OGMB_CNT); |
| 1350 | SPRINTF(" next message: 0x%x\n", adapter->next_ogmb); | 1347 | seq_printf(m, " next message: 0x%x\n", adapter->next_ogmb); |
| 1351 | SPRINTF(" queued messages: "); | 1348 | seq_printf(m, " queued messages: "); |
| 1352 | 1349 | ||
| 1353 | for (i = count = 0; i < OGMB_CNT; i++) | 1350 | for (i = count = 0; i < OGMB_CNT; i++) |
| 1354 | if (ogmbs[i].status) { | 1351 | if (ogmbs[i].status) { |
| 1355 | count++; | 1352 | count++; |
| 1356 | SPRINTF("0x%x ", i); | 1353 | seq_printf(m, "0x%x ", i); |
| 1357 | } | 1354 | } |
| 1358 | 1355 | ||
| 1359 | SPRINTF(count ? "\n" : "none\n"); | 1356 | seq_printf(m, count ? "\n" : "none\n"); |
| 1360 | #endif | 1357 | #endif |
| 1361 | 1358 | ||
| 1362 | spin_unlock_irqrestore(host->host_lock, flags); | 1359 | spin_unlock_irqrestore(host->host_lock, flags); |
