aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi
diff options
context:
space:
mode:
authorFinn Thain <fthain@telegraphics.com.au>2014-03-17 20:42:20 -0400
committerChristoph Hellwig <hch@lst.de>2014-05-28 06:10:43 -0400
commitd65e634a86e681ffd36717cde63fb81edbb6f719 (patch)
tree3fb1e463c652f6bdb469dd503c7483f56b420aaa /drivers/scsi
parent8ad3a593145b4941a1ee9e52896da67e38d082da (diff)
scsi/NCR5380: adopt dprintk()
All NCR5380 drivers already include the NCR5380.h header. Better to adopt those macros rather than have three variations on them. Moreover, the macros in NCR5380.h are preferable because the atari_NCR5380 and sun3_NCR5380 versions are inflexible. For example, they can't accomodate dprintk(NDEBUG_MAIN | NDEBUG_QUEUES, ...) Replace the *_PRINTK macros from atari_NCR5380.h and sun3_NCR5380.h with the equivalent macros from NCR5380.h. Signed-off-by: Finn Thain <fthain@telegraphics.com.au> Acked-by: Sam Creasey <sammy@sammy.net> Acked-by: Michael Schmitz <schmitz@debian.org> Signed-off-by: Christoph Hellwig <hch@lst.de>
Diffstat (limited to 'drivers/scsi')
-rw-r--r--drivers/scsi/atari_NCR5380.c130
-rw-r--r--drivers/scsi/atari_scsi.c16
-rw-r--r--drivers/scsi/sun3_NCR5380.c122
3 files changed, 134 insertions, 134 deletions
diff --git a/drivers/scsi/atari_NCR5380.c b/drivers/scsi/atari_NCR5380.c
index 82ed2fd6be1e..9e642035b38f 100644
--- a/drivers/scsi/atari_NCR5380.c
+++ b/drivers/scsi/atari_NCR5380.c
@@ -370,7 +370,7 @@ static int is_lun_busy(Scsi_Cmnd *cmd, int should_be_tagged)
370 return 0; 370 return 0;
371 if (TagAlloc[cmd->device->id][cmd->device->lun].nr_allocated >= 371 if (TagAlloc[cmd->device->id][cmd->device->lun].nr_allocated >=
372 TagAlloc[cmd->device->id][cmd->device->lun].queue_size) { 372 TagAlloc[cmd->device->id][cmd->device->lun].queue_size) {
373 TAG_PRINTK("scsi%d: target %d lun %d: no free tags\n", 373 dprintk(NDEBUG_TAGS, "scsi%d: target %d lun %d: no free tags\n",
374 H_NO(cmd), cmd->device->id, cmd->device->lun); 374 H_NO(cmd), cmd->device->id, cmd->device->lun);
375 return 1; 375 return 1;
376 } 376 }
@@ -394,7 +394,7 @@ static void cmd_get_tag(Scsi_Cmnd *cmd, int should_be_tagged)
394 !setup_use_tagged_queuing || !cmd->device->tagged_supported) { 394 !setup_use_tagged_queuing || !cmd->device->tagged_supported) {
395 cmd->tag = TAG_NONE; 395 cmd->tag = TAG_NONE;
396 hostdata->busy[cmd->device->id] |= (1 << cmd->device->lun); 396 hostdata->busy[cmd->device->id] |= (1 << cmd->device->lun);
397 TAG_PRINTK("scsi%d: target %d lun %d now allocated by untagged " 397 dprintk(NDEBUG_TAGS, "scsi%d: target %d lun %d now allocated by untagged "
398 "command\n", H_NO(cmd), cmd->device->id, cmd->device->lun); 398 "command\n", H_NO(cmd), cmd->device->id, cmd->device->lun);
399 } else { 399 } else {
400 TAG_ALLOC *ta = &TagAlloc[cmd->device->id][cmd->device->lun]; 400 TAG_ALLOC *ta = &TagAlloc[cmd->device->id][cmd->device->lun];
@@ -402,7 +402,7 @@ static void cmd_get_tag(Scsi_Cmnd *cmd, int should_be_tagged)
402 cmd->tag = find_first_zero_bit(ta->allocated, MAX_TAGS); 402 cmd->tag = find_first_zero_bit(ta->allocated, MAX_TAGS);
403 set_bit(cmd->tag, ta->allocated); 403 set_bit(cmd->tag, ta->allocated);
404 ta->nr_allocated++; 404 ta->nr_allocated++;
405 TAG_PRINTK("scsi%d: using tag %d for target %d lun %d " 405 dprintk(NDEBUG_TAGS, "scsi%d: using tag %d for target %d lun %d "
406 "(now %d tags in use)\n", 406 "(now %d tags in use)\n",
407 H_NO(cmd), cmd->tag, cmd->device->id, 407 H_NO(cmd), cmd->tag, cmd->device->id,
408 cmd->device->lun, ta->nr_allocated); 408 cmd->device->lun, ta->nr_allocated);
@@ -420,7 +420,7 @@ static void cmd_free_tag(Scsi_Cmnd *cmd)
420 420
421 if (cmd->tag == TAG_NONE) { 421 if (cmd->tag == TAG_NONE) {
422 hostdata->busy[cmd->device->id] &= ~(1 << cmd->device->lun); 422 hostdata->busy[cmd->device->id] &= ~(1 << cmd->device->lun);
423 TAG_PRINTK("scsi%d: target %d lun %d untagged cmd finished\n", 423 dprintk(NDEBUG_TAGS, "scsi%d: target %d lun %d untagged cmd finished\n",
424 H_NO(cmd), cmd->device->id, cmd->device->lun); 424 H_NO(cmd), cmd->device->id, cmd->device->lun);
425 } else if (cmd->tag >= MAX_TAGS) { 425 } else if (cmd->tag >= MAX_TAGS) {
426 printk(KERN_NOTICE "scsi%d: trying to free bad tag %d!\n", 426 printk(KERN_NOTICE "scsi%d: trying to free bad tag %d!\n",
@@ -429,7 +429,7 @@ static void cmd_free_tag(Scsi_Cmnd *cmd)
429 TAG_ALLOC *ta = &TagAlloc[cmd->device->id][cmd->device->lun]; 429 TAG_ALLOC *ta = &TagAlloc[cmd->device->id][cmd->device->lun];
430 clear_bit(cmd->tag, ta->allocated); 430 clear_bit(cmd->tag, ta->allocated);
431 ta->nr_allocated--; 431 ta->nr_allocated--;
432 TAG_PRINTK("scsi%d: freed tag %d for target %d lun %d\n", 432 dprintk(NDEBUG_TAGS, "scsi%d: freed tag %d for target %d lun %d\n",
433 H_NO(cmd), cmd->tag, cmd->device->id, cmd->device->lun); 433 H_NO(cmd), cmd->tag, cmd->device->id, cmd->device->lun);
434 } 434 }
435} 435}
@@ -478,7 +478,7 @@ static void merge_contiguous_buffers(Scsi_Cmnd *cmd)
478 for (endaddr = virt_to_phys(cmd->SCp.ptr + cmd->SCp.this_residual - 1) + 1; 478 for (endaddr = virt_to_phys(cmd->SCp.ptr + cmd->SCp.this_residual - 1) + 1;
479 cmd->SCp.buffers_residual && 479 cmd->SCp.buffers_residual &&
480 virt_to_phys(sg_virt(&cmd->SCp.buffer[1])) == endaddr;) { 480 virt_to_phys(sg_virt(&cmd->SCp.buffer[1])) == endaddr;) {
481 MER_PRINTK("VTOP(%p) == %08lx -> merging\n", 481 dprintk(NDEBUG_MERGING, "VTOP(%p) == %08lx -> merging\n",
482 page_address(sg_page(&cmd->SCp.buffer[1])), endaddr); 482 page_address(sg_page(&cmd->SCp.buffer[1])), endaddr);
483#if (NDEBUG & NDEBUG_MERGING) 483#if (NDEBUG & NDEBUG_MERGING)
484 ++cnt; 484 ++cnt;
@@ -490,7 +490,7 @@ static void merge_contiguous_buffers(Scsi_Cmnd *cmd)
490 } 490 }
491#if (NDEBUG & NDEBUG_MERGING) 491#if (NDEBUG & NDEBUG_MERGING)
492 if (oldlen != cmd->SCp.this_residual) 492 if (oldlen != cmd->SCp.this_residual)
493 MER_PRINTK("merged %d buffers from %p, new length %08x\n", 493 dprintk(NDEBUG_MERGING, "merged %d buffers from %p, new length %08x\n",
494 cnt, cmd->SCp.ptr, cmd->SCp.this_residual); 494 cnt, cmd->SCp.ptr, cmd->SCp.this_residual);
495#endif 495#endif
496} 496}
@@ -676,7 +676,7 @@ static inline void NCR5380_all_init(void)
676{ 676{
677 static int done = 0; 677 static int done = 0;
678 if (!done) { 678 if (!done) {
679 INI_PRINTK("scsi : NCR5380_all_init()\n"); 679 dprintk(NDEBUG_INIT, "scsi : NCR5380_all_init()\n");
680 done = 1; 680 done = 1;
681 } 681 }
682} 682}
@@ -984,7 +984,7 @@ static int NCR5380_queue_command_lck(Scsi_Cmnd *cmd, void (*done)(Scsi_Cmnd *))
984 } 984 }
985 local_irq_restore(flags); 985 local_irq_restore(flags);
986 986
987 QU_PRINTK("scsi%d: command added to %s of queue\n", H_NO(cmd), 987 dprintk(NDEBUG_QUEUES, "scsi%d: command added to %s of queue\n", H_NO(cmd),
988 (cmd->cmnd[0] == REQUEST_SENSE) ? "head" : "tail"); 988 (cmd->cmnd[0] == REQUEST_SENSE) ? "head" : "tail");
989 989
990 /* If queue_command() is called from an interrupt (real one or bottom 990 /* If queue_command() is called from an interrupt (real one or bottom
@@ -1054,7 +1054,7 @@ static void NCR5380_main(struct work_struct *work)
1054 done = 1; 1054 done = 1;
1055 1055
1056 if (!hostdata->connected) { 1056 if (!hostdata->connected) {
1057 MAIN_PRINTK("scsi%d: not connected\n", HOSTNO); 1057 dprintk(NDEBUG_MAIN, "scsi%d: not connected\n", HOSTNO);
1058 /* 1058 /*
1059 * Search through the issue_queue for a command destined 1059 * Search through the issue_queue for a command destined
1060 * for a target that's not busy. 1060 * for a target that's not busy.
@@ -1107,7 +1107,7 @@ static void NCR5380_main(struct work_struct *work)
1107 * On failure, we must add the command back to the 1107 * On failure, we must add the command back to the
1108 * issue queue so we can keep trying. 1108 * issue queue so we can keep trying.
1109 */ 1109 */
1110 MAIN_PRINTK("scsi%d: main(): command for target %d " 1110 dprintk(NDEBUG_MAIN, "scsi%d: main(): command for target %d "
1111 "lun %d removed from issue_queue\n", 1111 "lun %d removed from issue_queue\n",
1112 HOSTNO, tmp->device->id, tmp->device->lun); 1112 HOSTNO, tmp->device->id, tmp->device->lun);
1113 /* 1113 /*
@@ -1140,7 +1140,7 @@ static void NCR5380_main(struct work_struct *work)
1140#endif 1140#endif
1141 falcon_dont_release--; 1141 falcon_dont_release--;
1142 local_irq_restore(flags); 1142 local_irq_restore(flags);
1143 MAIN_PRINTK("scsi%d: main(): select() failed, " 1143 dprintk(NDEBUG_MAIN, "scsi%d: main(): select() failed, "
1144 "returned to issue_queue\n", HOSTNO); 1144 "returned to issue_queue\n", HOSTNO);
1145 if (hostdata->connected) 1145 if (hostdata->connected)
1146 break; 1146 break;
@@ -1155,10 +1155,10 @@ static void NCR5380_main(struct work_struct *work)
1155#endif 1155#endif
1156 ) { 1156 ) {
1157 local_irq_restore(flags); 1157 local_irq_restore(flags);
1158 MAIN_PRINTK("scsi%d: main: performing information transfer\n", 1158 dprintk(NDEBUG_MAIN, "scsi%d: main: performing information transfer\n",
1159 HOSTNO); 1159 HOSTNO);
1160 NCR5380_information_transfer(instance); 1160 NCR5380_information_transfer(instance);
1161 MAIN_PRINTK("scsi%d: main: done set false\n", HOSTNO); 1161 dprintk(NDEBUG_MAIN, "scsi%d: main: done set false\n", HOSTNO);
1162 done = 0; 1162 done = 0;
1163 } 1163 }
1164 } while (!done); 1164 } while (!done);
@@ -1204,12 +1204,12 @@ static void NCR5380_dma_complete(struct Scsi_Host *instance)
1204 (BASR_PHASE_MATCH|BASR_ACK)) { 1204 (BASR_PHASE_MATCH|BASR_ACK)) {
1205 saved_data = NCR5380_read(INPUT_DATA_REG); 1205 saved_data = NCR5380_read(INPUT_DATA_REG);
1206 overrun = 1; 1206 overrun = 1;
1207 DMA_PRINTK("scsi%d: read overrun handled\n", HOSTNO); 1207 dprintk(NDEBUG_DMA, "scsi%d: read overrun handled\n", HOSTNO);
1208 } 1208 }
1209 } 1209 }
1210 } 1210 }
1211 1211
1212 DMA_PRINTK("scsi%d: real DMA transfer complete, basr 0x%X, sr 0x%X\n", 1212 dprintk(NDEBUG_DMA, "scsi%d: real DMA transfer complete, basr 0x%X, sr 0x%X\n",
1213 HOSTNO, NCR5380_read(BUS_AND_STATUS_REG), 1213 HOSTNO, NCR5380_read(BUS_AND_STATUS_REG),
1214 NCR5380_read(STATUS_REG)); 1214 NCR5380_read(STATUS_REG));
1215 1215
@@ -1229,13 +1229,13 @@ static void NCR5380_dma_complete(struct Scsi_Host *instance)
1229 if ((NCR5380_read(STATUS_REG) & PHASE_MASK) == p && (p & SR_IO)) { 1229 if ((NCR5380_read(STATUS_REG) & PHASE_MASK) == p && (p & SR_IO)) {
1230 cnt = toPIO = atari_read_overruns; 1230 cnt = toPIO = atari_read_overruns;
1231 if (overrun) { 1231 if (overrun) {
1232 DMA_PRINTK("Got an input overrun, using saved byte\n"); 1232 dprintk(NDEBUG_DMA, "Got an input overrun, using saved byte\n");
1233 *(*data)++ = saved_data; 1233 *(*data)++ = saved_data;
1234 (*count)--; 1234 (*count)--;
1235 cnt--; 1235 cnt--;
1236 toPIO--; 1236 toPIO--;
1237 } 1237 }
1238 DMA_PRINTK("Doing %d-byte PIO to 0x%08lx\n", cnt, (long)*data); 1238 dprintk(NDEBUG_DMA, "Doing %d-byte PIO to 0x%08lx\n", cnt, (long)*data);
1239 NCR5380_transfer_pio(instance, &p, &cnt, data); 1239 NCR5380_transfer_pio(instance, &p, &cnt, data);
1240 *count -= toPIO - cnt; 1240 *count -= toPIO - cnt;
1241 } 1241 }
@@ -1261,25 +1261,25 @@ static irqreturn_t NCR5380_intr(int irq, void *dev_id)
1261 int done = 1, handled = 0; 1261 int done = 1, handled = 0;
1262 unsigned char basr; 1262 unsigned char basr;
1263 1263
1264 INT_PRINTK("scsi%d: NCR5380 irq triggered\n", HOSTNO); 1264 dprintk(NDEBUG_INTR, "scsi%d: NCR5380 irq triggered\n", HOSTNO);
1265 1265
1266 /* Look for pending interrupts */ 1266 /* Look for pending interrupts */
1267 basr = NCR5380_read(BUS_AND_STATUS_REG); 1267 basr = NCR5380_read(BUS_AND_STATUS_REG);
1268 INT_PRINTK("scsi%d: BASR=%02x\n", HOSTNO, basr); 1268 dprintk(NDEBUG_INTR, "scsi%d: BASR=%02x\n", HOSTNO, basr);
1269 /* dispatch to appropriate routine if found and done=0 */ 1269 /* dispatch to appropriate routine if found and done=0 */
1270 if (basr & BASR_IRQ) { 1270 if (basr & BASR_IRQ) {
1271 NCR5380_dprint(NDEBUG_INTR, instance); 1271 NCR5380_dprint(NDEBUG_INTR, instance);
1272 if ((NCR5380_read(STATUS_REG) & (SR_SEL|SR_IO)) == (SR_SEL|SR_IO)) { 1272 if ((NCR5380_read(STATUS_REG) & (SR_SEL|SR_IO)) == (SR_SEL|SR_IO)) {
1273 done = 0; 1273 done = 0;
1274 ENABLE_IRQ(); 1274 ENABLE_IRQ();
1275 INT_PRINTK("scsi%d: SEL interrupt\n", HOSTNO); 1275 dprintk(NDEBUG_INTR, "scsi%d: SEL interrupt\n", HOSTNO);
1276 NCR5380_reselect(instance); 1276 NCR5380_reselect(instance);
1277 (void)NCR5380_read(RESET_PARITY_INTERRUPT_REG); 1277 (void)NCR5380_read(RESET_PARITY_INTERRUPT_REG);
1278 } else if (basr & BASR_PARITY_ERROR) { 1278 } else if (basr & BASR_PARITY_ERROR) {
1279 INT_PRINTK("scsi%d: PARITY interrupt\n", HOSTNO); 1279 dprintk(NDEBUG_INTR, "scsi%d: PARITY interrupt\n", HOSTNO);
1280 (void)NCR5380_read(RESET_PARITY_INTERRUPT_REG); 1280 (void)NCR5380_read(RESET_PARITY_INTERRUPT_REG);
1281 } else if ((NCR5380_read(STATUS_REG) & SR_RST) == SR_RST) { 1281 } else if ((NCR5380_read(STATUS_REG) & SR_RST) == SR_RST) {
1282 INT_PRINTK("scsi%d: RESET interrupt\n", HOSTNO); 1282 dprintk(NDEBUG_INTR, "scsi%d: RESET interrupt\n", HOSTNO);
1283 (void)NCR5380_read(RESET_PARITY_INTERRUPT_REG); 1283 (void)NCR5380_read(RESET_PARITY_INTERRUPT_REG);
1284 } else { 1284 } else {
1285 /* 1285 /*
@@ -1298,7 +1298,7 @@ static irqreturn_t NCR5380_intr(int irq, void *dev_id)
1298 ((basr & BASR_END_DMA_TRANSFER) || 1298 ((basr & BASR_END_DMA_TRANSFER) ||
1299 !(basr & BASR_PHASE_MATCH))) { 1299 !(basr & BASR_PHASE_MATCH))) {
1300 1300
1301 INT_PRINTK("scsi%d: PHASE MISM or EOP interrupt\n", HOSTNO); 1301 dprintk(NDEBUG_INTR, "scsi%d: PHASE MISM or EOP interrupt\n", HOSTNO);
1302 NCR5380_dma_complete( instance ); 1302 NCR5380_dma_complete( instance );
1303 done = 0; 1303 done = 0;
1304 ENABLE_IRQ(); 1304 ENABLE_IRQ();
@@ -1323,7 +1323,7 @@ static irqreturn_t NCR5380_intr(int irq, void *dev_id)
1323 } 1323 }
1324 1324
1325 if (!done) { 1325 if (!done) {
1326 INT_PRINTK("scsi%d: in int routine, calling main\n", HOSTNO); 1326 dprintk(NDEBUG_INTR, "scsi%d: in int routine, calling main\n", HOSTNO);
1327 /* Put a call to NCR5380_main() on the queue... */ 1327 /* Put a call to NCR5380_main() on the queue... */
1328 queue_main(); 1328 queue_main();
1329 } 1329 }
@@ -1397,7 +1397,7 @@ static int NCR5380_select(struct Scsi_Host *instance, Scsi_Cmnd *cmd, int tag)
1397 1397
1398 hostdata->restart_select = 0; 1398 hostdata->restart_select = 0;
1399 NCR5380_dprint(NDEBUG_ARBITRATION, instance); 1399 NCR5380_dprint(NDEBUG_ARBITRATION, instance);
1400 ARB_PRINTK("scsi%d: starting arbitration, id = %d\n", HOSTNO, 1400 dprintk(NDEBUG_ARBITRATION, "scsi%d: starting arbitration, id = %d\n", HOSTNO,
1401 instance->this_id); 1401 instance->this_id);
1402 1402
1403 /* 1403 /*
@@ -1442,7 +1442,7 @@ static int NCR5380_select(struct Scsi_Host *instance, Scsi_Cmnd *cmd, int tag)
1442 ; 1442 ;
1443#endif 1443#endif
1444 1444
1445 ARB_PRINTK("scsi%d: arbitration complete\n", HOSTNO); 1445 dprintk(NDEBUG_ARBITRATION, "scsi%d: arbitration complete\n", HOSTNO);
1446 1446
1447 if (hostdata->connected) { 1447 if (hostdata->connected) {
1448 NCR5380_write(MODE_REG, MR_BASE); 1448 NCR5380_write(MODE_REG, MR_BASE);
@@ -1463,7 +1463,7 @@ static int NCR5380_select(struct Scsi_Host *instance, Scsi_Cmnd *cmd, int tag)
1463 (NCR5380_read(INITIATOR_COMMAND_REG) & ICR_ARBITRATION_LOST) || 1463 (NCR5380_read(INITIATOR_COMMAND_REG) & ICR_ARBITRATION_LOST) ||
1464 hostdata->connected) { 1464 hostdata->connected) {
1465 NCR5380_write(MODE_REG, MR_BASE); 1465 NCR5380_write(MODE_REG, MR_BASE);
1466 ARB_PRINTK("scsi%d: lost arbitration, deasserting MR_ARBITRATE\n", 1466 dprintk(NDEBUG_ARBITRATION, "scsi%d: lost arbitration, deasserting MR_ARBITRATE\n",
1467 HOSTNO); 1467 HOSTNO);
1468 return -1; 1468 return -1;
1469 } 1469 }
@@ -1478,7 +1478,7 @@ static int NCR5380_select(struct Scsi_Host *instance, Scsi_Cmnd *cmd, int tag)
1478 hostdata->connected) { 1478 hostdata->connected) {
1479 NCR5380_write(MODE_REG, MR_BASE); 1479 NCR5380_write(MODE_REG, MR_BASE);
1480 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE); 1480 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE);
1481 ARB_PRINTK("scsi%d: lost arbitration, deasserting ICR_ASSERT_SEL\n", 1481 dprintk(NDEBUG_ARBITRATION, "scsi%d: lost arbitration, deasserting ICR_ASSERT_SEL\n",
1482 HOSTNO); 1482 HOSTNO);
1483 return -1; 1483 return -1;
1484 } 1484 }
@@ -1501,7 +1501,7 @@ static int NCR5380_select(struct Scsi_Host *instance, Scsi_Cmnd *cmd, int tag)
1501 return -1; 1501 return -1;
1502 } 1502 }
1503 1503
1504 ARB_PRINTK("scsi%d: won arbitration\n", HOSTNO); 1504 dprintk(NDEBUG_ARBITRATION, "scsi%d: won arbitration\n", HOSTNO);
1505 1505
1506 /* 1506 /*
1507 * Now that we have won arbitration, start Selection process, asserting 1507 * Now that we have won arbitration, start Selection process, asserting
@@ -1561,7 +1561,7 @@ static int NCR5380_select(struct Scsi_Host *instance, Scsi_Cmnd *cmd, int tag)
1561 1561
1562 udelay(1); 1562 udelay(1);
1563 1563
1564 SEL_PRINTK("scsi%d: selecting target %d\n", HOSTNO, cmd->device->id); 1564 dprintk(NDEBUG_SELECTION, "scsi%d: selecting target %d\n", HOSTNO, cmd->device->id);
1565 1565
1566 /* 1566 /*
1567 * The SCSI specification calls for a 250 ms timeout for the actual 1567 * The SCSI specification calls for a 250 ms timeout for the actual
@@ -1630,7 +1630,7 @@ static int NCR5380_select(struct Scsi_Host *instance, Scsi_Cmnd *cmd, int tag)
1630#endif 1630#endif
1631 cmd->scsi_done(cmd); 1631 cmd->scsi_done(cmd);
1632 NCR5380_write(SELECT_ENABLE_REG, hostdata->id_mask); 1632 NCR5380_write(SELECT_ENABLE_REG, hostdata->id_mask);
1633 SEL_PRINTK("scsi%d: target did not respond within 250ms\n", HOSTNO); 1633 dprintk(NDEBUG_SELECTION, "scsi%d: target did not respond within 250ms\n", HOSTNO);
1634 NCR5380_write(SELECT_ENABLE_REG, hostdata->id_mask); 1634 NCR5380_write(SELECT_ENABLE_REG, hostdata->id_mask);
1635 return 0; 1635 return 0;
1636 } 1636 }
@@ -1656,7 +1656,7 @@ static int NCR5380_select(struct Scsi_Host *instance, Scsi_Cmnd *cmd, int tag)
1656 while (!(NCR5380_read(STATUS_REG) & SR_REQ)) 1656 while (!(NCR5380_read(STATUS_REG) & SR_REQ))
1657 ; 1657 ;
1658 1658
1659 SEL_PRINTK("scsi%d: target %d selected, going into MESSAGE OUT phase.\n", 1659 dprintk(NDEBUG_SELECTION, "scsi%d: target %d selected, going into MESSAGE OUT phase.\n",
1660 HOSTNO, cmd->device->id); 1660 HOSTNO, cmd->device->id);
1661 tmp[0] = IDENTIFY(1, cmd->device->lun); 1661 tmp[0] = IDENTIFY(1, cmd->device->lun);
1662 1662
@@ -1676,7 +1676,7 @@ static int NCR5380_select(struct Scsi_Host *instance, Scsi_Cmnd *cmd, int tag)
1676 data = tmp; 1676 data = tmp;
1677 phase = PHASE_MSGOUT; 1677 phase = PHASE_MSGOUT;
1678 NCR5380_transfer_pio(instance, &phase, &len, &data); 1678 NCR5380_transfer_pio(instance, &phase, &len, &data);
1679 SEL_PRINTK("scsi%d: nexus established.\n", HOSTNO); 1679 dprintk(NDEBUG_SELECTION, "scsi%d: nexus established.\n", HOSTNO);
1680 /* XXX need to handle errors here */ 1680 /* XXX need to handle errors here */
1681 hostdata->connected = cmd; 1681 hostdata->connected = cmd;
1682#ifndef SUPPORT_TAGS 1682#ifndef SUPPORT_TAGS
@@ -1737,11 +1737,11 @@ static int NCR5380_transfer_pio(struct Scsi_Host *instance,
1737 while (!((tmp = NCR5380_read(STATUS_REG)) & SR_REQ)) 1737 while (!((tmp = NCR5380_read(STATUS_REG)) & SR_REQ))
1738 ; 1738 ;
1739 1739
1740 HSH_PRINTK("scsi%d: REQ detected\n", HOSTNO); 1740 dprintk(NDEBUG_HANDSHAKE, "scsi%d: REQ detected\n", HOSTNO);
1741 1741
1742 /* Check for phase mismatch */ 1742 /* Check for phase mismatch */
1743 if ((tmp & PHASE_MASK) != p) { 1743 if ((tmp & PHASE_MASK) != p) {
1744 PIO_PRINTK("scsi%d: phase mismatch\n", HOSTNO); 1744 dprintk(NDEBUG_PIO, "scsi%d: phase mismatch\n", HOSTNO);
1745 NCR5380_dprint_phase(NDEBUG_PIO, instance); 1745 NCR5380_dprint_phase(NDEBUG_PIO, instance);
1746 break; 1746 break;
1747 } 1747 }
@@ -1782,7 +1782,7 @@ static int NCR5380_transfer_pio(struct Scsi_Host *instance,
1782 while (NCR5380_read(STATUS_REG) & SR_REQ) 1782 while (NCR5380_read(STATUS_REG) & SR_REQ)
1783 ; 1783 ;
1784 1784
1785 HSH_PRINTK("scsi%d: req false, handshake complete\n", HOSTNO); 1785 dprintk(NDEBUG_HANDSHAKE, "scsi%d: req false, handshake complete\n", HOSTNO);
1786 1786
1787 /* 1787 /*
1788 * We have several special cases to consider during REQ/ACK handshaking : 1788 * We have several special cases to consider during REQ/ACK handshaking :
@@ -1803,7 +1803,7 @@ static int NCR5380_transfer_pio(struct Scsi_Host *instance,
1803 } 1803 }
1804 } while (--c); 1804 } while (--c);
1805 1805
1806 PIO_PRINTK("scsi%d: residual %d\n", HOSTNO, c); 1806 dprintk(NDEBUG_PIO, "scsi%d: residual %d\n", HOSTNO, c);
1807 1807
1808 *count = c; 1808 *count = c;
1809 *data = d; 1809 *data = d;
@@ -1917,7 +1917,7 @@ static int NCR5380_transfer_dma(struct Scsi_Host *instance,
1917 if (atari_read_overruns && (p & SR_IO)) 1917 if (atari_read_overruns && (p & SR_IO))
1918 c -= atari_read_overruns; 1918 c -= atari_read_overruns;
1919 1919
1920 DMA_PRINTK("scsi%d: initializing DMA for %s, %d bytes %s %p\n", 1920 dprintk(NDEBUG_DMA, "scsi%d: initializing DMA for %s, %d bytes %s %p\n",
1921 HOSTNO, (p & SR_IO) ? "reading" : "writing", 1921 HOSTNO, (p & SR_IO) ? "reading" : "writing",
1922 c, (p & SR_IO) ? "to" : "from", d); 1922 c, (p & SR_IO) ? "to" : "from", d);
1923 1923
@@ -2039,7 +2039,7 @@ static void NCR5380_information_transfer(struct Scsi_Host *instance)
2039 * they are at contiguous physical addresses. 2039 * they are at contiguous physical addresses.
2040 */ 2040 */
2041 merge_contiguous_buffers(cmd); 2041 merge_contiguous_buffers(cmd);
2042 INF_PRINTK("scsi%d: %d bytes and %d buffers left\n", 2042 dprintk(NDEBUG_INFORMATION, "scsi%d: %d bytes and %d buffers left\n",
2043 HOSTNO, cmd->SCp.this_residual, 2043 HOSTNO, cmd->SCp.this_residual,
2044 cmd->SCp.buffers_residual); 2044 cmd->SCp.buffers_residual);
2045 } 2045 }
@@ -2123,7 +2123,7 @@ static void NCR5380_information_transfer(struct Scsi_Host *instance)
2123 /* Accept message by clearing ACK */ 2123 /* Accept message by clearing ACK */
2124 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE); 2124 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE);
2125 2125
2126 LNK_PRINTK("scsi%d: target %d lun %d linked command " 2126 dprintk(NDEBUG_LINKED, "scsi%d: target %d lun %d linked command "
2127 "complete.\n", HOSTNO, cmd->device->id, cmd->device->lun); 2127 "complete.\n", HOSTNO, cmd->device->id, cmd->device->lun);
2128 2128
2129 /* Enable reselect interrupts */ 2129 /* Enable reselect interrupts */
@@ -2148,7 +2148,7 @@ static void NCR5380_information_transfer(struct Scsi_Host *instance)
2148 * and don't free it! */ 2148 * and don't free it! */
2149 cmd->next_link->tag = cmd->tag; 2149 cmd->next_link->tag = cmd->tag;
2150 cmd->result = cmd->SCp.Status | (cmd->SCp.Message << 8); 2150 cmd->result = cmd->SCp.Status | (cmd->SCp.Message << 8);
2151 LNK_PRINTK("scsi%d: target %d lun %d linked request " 2151 dprintk(NDEBUG_LINKED, "scsi%d: target %d lun %d linked request "
2152 "done, calling scsi_done().\n", 2152 "done, calling scsi_done().\n",
2153 HOSTNO, cmd->device->id, cmd->device->lun); 2153 HOSTNO, cmd->device->id, cmd->device->lun);
2154#ifdef NCR5380_STATS 2154#ifdef NCR5380_STATS
@@ -2165,7 +2165,7 @@ static void NCR5380_information_transfer(struct Scsi_Host *instance)
2165 /* ++guenther: possible race with Falcon locking */ 2165 /* ++guenther: possible race with Falcon locking */
2166 falcon_dont_release++; 2166 falcon_dont_release++;
2167 hostdata->connected = NULL; 2167 hostdata->connected = NULL;
2168 QU_PRINTK("scsi%d: command for target %d, lun %d " 2168 dprintk(NDEBUG_QUEUES, "scsi%d: command for target %d, lun %d "
2169 "completed\n", HOSTNO, cmd->device->id, cmd->device->lun); 2169 "completed\n", HOSTNO, cmd->device->id, cmd->device->lun);
2170#ifdef SUPPORT_TAGS 2170#ifdef SUPPORT_TAGS
2171 cmd_free_tag(cmd); 2171 cmd_free_tag(cmd);
@@ -2179,7 +2179,7 @@ static void NCR5380_information_transfer(struct Scsi_Host *instance)
2179 /* ++Andreas: the mid level code knows about 2179 /* ++Andreas: the mid level code knows about
2180 QUEUE_FULL now. */ 2180 QUEUE_FULL now. */
2181 TAG_ALLOC *ta = &TagAlloc[cmd->device->id][cmd->device->lun]; 2181 TAG_ALLOC *ta = &TagAlloc[cmd->device->id][cmd->device->lun];
2182 TAG_PRINTK("scsi%d: target %d lun %d returned " 2182 dprintk(NDEBUG_TAGS, "scsi%d: target %d lun %d returned "
2183 "QUEUE_FULL after %d commands\n", 2183 "QUEUE_FULL after %d commands\n",
2184 HOSTNO, cmd->device->id, cmd->device->lun, 2184 HOSTNO, cmd->device->id, cmd->device->lun,
2185 ta->nr_allocated); 2185 ta->nr_allocated);
@@ -2224,14 +2224,14 @@ static void NCR5380_information_transfer(struct Scsi_Host *instance)
2224 (status_byte(cmd->SCp.Status) == CHECK_CONDITION)) { 2224 (status_byte(cmd->SCp.Status) == CHECK_CONDITION)) {
2225 scsi_eh_prep_cmnd(cmd, &hostdata->ses, NULL, 0, ~0); 2225 scsi_eh_prep_cmnd(cmd, &hostdata->ses, NULL, 0, ~0);
2226 2226
2227 ASEN_PRINTK("scsi%d: performing request sense\n", HOSTNO); 2227 dprintk(NDEBUG_AUTOSENSE, "scsi%d: performing request sense\n", HOSTNO);
2228 2228
2229 local_irq_save(flags); 2229 local_irq_save(flags);
2230 LIST(cmd,hostdata->issue_queue); 2230 LIST(cmd,hostdata->issue_queue);
2231 SET_NEXT(cmd, hostdata->issue_queue); 2231 SET_NEXT(cmd, hostdata->issue_queue);
2232 hostdata->issue_queue = (Scsi_Cmnd *) cmd; 2232 hostdata->issue_queue = (Scsi_Cmnd *) cmd;
2233 local_irq_restore(flags); 2233 local_irq_restore(flags);
2234 QU_PRINTK("scsi%d: REQUEST SENSE added to head of " 2234 dprintk(NDEBUG_QUEUES, "scsi%d: REQUEST SENSE added to head of "
2235 "issue queue\n", H_NO(cmd)); 2235 "issue queue\n", H_NO(cmd));
2236 } else 2236 } else
2237#endif /* def AUTOSENSE */ 2237#endif /* def AUTOSENSE */
@@ -2277,7 +2277,7 @@ static void NCR5380_information_transfer(struct Scsi_Host *instance)
2277 cmd->device->tagged_supported = 0; 2277 cmd->device->tagged_supported = 0;
2278 hostdata->busy[cmd->device->id] |= (1 << cmd->device->lun); 2278 hostdata->busy[cmd->device->id] |= (1 << cmd->device->lun);
2279 cmd->tag = TAG_NONE; 2279 cmd->tag = TAG_NONE;
2280 TAG_PRINTK("scsi%d: target %d lun %d rejected " 2280 dprintk(NDEBUG_TAGS, "scsi%d: target %d lun %d rejected "
2281 "QUEUE_TAG message; tagged queuing " 2281 "QUEUE_TAG message; tagged queuing "
2282 "disabled\n", 2282 "disabled\n",
2283 HOSTNO, cmd->device->id, cmd->device->lun); 2283 HOSTNO, cmd->device->id, cmd->device->lun);
@@ -2294,7 +2294,7 @@ static void NCR5380_information_transfer(struct Scsi_Host *instance)
2294 hostdata->connected = NULL; 2294 hostdata->connected = NULL;
2295 hostdata->disconnected_queue = cmd; 2295 hostdata->disconnected_queue = cmd;
2296 local_irq_restore(flags); 2296 local_irq_restore(flags);
2297 QU_PRINTK("scsi%d: command for target %d lun %d was " 2297 dprintk(NDEBUG_QUEUES, "scsi%d: command for target %d lun %d was "
2298 "moved from connected to the " 2298 "moved from connected to the "
2299 "disconnected_queue\n", HOSTNO, 2299 "disconnected_queue\n", HOSTNO,
2300 cmd->device->id, cmd->device->lun); 2300 cmd->device->id, cmd->device->lun);
@@ -2344,13 +2344,13 @@ static void NCR5380_information_transfer(struct Scsi_Host *instance)
2344 /* Accept first byte by clearing ACK */ 2344 /* Accept first byte by clearing ACK */
2345 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE); 2345 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE);
2346 2346
2347 EXT_PRINTK("scsi%d: receiving extended message\n", HOSTNO); 2347 dprintk(NDEBUG_EXTENDED, "scsi%d: receiving extended message\n", HOSTNO);
2348 2348
2349 len = 2; 2349 len = 2;
2350 data = extended_msg + 1; 2350 data = extended_msg + 1;
2351 phase = PHASE_MSGIN; 2351 phase = PHASE_MSGIN;
2352 NCR5380_transfer_pio(instance, &phase, &len, &data); 2352 NCR5380_transfer_pio(instance, &phase, &len, &data);
2353 EXT_PRINTK("scsi%d: length=%d, code=0x%02x\n", HOSTNO, 2353 dprintk(NDEBUG_EXTENDED, "scsi%d: length=%d, code=0x%02x\n", HOSTNO,
2354 (int)extended_msg[1], (int)extended_msg[2]); 2354 (int)extended_msg[1], (int)extended_msg[2]);
2355 2355
2356 if (!len && extended_msg[1] <= 2356 if (!len && extended_msg[1] <=
@@ -2362,7 +2362,7 @@ static void NCR5380_information_transfer(struct Scsi_Host *instance)
2362 phase = PHASE_MSGIN; 2362 phase = PHASE_MSGIN;
2363 2363
2364 NCR5380_transfer_pio(instance, &phase, &len, &data); 2364 NCR5380_transfer_pio(instance, &phase, &len, &data);
2365 EXT_PRINTK("scsi%d: message received, residual %d\n", 2365 dprintk(NDEBUG_EXTENDED, "scsi%d: message received, residual %d\n",
2366 HOSTNO, len); 2366 HOSTNO, len);
2367 2367
2368 switch (extended_msg[2]) { 2368 switch (extended_msg[2]) {
@@ -2493,7 +2493,7 @@ static void NCR5380_reselect(struct Scsi_Host *instance)
2493 2493
2494 target_mask = NCR5380_read(CURRENT_SCSI_DATA_REG) & ~(hostdata->id_mask); 2494 target_mask = NCR5380_read(CURRENT_SCSI_DATA_REG) & ~(hostdata->id_mask);
2495 2495
2496 RSL_PRINTK("scsi%d: reselect\n", HOSTNO); 2496 dprintk(NDEBUG_RESELECTION, "scsi%d: reselect\n", HOSTNO);
2497 2497
2498 /* 2498 /*
2499 * At this point, we have detected that our SCSI ID is on the bus, 2499 * At this point, we have detected that our SCSI ID is on the bus,
@@ -2544,7 +2544,7 @@ static void NCR5380_reselect(struct Scsi_Host *instance)
2544 if (!NCR5380_transfer_pio(instance, &phase, &len, &data) && 2544 if (!NCR5380_transfer_pio(instance, &phase, &len, &data) &&
2545 msg[1] == SIMPLE_QUEUE_TAG) 2545 msg[1] == SIMPLE_QUEUE_TAG)
2546 tag = msg[2]; 2546 tag = msg[2];
2547 TAG_PRINTK("scsi%d: target mask %02x, lun %d sent tag %d at " 2547 dprintk(NDEBUG_TAGS, "scsi%d: target mask %02x, lun %d sent tag %d at "
2548 "reselection\n", HOSTNO, target_mask, lun, tag); 2548 "reselection\n", HOSTNO, target_mask, lun, tag);
2549 } 2549 }
2550#endif 2550#endif
@@ -2598,7 +2598,7 @@ static void NCR5380_reselect(struct Scsi_Host *instance)
2598 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE); 2598 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE);
2599 2599
2600 hostdata->connected = tmp; 2600 hostdata->connected = tmp;
2601 RSL_PRINTK("scsi%d: nexus established, target = %d, lun = %d, tag = %d\n", 2601 dprintk(NDEBUG_RESELECTION, "scsi%d: nexus established, target = %d, lun = %d, tag = %d\n",
2602 HOSTNO, tmp->device->id, tmp->device->lun, tmp->tag); 2602 HOSTNO, tmp->device->id, tmp->device->lun, tmp->tag);
2603 falcon_dont_release--; 2603 falcon_dont_release--;
2604} 2604}
@@ -2640,7 +2640,7 @@ int NCR5380_abort(Scsi_Cmnd *cmd)
2640 printk(KERN_ERR "scsi%d: !!BINGO!! Falcon has no lock in NCR5380_abort\n", 2640 printk(KERN_ERR "scsi%d: !!BINGO!! Falcon has no lock in NCR5380_abort\n",
2641 HOSTNO); 2641 HOSTNO);
2642 2642
2643 ABRT_PRINTK("scsi%d: abort called basr 0x%02x, sr 0x%02x\n", HOSTNO, 2643 dprintk(NDEBUG_ABORT, "scsi%d: abort called basr 0x%02x, sr 0x%02x\n", HOSTNO,
2644 NCR5380_read(BUS_AND_STATUS_REG), 2644 NCR5380_read(BUS_AND_STATUS_REG),
2645 NCR5380_read(STATUS_REG)); 2645 NCR5380_read(STATUS_REG));
2646 2646
@@ -2653,7 +2653,7 @@ int NCR5380_abort(Scsi_Cmnd *cmd)
2653 2653
2654 if (hostdata->connected == cmd) { 2654 if (hostdata->connected == cmd) {
2655 2655
2656 ABRT_PRINTK("scsi%d: aborting connected command\n", HOSTNO); 2656 dprintk(NDEBUG_ABORT, "scsi%d: aborting connected command\n", HOSTNO);
2657 /* 2657 /*
2658 * We should perform BSY checking, and make sure we haven't slipped 2658 * We should perform BSY checking, and make sure we haven't slipped
2659 * into BUS FREE. 2659 * into BUS FREE.
@@ -2705,7 +2705,7 @@ int NCR5380_abort(Scsi_Cmnd *cmd)
2705 SET_NEXT(tmp, NULL); 2705 SET_NEXT(tmp, NULL);
2706 tmp->result = DID_ABORT << 16; 2706 tmp->result = DID_ABORT << 16;
2707 local_irq_restore(flags); 2707 local_irq_restore(flags);
2708 ABRT_PRINTK("scsi%d: abort removed command from issue queue.\n", 2708 dprintk(NDEBUG_ABORT, "scsi%d: abort removed command from issue queue.\n",
2709 HOSTNO); 2709 HOSTNO);
2710 /* Tagged queuing note: no tag to free here, hasn't been assigned 2710 /* Tagged queuing note: no tag to free here, hasn't been assigned
2711 * yet... */ 2711 * yet... */
@@ -2728,7 +2728,7 @@ int NCR5380_abort(Scsi_Cmnd *cmd)
2728 2728
2729 if (hostdata->connected) { 2729 if (hostdata->connected) {
2730 local_irq_restore(flags); 2730 local_irq_restore(flags);
2731 ABRT_PRINTK("scsi%d: abort failed, command connected.\n", HOSTNO); 2731 dprintk(NDEBUG_ABORT, "scsi%d: abort failed, command connected.\n", HOSTNO);
2732 return FAILED; 2732 return FAILED;
2733 } 2733 }
2734 2734
@@ -2761,12 +2761,12 @@ int NCR5380_abort(Scsi_Cmnd *cmd)
2761 tmp = NEXT(tmp)) { 2761 tmp = NEXT(tmp)) {
2762 if (cmd == tmp) { 2762 if (cmd == tmp) {
2763 local_irq_restore(flags); 2763 local_irq_restore(flags);
2764 ABRT_PRINTK("scsi%d: aborting disconnected command.\n", HOSTNO); 2764 dprintk(NDEBUG_ABORT, "scsi%d: aborting disconnected command.\n", HOSTNO);
2765 2765
2766 if (NCR5380_select(instance, cmd, (int)cmd->tag)) 2766 if (NCR5380_select(instance, cmd, (int)cmd->tag))
2767 return FAILED; 2767 return FAILED;
2768 2768
2769 ABRT_PRINTK("scsi%d: nexus reestablished.\n", HOSTNO); 2769 dprintk(NDEBUG_ABORT, "scsi%d: nexus reestablished.\n", HOSTNO);
2770 2770
2771 do_abort(instance); 2771 do_abort(instance);
2772 2772
@@ -2897,7 +2897,7 @@ static int NCR5380_bus_reset(Scsi_Cmnd *cmd)
2897 */ 2897 */
2898 2898
2899 if ((cmd = connected)) { 2899 if ((cmd = connected)) {
2900 ABRT_PRINTK("scsi%d: reset aborted a connected command\n", H_NO(cmd)); 2900 dprintk(NDEBUG_ABORT, "scsi%d: reset aborted a connected command\n", H_NO(cmd));
2901 cmd->result = (cmd->result & 0xffff) | (DID_RESET << 16); 2901 cmd->result = (cmd->result & 0xffff) | (DID_RESET << 16);
2902 cmd->scsi_done(cmd); 2902 cmd->scsi_done(cmd);
2903 } 2903 }
@@ -2909,7 +2909,7 @@ static int NCR5380_bus_reset(Scsi_Cmnd *cmd)
2909 cmd->scsi_done(cmd); 2909 cmd->scsi_done(cmd);
2910 } 2910 }
2911 if (i > 0) 2911 if (i > 0)
2912 ABRT_PRINTK("scsi: reset aborted %d disconnected command(s)\n", i); 2912 dprintk(NDEBUG_ABORT, "scsi: reset aborted %d disconnected command(s)\n", i);
2913 2913
2914 /* The Falcon lock should be released after a reset... 2914 /* The Falcon lock should be released after a reset...
2915 */ 2915 */
@@ -2949,11 +2949,11 @@ static int NCR5380_bus_reset(Scsi_Cmnd *cmd)
2949 */ 2949 */
2950 2950
2951 if (hostdata->issue_queue) 2951 if (hostdata->issue_queue)
2952 ABRT_PRINTK("scsi%d: reset aborted issued command(s)\n", H_NO(cmd)); 2952 dprintk(NDEBUG_ABORT, "scsi%d: reset aborted issued command(s)\n", H_NO(cmd));
2953 if (hostdata->connected) 2953 if (hostdata->connected)
2954 ABRT_PRINTK("scsi%d: reset aborted a connected command\n", H_NO(cmd)); 2954 dprintk(NDEBUG_ABORT, "scsi%d: reset aborted a connected command\n", H_NO(cmd));
2955 if (hostdata->disconnected_queue) 2955 if (hostdata->disconnected_queue)
2956 ABRT_PRINTK("scsi%d: reset aborted disconnected command(s)\n", H_NO(cmd)); 2956 dprintk(NDEBUG_ABORT, "scsi%d: reset aborted disconnected command(s)\n", H_NO(cmd));
2957 2957
2958 local_irq_save(flags); 2958 local_irq_save(flags);
2959 hostdata->issue_queue = NULL; 2959 hostdata->issue_queue = NULL;
diff --git a/drivers/scsi/atari_scsi.c b/drivers/scsi/atari_scsi.c
index 4ae0c1a29598..c66b4caee9c6 100644
--- a/drivers/scsi/atari_scsi.c
+++ b/drivers/scsi/atari_scsi.c
@@ -314,7 +314,7 @@ static irqreturn_t scsi_tt_intr(int irq, void *dummy)
314 314
315 dma_stat = tt_scsi_dma.dma_ctrl; 315 dma_stat = tt_scsi_dma.dma_ctrl;
316 316
317 INT_PRINTK("scsi%d: NCR5380 interrupt, DMA status = %02x\n", 317 dprintk(NDEBUG_INTR, "scsi%d: NCR5380 interrupt, DMA status = %02x\n",
318 atari_scsi_host->host_no, dma_stat & 0xff); 318 atari_scsi_host->host_no, dma_stat & 0xff);
319 319
320 /* Look if it was the DMA that has interrupted: First possibility 320 /* Look if it was the DMA that has interrupted: First possibility
@@ -340,7 +340,7 @@ static irqreturn_t scsi_tt_intr(int irq, void *dummy)
340 if ((dma_stat & 0x02) && !(dma_stat & 0x40)) { 340 if ((dma_stat & 0x02) && !(dma_stat & 0x40)) {
341 atari_dma_residual = HOSTDATA_DMALEN - (SCSI_DMA_READ_P(dma_addr) - atari_dma_startaddr); 341 atari_dma_residual = HOSTDATA_DMALEN - (SCSI_DMA_READ_P(dma_addr) - atari_dma_startaddr);
342 342
343 DMA_PRINTK("SCSI DMA: There are %ld residual bytes.\n", 343 dprintk(NDEBUG_DMA, "SCSI DMA: There are %ld residual bytes.\n",
344 atari_dma_residual); 344 atari_dma_residual);
345 345
346 if ((signed int)atari_dma_residual < 0) 346 if ((signed int)atari_dma_residual < 0)
@@ -371,7 +371,7 @@ static irqreturn_t scsi_tt_intr(int irq, void *dummy)
371 * other command. These shouldn't disconnect anyway. 371 * other command. These shouldn't disconnect anyway.
372 */ 372 */
373 if (atari_dma_residual & 0x1ff) { 373 if (atari_dma_residual & 0x1ff) {
374 DMA_PRINTK("SCSI DMA: DMA bug corrected, " 374 dprintk(NDEBUG_DMA, "SCSI DMA: DMA bug corrected, "
375 "difference %ld bytes\n", 375 "difference %ld bytes\n",
376 512 - (atari_dma_residual & 0x1ff)); 376 512 - (atari_dma_residual & 0x1ff));
377 atari_dma_residual = (atari_dma_residual + 511) & ~0x1ff; 377 atari_dma_residual = (atari_dma_residual + 511) & ~0x1ff;
@@ -438,7 +438,7 @@ static irqreturn_t scsi_falcon_intr(int irq, void *dummy)
438 "ST-DMA fifo\n", transferred & 15); 438 "ST-DMA fifo\n", transferred & 15);
439 439
440 atari_dma_residual = HOSTDATA_DMALEN - transferred; 440 atari_dma_residual = HOSTDATA_DMALEN - transferred;
441 DMA_PRINTK("SCSI DMA: There are %ld residual bytes.\n", 441 dprintk(NDEBUG_DMA, "SCSI DMA: There are %ld residual bytes.\n",
442 atari_dma_residual); 442 atari_dma_residual);
443 } else 443 } else
444 atari_dma_residual = 0; 444 atari_dma_residual = 0;
@@ -474,11 +474,11 @@ static void atari_scsi_fetch_restbytes(void)
474 /* there are 'nr' bytes left for the last long address 474 /* there are 'nr' bytes left for the last long address
475 before the DMA pointer */ 475 before the DMA pointer */
476 phys_dst ^= nr; 476 phys_dst ^= nr;
477 DMA_PRINTK("SCSI DMA: there are %d rest bytes for phys addr 0x%08lx", 477 dprintk(NDEBUG_DMA, "SCSI DMA: there are %d rest bytes for phys addr 0x%08lx",
478 nr, phys_dst); 478 nr, phys_dst);
479 /* The content of the DMA pointer is a physical address! */ 479 /* The content of the DMA pointer is a physical address! */
480 dst = phys_to_virt(phys_dst); 480 dst = phys_to_virt(phys_dst);
481 DMA_PRINTK(" = virt addr %p\n", dst); 481 dprintk(NDEBUG_DMA, " = virt addr %p\n", dst);
482 for (src = (char *)&tt_scsi_dma.dma_restdata; nr != 0; --nr) 482 for (src = (char *)&tt_scsi_dma.dma_restdata; nr != 0; --nr)
483 *dst++ = *src++; 483 *dst++ = *src++;
484 } 484 }
@@ -883,7 +883,7 @@ static unsigned long atari_scsi_dma_setup(struct Scsi_Host *instance,
883{ 883{
884 unsigned long addr = virt_to_phys(data); 884 unsigned long addr = virt_to_phys(data);
885 885
886 DMA_PRINTK("scsi%d: setting up dma, data = %p, phys = %lx, count = %ld, " 886 dprintk(NDEBUG_DMA, "scsi%d: setting up dma, data = %p, phys = %lx, count = %ld, "
887 "dir = %d\n", instance->host_no, data, addr, count, dir); 887 "dir = %d\n", instance->host_no, data, addr, count, dir);
888 888
889 if (!IS_A_TT() && !STRAM_ADDR(addr)) { 889 if (!IS_A_TT() && !STRAM_ADDR(addr)) {
@@ -1063,7 +1063,7 @@ static unsigned long atari_dma_xfer_len(unsigned long wanted_len,
1063 possible_len = limit; 1063 possible_len = limit;
1064 1064
1065 if (possible_len != wanted_len) 1065 if (possible_len != wanted_len)
1066 DMA_PRINTK("Sorry, must cut DMA transfer size to %ld bytes " 1066 dprintk(NDEBUG_DMA, "Sorry, must cut DMA transfer size to %ld bytes "
1067 "instead of %ld\n", possible_len, wanted_len); 1067 "instead of %ld\n", possible_len, wanted_len);
1068 1068
1069 return possible_len; 1069 return possible_len;
diff --git a/drivers/scsi/sun3_NCR5380.c b/drivers/scsi/sun3_NCR5380.c
index 9d706e479921..447c8f0f8cf1 100644
--- a/drivers/scsi/sun3_NCR5380.c
+++ b/drivers/scsi/sun3_NCR5380.c
@@ -364,7 +364,7 @@ static int is_lun_busy(struct scsi_cmnd *cmd, int should_be_tagged)
364 return( 0 ); 364 return( 0 );
365 if (TagAlloc[cmd->device->id][cmd->device->lun].nr_allocated >= 365 if (TagAlloc[cmd->device->id][cmd->device->lun].nr_allocated >=
366 TagAlloc[cmd->device->id][cmd->device->lun].queue_size ) { 366 TagAlloc[cmd->device->id][cmd->device->lun].queue_size ) {
367 TAG_PRINTK( "scsi%d: target %d lun %d: no free tags\n", 367 dprintk(NDEBUG_TAGS, "scsi%d: target %d lun %d: no free tags\n",
368 H_NO(cmd), cmd->device->id, cmd->device->lun ); 368 H_NO(cmd), cmd->device->id, cmd->device->lun );
369 return( 1 ); 369 return( 1 );
370 } 370 }
@@ -388,7 +388,7 @@ static void cmd_get_tag(struct scsi_cmnd *cmd, int should_be_tagged)
388 !setup_use_tagged_queuing || !cmd->device->tagged_supported) { 388 !setup_use_tagged_queuing || !cmd->device->tagged_supported) {
389 cmd->tag = TAG_NONE; 389 cmd->tag = TAG_NONE;
390 hostdata->busy[cmd->device->id] |= (1 << cmd->device->lun); 390 hostdata->busy[cmd->device->id] |= (1 << cmd->device->lun);
391 TAG_PRINTK( "scsi%d: target %d lun %d now allocated by untagged " 391 dprintk(NDEBUG_TAGS, "scsi%d: target %d lun %d now allocated by untagged "
392 "command\n", H_NO(cmd), cmd->device->id, cmd->device->lun ); 392 "command\n", H_NO(cmd), cmd->device->id, cmd->device->lun );
393 } 393 }
394 else { 394 else {
@@ -397,7 +397,7 @@ static void cmd_get_tag(struct scsi_cmnd *cmd, int should_be_tagged)
397 cmd->tag = find_first_zero_bit( &ta->allocated, MAX_TAGS ); 397 cmd->tag = find_first_zero_bit( &ta->allocated, MAX_TAGS );
398 set_bit( cmd->tag, &ta->allocated ); 398 set_bit( cmd->tag, &ta->allocated );
399 ta->nr_allocated++; 399 ta->nr_allocated++;
400 TAG_PRINTK( "scsi%d: using tag %d for target %d lun %d " 400 dprintk(NDEBUG_TAGS, "scsi%d: using tag %d for target %d lun %d "
401 "(now %d tags in use)\n", 401 "(now %d tags in use)\n",
402 H_NO(cmd), cmd->tag, cmd->device->id, cmd->device->lun, 402 H_NO(cmd), cmd->tag, cmd->device->id, cmd->device->lun,
403 ta->nr_allocated ); 403 ta->nr_allocated );
@@ -415,7 +415,7 @@ static void cmd_free_tag(struct scsi_cmnd *cmd)
415 415
416 if (cmd->tag == TAG_NONE) { 416 if (cmd->tag == TAG_NONE) {
417 hostdata->busy[cmd->device->id] &= ~(1 << cmd->device->lun); 417 hostdata->busy[cmd->device->id] &= ~(1 << cmd->device->lun);
418 TAG_PRINTK( "scsi%d: target %d lun %d untagged cmd finished\n", 418 dprintk(NDEBUG_TAGS, "scsi%d: target %d lun %d untagged cmd finished\n",
419 H_NO(cmd), cmd->device->id, cmd->device->lun ); 419 H_NO(cmd), cmd->device->id, cmd->device->lun );
420 } 420 }
421 else if (cmd->tag >= MAX_TAGS) { 421 else if (cmd->tag >= MAX_TAGS) {
@@ -426,7 +426,7 @@ static void cmd_free_tag(struct scsi_cmnd *cmd)
426 TAG_ALLOC *ta = &TagAlloc[cmd->device->id][cmd->device->lun]; 426 TAG_ALLOC *ta = &TagAlloc[cmd->device->id][cmd->device->lun];
427 clear_bit( cmd->tag, &ta->allocated ); 427 clear_bit( cmd->tag, &ta->allocated );
428 ta->nr_allocated--; 428 ta->nr_allocated--;
429 TAG_PRINTK( "scsi%d: freed tag %d for target %d lun %d\n", 429 dprintk(NDEBUG_TAGS, "scsi%d: freed tag %d for target %d lun %d\n",
430 H_NO(cmd), cmd->tag, cmd->device->id, cmd->device->lun ); 430 H_NO(cmd), cmd->tag, cmd->device->id, cmd->device->lun );
431 } 431 }
432} 432}
@@ -618,7 +618,7 @@ static inline void NCR5380_all_init (void)
618{ 618{
619 static int done = 0; 619 static int done = 0;
620 if (!done) { 620 if (!done) {
621 INI_PRINTK("scsi : NCR5380_all_init()\n"); 621 dprintk(NDEBUG_INIT, "scsi : NCR5380_all_init()\n");
622 done = 1; 622 done = 1;
623 } 623 }
624} 624}
@@ -928,7 +928,7 @@ static int NCR5380_queue_command_lck(struct scsi_cmnd *cmd,
928 928
929 local_irq_restore(flags); 929 local_irq_restore(flags);
930 930
931 QU_PRINTK("scsi%d: command added to %s of queue\n", H_NO(cmd), 931 dprintk(NDEBUG_QUEUES, "scsi%d: command added to %s of queue\n", H_NO(cmd),
932 (cmd->cmnd[0] == REQUEST_SENSE) ? "head" : "tail"); 932 (cmd->cmnd[0] == REQUEST_SENSE) ? "head" : "tail");
933 933
934 /* If queue_command() is called from an interrupt (real one or bottom 934 /* If queue_command() is called from an interrupt (real one or bottom
@@ -998,7 +998,7 @@ static void NCR5380_main (struct work_struct *bl)
998 done = 1; 998 done = 1;
999 999
1000 if (!hostdata->connected) { 1000 if (!hostdata->connected) {
1001 MAIN_PRINTK( "scsi%d: not connected\n", HOSTNO ); 1001 dprintk(NDEBUG_MAIN, "scsi%d: not connected\n", HOSTNO );
1002 /* 1002 /*
1003 * Search through the issue_queue for a command destined 1003 * Search through the issue_queue for a command destined
1004 * for a target that's not busy. 1004 * for a target that's not busy.
@@ -1047,7 +1047,7 @@ static void NCR5380_main (struct work_struct *bl)
1047 * On failure, we must add the command back to the 1047 * On failure, we must add the command back to the
1048 * issue queue so we can keep trying. 1048 * issue queue so we can keep trying.
1049 */ 1049 */
1050 MAIN_PRINTK("scsi%d: main(): command for target %d " 1050 dprintk(NDEBUG_MAIN, "scsi%d: main(): command for target %d "
1051 "lun %d removed from issue_queue\n", 1051 "lun %d removed from issue_queue\n",
1052 HOSTNO, tmp->device->id, tmp->device->lun); 1052 HOSTNO, tmp->device->id, tmp->device->lun);
1053 /* 1053 /*
@@ -1076,7 +1076,7 @@ static void NCR5380_main (struct work_struct *bl)
1076 cmd_free_tag( tmp ); 1076 cmd_free_tag( tmp );
1077#endif 1077#endif
1078 local_irq_restore(flags); 1078 local_irq_restore(flags);
1079 MAIN_PRINTK("scsi%d: main(): select() failed, " 1079 dprintk(NDEBUG_MAIN, "scsi%d: main(): select() failed, "
1080 "returned to issue_queue\n", HOSTNO); 1080 "returned to issue_queue\n", HOSTNO);
1081 if (hostdata->connected) 1081 if (hostdata->connected)
1082 break; 1082 break;
@@ -1090,10 +1090,10 @@ static void NCR5380_main (struct work_struct *bl)
1090#endif 1090#endif
1091 ) { 1091 ) {
1092 local_irq_restore(flags); 1092 local_irq_restore(flags);
1093 MAIN_PRINTK("scsi%d: main: performing information transfer\n", 1093 dprintk(NDEBUG_MAIN, "scsi%d: main: performing information transfer\n",
1094 HOSTNO); 1094 HOSTNO);
1095 NCR5380_information_transfer(instance); 1095 NCR5380_information_transfer(instance);
1096 MAIN_PRINTK("scsi%d: main: done set false\n", HOSTNO); 1096 dprintk(NDEBUG_MAIN, "scsi%d: main: done set false\n", HOSTNO);
1097 done = 0; 1097 done = 0;
1098 } 1098 }
1099 } while (!done); 1099 } while (!done);
@@ -1130,7 +1130,7 @@ static void NCR5380_dma_complete( struct Scsi_Host *instance )
1130 return; 1130 return;
1131 } 1131 }
1132 1132
1133 DMA_PRINTK("scsi%d: real DMA transfer complete, basr 0x%X, sr 0x%X\n", 1133 dprintk(NDEBUG_DMA, "scsi%d: real DMA transfer complete, basr 0x%X, sr 0x%X\n",
1134 HOSTNO, NCR5380_read(BUS_AND_STATUS_REG), 1134 HOSTNO, NCR5380_read(BUS_AND_STATUS_REG),
1135 NCR5380_read(STATUS_REG)); 1135 NCR5380_read(STATUS_REG));
1136 1136
@@ -1189,27 +1189,27 @@ static irqreturn_t NCR5380_intr (int irq, void *dev_id)
1189 int done = 1, handled = 0; 1189 int done = 1, handled = 0;
1190 unsigned char basr; 1190 unsigned char basr;
1191 1191
1192 INT_PRINTK("scsi%d: NCR5380 irq triggered\n", HOSTNO); 1192 dprintk(NDEBUG_INTR, "scsi%d: NCR5380 irq triggered\n", HOSTNO);
1193 1193
1194 /* Look for pending interrupts */ 1194 /* Look for pending interrupts */
1195 basr = NCR5380_read(BUS_AND_STATUS_REG); 1195 basr = NCR5380_read(BUS_AND_STATUS_REG);
1196 INT_PRINTK("scsi%d: BASR=%02x\n", HOSTNO, basr); 1196 dprintk(NDEBUG_INTR, "scsi%d: BASR=%02x\n", HOSTNO, basr);
1197 /* dispatch to appropriate routine if found and done=0 */ 1197 /* dispatch to appropriate routine if found and done=0 */
1198 if (basr & BASR_IRQ) { 1198 if (basr & BASR_IRQ) {
1199 NCR5380_dprint(NDEBUG_INTR, instance); 1199 NCR5380_dprint(NDEBUG_INTR, instance);
1200 if ((NCR5380_read(STATUS_REG) & (SR_SEL|SR_IO)) == (SR_SEL|SR_IO)) { 1200 if ((NCR5380_read(STATUS_REG) & (SR_SEL|SR_IO)) == (SR_SEL|SR_IO)) {
1201 done = 0; 1201 done = 0;
1202// ENABLE_IRQ(); 1202// ENABLE_IRQ();
1203 INT_PRINTK("scsi%d: SEL interrupt\n", HOSTNO); 1203 dprintk(NDEBUG_INTR, "scsi%d: SEL interrupt\n", HOSTNO);
1204 NCR5380_reselect(instance); 1204 NCR5380_reselect(instance);
1205 (void) NCR5380_read(RESET_PARITY_INTERRUPT_REG); 1205 (void) NCR5380_read(RESET_PARITY_INTERRUPT_REG);
1206 } 1206 }
1207 else if (basr & BASR_PARITY_ERROR) { 1207 else if (basr & BASR_PARITY_ERROR) {
1208 INT_PRINTK("scsi%d: PARITY interrupt\n", HOSTNO); 1208 dprintk(NDEBUG_INTR, "scsi%d: PARITY interrupt\n", HOSTNO);
1209 (void) NCR5380_read(RESET_PARITY_INTERRUPT_REG); 1209 (void) NCR5380_read(RESET_PARITY_INTERRUPT_REG);
1210 } 1210 }
1211 else if ((NCR5380_read(STATUS_REG) & SR_RST) == SR_RST) { 1211 else if ((NCR5380_read(STATUS_REG) & SR_RST) == SR_RST) {
1212 INT_PRINTK("scsi%d: RESET interrupt\n", HOSTNO); 1212 dprintk(NDEBUG_INTR, "scsi%d: RESET interrupt\n", HOSTNO);
1213 (void)NCR5380_read(RESET_PARITY_INTERRUPT_REG); 1213 (void)NCR5380_read(RESET_PARITY_INTERRUPT_REG);
1214 } 1214 }
1215 else { 1215 else {
@@ -1229,7 +1229,7 @@ static irqreturn_t NCR5380_intr (int irq, void *dev_id)
1229 ((basr & BASR_END_DMA_TRANSFER) || 1229 ((basr & BASR_END_DMA_TRANSFER) ||
1230 !(basr & BASR_PHASE_MATCH))) { 1230 !(basr & BASR_PHASE_MATCH))) {
1231 1231
1232 INT_PRINTK("scsi%d: PHASE MISM or EOP interrupt\n", HOSTNO); 1232 dprintk(NDEBUG_INTR, "scsi%d: PHASE MISM or EOP interrupt\n", HOSTNO);
1233 NCR5380_dma_complete( instance ); 1233 NCR5380_dma_complete( instance );
1234 done = 0; 1234 done = 0;
1235// ENABLE_IRQ(); 1235// ENABLE_IRQ();
@@ -1238,7 +1238,7 @@ static irqreturn_t NCR5380_intr (int irq, void *dev_id)
1238 { 1238 {
1239/* MS: Ignore unknown phase mismatch interrupts (caused by EOP interrupt) */ 1239/* MS: Ignore unknown phase mismatch interrupts (caused by EOP interrupt) */
1240 if (basr & BASR_PHASE_MATCH) 1240 if (basr & BASR_PHASE_MATCH)
1241 INT_PRINTK("scsi%d: unknown interrupt, " 1241 dprintk(NDEBUG_INTR, "scsi%d: unknown interrupt, "
1242 "BASR 0x%x, MR 0x%x, SR 0x%x\n", 1242 "BASR 0x%x, MR 0x%x, SR 0x%x\n",
1243 HOSTNO, basr, NCR5380_read(MODE_REG), 1243 HOSTNO, basr, NCR5380_read(MODE_REG),
1244 NCR5380_read(STATUS_REG)); 1244 NCR5380_read(STATUS_REG));
@@ -1262,7 +1262,7 @@ static irqreturn_t NCR5380_intr (int irq, void *dev_id)
1262 } 1262 }
1263 1263
1264 if (!done) { 1264 if (!done) {
1265 INT_PRINTK("scsi%d: in int routine, calling main\n", HOSTNO); 1265 dprintk(NDEBUG_INTR, "scsi%d: in int routine, calling main\n", HOSTNO);
1266 /* Put a call to NCR5380_main() on the queue... */ 1266 /* Put a call to NCR5380_main() on the queue... */
1267 queue_main(); 1267 queue_main();
1268 } 1268 }
@@ -1339,7 +1339,7 @@ static int NCR5380_select(struct Scsi_Host *instance, struct scsi_cmnd *cmd,
1339 1339
1340 hostdata->restart_select = 0; 1340 hostdata->restart_select = 0;
1341 NCR5380_dprint(NDEBUG_ARBITRATION, instance); 1341 NCR5380_dprint(NDEBUG_ARBITRATION, instance);
1342 ARB_PRINTK("scsi%d: starting arbitration, id = %d\n", HOSTNO, 1342 dprintk(NDEBUG_ARBITRATION, "scsi%d: starting arbitration, id = %d\n", HOSTNO,
1343 instance->this_id); 1343 instance->this_id);
1344 1344
1345 /* 1345 /*
@@ -1385,7 +1385,7 @@ static int NCR5380_select(struct Scsi_Host *instance, struct scsi_cmnd *cmd,
1385 && !hostdata->connected); 1385 && !hostdata->connected);
1386#endif 1386#endif
1387 1387
1388 ARB_PRINTK("scsi%d: arbitration complete\n", HOSTNO); 1388 dprintk(NDEBUG_ARBITRATION, "scsi%d: arbitration complete\n", HOSTNO);
1389 1389
1390 if (hostdata->connected) { 1390 if (hostdata->connected) {
1391 NCR5380_write(MODE_REG, MR_BASE); 1391 NCR5380_write(MODE_REG, MR_BASE);
@@ -1406,7 +1406,7 @@ static int NCR5380_select(struct Scsi_Host *instance, struct scsi_cmnd *cmd,
1406 (NCR5380_read(INITIATOR_COMMAND_REG) & ICR_ARBITRATION_LOST) || 1406 (NCR5380_read(INITIATOR_COMMAND_REG) & ICR_ARBITRATION_LOST) ||
1407 hostdata->connected) { 1407 hostdata->connected) {
1408 NCR5380_write(MODE_REG, MR_BASE); 1408 NCR5380_write(MODE_REG, MR_BASE);
1409 ARB_PRINTK("scsi%d: lost arbitration, deasserting MR_ARBITRATE\n", 1409 dprintk(NDEBUG_ARBITRATION, "scsi%d: lost arbitration, deasserting MR_ARBITRATE\n",
1410 HOSTNO); 1410 HOSTNO);
1411 return -1; 1411 return -1;
1412 } 1412 }
@@ -1421,7 +1421,7 @@ static int NCR5380_select(struct Scsi_Host *instance, struct scsi_cmnd *cmd,
1421 hostdata->connected) { 1421 hostdata->connected) {
1422 NCR5380_write(MODE_REG, MR_BASE); 1422 NCR5380_write(MODE_REG, MR_BASE);
1423 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE); 1423 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE);
1424 ARB_PRINTK("scsi%d: lost arbitration, deasserting ICR_ASSERT_SEL\n", 1424 dprintk(NDEBUG_ARBITRATION, "scsi%d: lost arbitration, deasserting ICR_ASSERT_SEL\n",
1425 HOSTNO); 1425 HOSTNO);
1426 return -1; 1426 return -1;
1427 } 1427 }
@@ -1444,7 +1444,7 @@ static int NCR5380_select(struct Scsi_Host *instance, struct scsi_cmnd *cmd,
1444 return -1; 1444 return -1;
1445 } 1445 }
1446 1446
1447 ARB_PRINTK("scsi%d: won arbitration\n", HOSTNO); 1447 dprintk(NDEBUG_ARBITRATION, "scsi%d: won arbitration\n", HOSTNO);
1448 1448
1449 /* 1449 /*
1450 * Now that we have won arbitration, start Selection process, asserting 1450 * Now that we have won arbitration, start Selection process, asserting
@@ -1504,7 +1504,7 @@ static int NCR5380_select(struct Scsi_Host *instance, struct scsi_cmnd *cmd,
1504 1504
1505 udelay(1); 1505 udelay(1);
1506 1506
1507 SEL_PRINTK("scsi%d: selecting target %d\n", HOSTNO, cmd->device->id); 1507 dprintk(NDEBUG_SELECTION, "scsi%d: selecting target %d\n", HOSTNO, cmd->device->id);
1508 1508
1509 /* 1509 /*
1510 * The SCSI specification calls for a 250 ms timeout for the actual 1510 * The SCSI specification calls for a 250 ms timeout for the actual
@@ -1572,7 +1572,7 @@ static int NCR5380_select(struct Scsi_Host *instance, struct scsi_cmnd *cmd,
1572#endif 1572#endif
1573 cmd->scsi_done(cmd); 1573 cmd->scsi_done(cmd);
1574 NCR5380_write(SELECT_ENABLE_REG, hostdata->id_mask); 1574 NCR5380_write(SELECT_ENABLE_REG, hostdata->id_mask);
1575 SEL_PRINTK("scsi%d: target did not respond within 250ms\n", HOSTNO); 1575 dprintk(NDEBUG_SELECTION, "scsi%d: target did not respond within 250ms\n", HOSTNO);
1576 NCR5380_write(SELECT_ENABLE_REG, hostdata->id_mask); 1576 NCR5380_write(SELECT_ENABLE_REG, hostdata->id_mask);
1577 return 0; 1577 return 0;
1578 } 1578 }
@@ -1597,7 +1597,7 @@ static int NCR5380_select(struct Scsi_Host *instance, struct scsi_cmnd *cmd,
1597 /* Wait for start of REQ/ACK handshake */ 1597 /* Wait for start of REQ/ACK handshake */
1598 while (!(NCR5380_read(STATUS_REG) & SR_REQ)); 1598 while (!(NCR5380_read(STATUS_REG) & SR_REQ));
1599 1599
1600 SEL_PRINTK("scsi%d: target %d selected, going into MESSAGE OUT phase.\n", 1600 dprintk(NDEBUG_SELECTION, "scsi%d: target %d selected, going into MESSAGE OUT phase.\n",
1601 HOSTNO, cmd->device->id); 1601 HOSTNO, cmd->device->id);
1602 tmp[0] = IDENTIFY(1, cmd->device->lun); 1602 tmp[0] = IDENTIFY(1, cmd->device->lun);
1603 1603
@@ -1617,7 +1617,7 @@ static int NCR5380_select(struct Scsi_Host *instance, struct scsi_cmnd *cmd,
1617 data = tmp; 1617 data = tmp;
1618 phase = PHASE_MSGOUT; 1618 phase = PHASE_MSGOUT;
1619 NCR5380_transfer_pio(instance, &phase, &len, &data); 1619 NCR5380_transfer_pio(instance, &phase, &len, &data);
1620 SEL_PRINTK("scsi%d: nexus established.\n", HOSTNO); 1620 dprintk(NDEBUG_SELECTION, "scsi%d: nexus established.\n", HOSTNO);
1621 /* XXX need to handle errors here */ 1621 /* XXX need to handle errors here */
1622 hostdata->connected = cmd; 1622 hostdata->connected = cmd;
1623#ifndef SUPPORT_TAGS 1623#ifndef SUPPORT_TAGS
@@ -1680,11 +1680,11 @@ static int NCR5380_transfer_pio( struct Scsi_Host *instance,
1680 */ 1680 */
1681 while (!((tmp = NCR5380_read(STATUS_REG)) & SR_REQ)); 1681 while (!((tmp = NCR5380_read(STATUS_REG)) & SR_REQ));
1682 1682
1683 HSH_PRINTK("scsi%d: REQ detected\n", HOSTNO); 1683 dprintk(NDEBUG_HANDSHAKE, "scsi%d: REQ detected\n", HOSTNO);
1684 1684
1685 /* Check for phase mismatch */ 1685 /* Check for phase mismatch */
1686 if ((tmp & PHASE_MASK) != p) { 1686 if ((tmp & PHASE_MASK) != p) {
1687 PIO_PRINTK("scsi%d: phase mismatch\n", HOSTNO); 1687 dprintk(NDEBUG_PIO, "scsi%d: phase mismatch\n", HOSTNO);
1688 NCR5380_dprint_phase(NDEBUG_PIO, instance); 1688 NCR5380_dprint_phase(NDEBUG_PIO, instance);
1689 break; 1689 break;
1690 } 1690 }
@@ -1725,7 +1725,7 @@ static int NCR5380_transfer_pio( struct Scsi_Host *instance,
1725 1725
1726 while (NCR5380_read(STATUS_REG) & SR_REQ); 1726 while (NCR5380_read(STATUS_REG) & SR_REQ);
1727 1727
1728 HSH_PRINTK("scsi%d: req false, handshake complete\n", HOSTNO); 1728 dprintk(NDEBUG_HANDSHAKE, "scsi%d: req false, handshake complete\n", HOSTNO);
1729 1729
1730/* 1730/*
1731 * We have several special cases to consider during REQ/ACK handshaking : 1731 * We have several special cases to consider during REQ/ACK handshaking :
@@ -1746,7 +1746,7 @@ static int NCR5380_transfer_pio( struct Scsi_Host *instance,
1746 } 1746 }
1747 } while (--c); 1747 } while (--c);
1748 1748
1749 PIO_PRINTK("scsi%d: residual %d\n", HOSTNO, c); 1749 dprintk(NDEBUG_PIO, "scsi%d: residual %d\n", HOSTNO, c);
1750 1750
1751 *count = c; 1751 *count = c;
1752 *data = d; 1752 *data = d;
@@ -1854,7 +1854,7 @@ static int NCR5380_transfer_dma( struct Scsi_Host *instance,
1854 } 1854 }
1855 hostdata->dma_len = c; 1855 hostdata->dma_len = c;
1856 1856
1857 DMA_PRINTK("scsi%d: initializing DMA for %s, %d bytes %s %p\n", 1857 dprintk(NDEBUG_DMA, "scsi%d: initializing DMA for %s, %d bytes %s %p\n",
1858 HOSTNO, (p & SR_IO) ? "reading" : "writing", 1858 HOSTNO, (p & SR_IO) ? "reading" : "writing",
1859 c, (p & SR_IO) ? "to" : "from", *data); 1859 c, (p & SR_IO) ? "to" : "from", *data);
1860 1860
@@ -1996,7 +1996,7 @@ static void NCR5380_information_transfer (struct Scsi_Host *instance)
1996 --cmd->SCp.buffers_residual; 1996 --cmd->SCp.buffers_residual;
1997 cmd->SCp.this_residual = cmd->SCp.buffer->length; 1997 cmd->SCp.this_residual = cmd->SCp.buffer->length;
1998 cmd->SCp.ptr = SGADDR(cmd->SCp.buffer); 1998 cmd->SCp.ptr = SGADDR(cmd->SCp.buffer);
1999 INF_PRINTK("scsi%d: %d bytes and %d buffers left\n", 1999 dprintk(NDEBUG_INFORMATION, "scsi%d: %d bytes and %d buffers left\n",
2000 HOSTNO, cmd->SCp.this_residual, 2000 HOSTNO, cmd->SCp.this_residual,
2001 cmd->SCp.buffers_residual); 2001 cmd->SCp.buffers_residual);
2002 } 2002 }
@@ -2088,7 +2088,7 @@ static void NCR5380_information_transfer (struct Scsi_Host *instance)
2088 /* Accept message by clearing ACK */ 2088 /* Accept message by clearing ACK */
2089 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE); 2089 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE);
2090 2090
2091 LNK_PRINTK("scsi%d: target %d lun %d linked command " 2091 dprintk(NDEBUG_LINKED, "scsi%d: target %d lun %d linked command "
2092 "complete.\n", HOSTNO, cmd->device->id, cmd->device->lun); 2092 "complete.\n", HOSTNO, cmd->device->id, cmd->device->lun);
2093 2093
2094 /* Enable reselect interrupts */ 2094 /* Enable reselect interrupts */
@@ -2113,7 +2113,7 @@ static void NCR5380_information_transfer (struct Scsi_Host *instance)
2113 * and don't free it! */ 2113 * and don't free it! */
2114 cmd->next_link->tag = cmd->tag; 2114 cmd->next_link->tag = cmd->tag;
2115 cmd->result = cmd->SCp.Status | (cmd->SCp.Message << 8); 2115 cmd->result = cmd->SCp.Status | (cmd->SCp.Message << 8);
2116 LNK_PRINTK("scsi%d: target %d lun %d linked request " 2116 dprintk(NDEBUG_LINKED, "scsi%d: target %d lun %d linked request "
2117 "done, calling scsi_done().\n", 2117 "done, calling scsi_done().\n",
2118 HOSTNO, cmd->device->id, cmd->device->lun); 2118 HOSTNO, cmd->device->id, cmd->device->lun);
2119#ifdef NCR5380_STATS 2119#ifdef NCR5380_STATS
@@ -2128,7 +2128,7 @@ static void NCR5380_information_transfer (struct Scsi_Host *instance)
2128 /* Accept message by clearing ACK */ 2128 /* Accept message by clearing ACK */
2129 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE); 2129 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE);
2130 hostdata->connected = NULL; 2130 hostdata->connected = NULL;
2131 QU_PRINTK("scsi%d: command for target %d, lun %d " 2131 dprintk(NDEBUG_QUEUES, "scsi%d: command for target %d, lun %d "
2132 "completed\n", HOSTNO, cmd->device->id, cmd->device->lun); 2132 "completed\n", HOSTNO, cmd->device->id, cmd->device->lun);
2133#ifdef SUPPORT_TAGS 2133#ifdef SUPPORT_TAGS
2134 cmd_free_tag( cmd ); 2134 cmd_free_tag( cmd );
@@ -2142,7 +2142,7 @@ static void NCR5380_information_transfer (struct Scsi_Host *instance)
2142 /* ++Andreas: the mid level code knows about 2142 /* ++Andreas: the mid level code knows about
2143 QUEUE_FULL now. */ 2143 QUEUE_FULL now. */
2144 TAG_ALLOC *ta = &TagAlloc[cmd->device->id][cmd->device->lun]; 2144 TAG_ALLOC *ta = &TagAlloc[cmd->device->id][cmd->device->lun];
2145 TAG_PRINTK("scsi%d: target %d lun %d returned " 2145 dprintk(NDEBUG_TAGS, "scsi%d: target %d lun %d returned "
2146 "QUEUE_FULL after %d commands\n", 2146 "QUEUE_FULL after %d commands\n",
2147 HOSTNO, cmd->device->id, cmd->device->lun, 2147 HOSTNO, cmd->device->id, cmd->device->lun,
2148 ta->nr_allocated); 2148 ta->nr_allocated);
@@ -2186,7 +2186,7 @@ static void NCR5380_information_transfer (struct Scsi_Host *instance)
2186 if ((cmd->cmnd[0] != REQUEST_SENSE) && 2186 if ((cmd->cmnd[0] != REQUEST_SENSE) &&
2187 (status_byte(cmd->SCp.Status) == CHECK_CONDITION)) { 2187 (status_byte(cmd->SCp.Status) == CHECK_CONDITION)) {
2188 scsi_eh_prep_cmnd(cmd, &hostdata->ses, NULL, 0, ~0); 2188 scsi_eh_prep_cmnd(cmd, &hostdata->ses, NULL, 0, ~0);
2189 ASEN_PRINTK("scsi%d: performing request sense\n", 2189 dprintk(NDEBUG_AUTOSENSE, "scsi%d: performing request sense\n",
2190 HOSTNO); 2190 HOSTNO);
2191 /* this is initialized from initialize_SCp 2191 /* this is initialized from initialize_SCp
2192 cmd->SCp.buffer = NULL; 2192 cmd->SCp.buffer = NULL;
@@ -2198,7 +2198,7 @@ static void NCR5380_information_transfer (struct Scsi_Host *instance)
2198 SET_NEXT(cmd, hostdata->issue_queue); 2198 SET_NEXT(cmd, hostdata->issue_queue);
2199 hostdata->issue_queue = (struct scsi_cmnd *) cmd; 2199 hostdata->issue_queue = (struct scsi_cmnd *) cmd;
2200 local_irq_restore(flags); 2200 local_irq_restore(flags);
2201 QU_PRINTK("scsi%d: REQUEST SENSE added to head of " 2201 dprintk(NDEBUG_QUEUES, "scsi%d: REQUEST SENSE added to head of "
2202 "issue queue\n", H_NO(cmd)); 2202 "issue queue\n", H_NO(cmd));
2203 } else 2203 } else
2204#endif /* def AUTOSENSE */ 2204#endif /* def AUTOSENSE */
@@ -2238,7 +2238,7 @@ static void NCR5380_information_transfer (struct Scsi_Host *instance)
2238 cmd->device->tagged_supported = 0; 2238 cmd->device->tagged_supported = 0;
2239 hostdata->busy[cmd->device->id] |= (1 << cmd->device->lun); 2239 hostdata->busy[cmd->device->id] |= (1 << cmd->device->lun);
2240 cmd->tag = TAG_NONE; 2240 cmd->tag = TAG_NONE;
2241 TAG_PRINTK("scsi%d: target %d lun %d rejected " 2241 dprintk(NDEBUG_TAGS, "scsi%d: target %d lun %d rejected "
2242 "QUEUE_TAG message; tagged queuing " 2242 "QUEUE_TAG message; tagged queuing "
2243 "disabled\n", 2243 "disabled\n",
2244 HOSTNO, cmd->device->id, cmd->device->lun); 2244 HOSTNO, cmd->device->id, cmd->device->lun);
@@ -2255,7 +2255,7 @@ static void NCR5380_information_transfer (struct Scsi_Host *instance)
2255 hostdata->connected = NULL; 2255 hostdata->connected = NULL;
2256 hostdata->disconnected_queue = cmd; 2256 hostdata->disconnected_queue = cmd;
2257 local_irq_restore(flags); 2257 local_irq_restore(flags);
2258 QU_PRINTK("scsi%d: command for target %d lun %d was " 2258 dprintk(NDEBUG_QUEUES, "scsi%d: command for target %d lun %d was "
2259 "moved from connected to the " 2259 "moved from connected to the "
2260 "disconnected_queue\n", HOSTNO, 2260 "disconnected_queue\n", HOSTNO,
2261 cmd->device->id, cmd->device->lun); 2261 cmd->device->id, cmd->device->lun);
@@ -2308,13 +2308,13 @@ static void NCR5380_information_transfer (struct Scsi_Host *instance)
2308 /* Accept first byte by clearing ACK */ 2308 /* Accept first byte by clearing ACK */
2309 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE); 2309 NCR5380_write(INITIATOR_COMMAND_REG, ICR_BASE);
2310 2310
2311 EXT_PRINTK("scsi%d: receiving extended message\n", HOSTNO); 2311 dprintk(NDEBUG_EXTENDED, "scsi%d: receiving extended message\n", HOSTNO);
2312 2312
2313 len = 2; 2313 len = 2;
2314 data = extended_msg + 1; 2314 data = extended_msg + 1;
2315 phase = PHASE_MSGIN; 2315 phase = PHASE_MSGIN;
2316 NCR5380_transfer_pio(instance, &phase, &len, &data); 2316 NCR5380_transfer_pio(instance, &phase, &len, &data);
2317 EXT_PRINTK("scsi%d: length=%d, code=0x%02x\n", HOSTNO, 2317 dprintk(NDEBUG_EXTENDED, "scsi%d: length=%d, code=0x%02x\n", HOSTNO,
2318 (int)extended_msg[1], (int)extended_msg[2]); 2318 (int)extended_msg[1], (int)extended_msg[2]);
2319 2319
2320 if (!len && extended_msg[1] <= 2320 if (!len && extended_msg[1] <=
@@ -2326,7 +2326,7 @@ static void NCR5380_information_transfer (struct Scsi_Host *instance)
2326 phase = PHASE_MSGIN; 2326 phase = PHASE_MSGIN;
2327 2327
2328 NCR5380_transfer_pio(instance, &phase, &len, &data); 2328 NCR5380_transfer_pio(instance, &phase, &len, &data);
2329 EXT_PRINTK("scsi%d: message received, residual %d\n", 2329 dprintk(NDEBUG_EXTENDED, "scsi%d: message received, residual %d\n",
2330 HOSTNO, len); 2330 HOSTNO, len);
2331 2331
2332 switch (extended_msg[2]) { 2332 switch (extended_msg[2]) {
@@ -2458,7 +2458,7 @@ static void NCR5380_reselect (struct Scsi_Host *instance)
2458 2458
2459 target_mask = NCR5380_read(CURRENT_SCSI_DATA_REG) & ~(hostdata->id_mask); 2459 target_mask = NCR5380_read(CURRENT_SCSI_DATA_REG) & ~(hostdata->id_mask);
2460 2460
2461 RSL_PRINTK("scsi%d: reselect\n", HOSTNO); 2461 dprintk(NDEBUG_RESELECTION, "scsi%d: reselect\n", HOSTNO);
2462 2462
2463 /* 2463 /*
2464 * At this point, we have detected that our SCSI ID is on the bus, 2464 * At this point, we have detected that our SCSI ID is on the bus,
@@ -2580,13 +2580,13 @@ static void NCR5380_reselect (struct Scsi_Host *instance)
2580 if (!NCR5380_transfer_pio(instance, &phase, &len, &data) && 2580 if (!NCR5380_transfer_pio(instance, &phase, &len, &data) &&
2581 msg[1] == SIMPLE_QUEUE_TAG) 2581 msg[1] == SIMPLE_QUEUE_TAG)
2582 tag = msg[2]; 2582 tag = msg[2];
2583 TAG_PRINTK("scsi%d: target mask %02x, lun %d sent tag %d at " 2583 dprintk(NDEBUG_TAGS, "scsi%d: target mask %02x, lun %d sent tag %d at "
2584 "reselection\n", HOSTNO, target_mask, lun, tag); 2584 "reselection\n", HOSTNO, target_mask, lun, tag);
2585 } 2585 }
2586#endif 2586#endif
2587 2587
2588 hostdata->connected = tmp; 2588 hostdata->connected = tmp;
2589 RSL_PRINTK("scsi%d: nexus established, target = %d, lun = %d, tag = %d\n", 2589 dprintk(NDEBUG_RESELECTION, "scsi%d: nexus established, target = %d, lun = %d, tag = %d\n",
2590 HOSTNO, tmp->device->id, tmp->device->lun, tmp->tag); 2590 HOSTNO, tmp->device->id, tmp->device->lun, tmp->tag);
2591} 2591}
2592 2592
@@ -2622,7 +2622,7 @@ static int NCR5380_abort(struct scsi_cmnd *cmd)
2622 2622
2623 local_irq_save(flags); 2623 local_irq_save(flags);
2624 2624
2625 ABRT_PRINTK("scsi%d: abort called basr 0x%02x, sr 0x%02x\n", HOSTNO, 2625 dprintk(NDEBUG_ABORT, "scsi%d: abort called basr 0x%02x, sr 0x%02x\n", HOSTNO,
2626 NCR5380_read(BUS_AND_STATUS_REG), 2626 NCR5380_read(BUS_AND_STATUS_REG),
2627 NCR5380_read(STATUS_REG)); 2627 NCR5380_read(STATUS_REG));
2628 2628
@@ -2635,7 +2635,7 @@ static int NCR5380_abort(struct scsi_cmnd *cmd)
2635 2635
2636 if (hostdata->connected == cmd) { 2636 if (hostdata->connected == cmd) {
2637 2637
2638 ABRT_PRINTK("scsi%d: aborting connected command\n", HOSTNO); 2638 dprintk(NDEBUG_ABORT, "scsi%d: aborting connected command\n", HOSTNO);
2639/* 2639/*
2640 * We should perform BSY checking, and make sure we haven't slipped 2640 * We should perform BSY checking, and make sure we haven't slipped
2641 * into BUS FREE. 2641 * into BUS FREE.
@@ -2686,7 +2686,7 @@ static int NCR5380_abort(struct scsi_cmnd *cmd)
2686 SET_NEXT(tmp, NULL); 2686 SET_NEXT(tmp, NULL);
2687 tmp->result = DID_ABORT << 16; 2687 tmp->result = DID_ABORT << 16;
2688 local_irq_restore(flags); 2688 local_irq_restore(flags);
2689 ABRT_PRINTK("scsi%d: abort removed command from issue queue.\n", 2689 dprintk(NDEBUG_ABORT, "scsi%d: abort removed command from issue queue.\n",
2690 HOSTNO); 2690 HOSTNO);
2691 /* Tagged queuing note: no tag to free here, hasn't been assigned 2691 /* Tagged queuing note: no tag to free here, hasn't been assigned
2692 * yet... */ 2692 * yet... */
@@ -2707,7 +2707,7 @@ static int NCR5380_abort(struct scsi_cmnd *cmd)
2707 2707
2708 if (hostdata->connected) { 2708 if (hostdata->connected) {
2709 local_irq_restore(flags); 2709 local_irq_restore(flags);
2710 ABRT_PRINTK("scsi%d: abort failed, command connected.\n", HOSTNO); 2710 dprintk(NDEBUG_ABORT, "scsi%d: abort failed, command connected.\n", HOSTNO);
2711 return FAILED; 2711 return FAILED;
2712 } 2712 }
2713 2713
@@ -2740,12 +2740,12 @@ static int NCR5380_abort(struct scsi_cmnd *cmd)
2740 tmp = NEXT(tmp)) 2740 tmp = NEXT(tmp))
2741 if (cmd == tmp) { 2741 if (cmd == tmp) {
2742 local_irq_restore(flags); 2742 local_irq_restore(flags);
2743 ABRT_PRINTK("scsi%d: aborting disconnected command.\n", HOSTNO); 2743 dprintk(NDEBUG_ABORT, "scsi%d: aborting disconnected command.\n", HOSTNO);
2744 2744
2745 if (NCR5380_select (instance, cmd, (int) cmd->tag)) 2745 if (NCR5380_select (instance, cmd, (int) cmd->tag))
2746 return FAILED; 2746 return FAILED;
2747 2747
2748 ABRT_PRINTK("scsi%d: nexus reestablished.\n", HOSTNO); 2748 dprintk(NDEBUG_ABORT, "scsi%d: nexus reestablished.\n", HOSTNO);
2749 2749
2750 do_abort (instance); 2750 do_abort (instance);
2751 2751
@@ -2864,7 +2864,7 @@ static int NCR5380_bus_reset(struct scsi_cmnd *cmd)
2864 */ 2864 */
2865 2865
2866 if ((cmd = connected)) { 2866 if ((cmd = connected)) {
2867 ABRT_PRINTK("scsi%d: reset aborted a connected command\n", H_NO(cmd)); 2867 dprintk(NDEBUG_ABORT, "scsi%d: reset aborted a connected command\n", H_NO(cmd));
2868 cmd->result = (cmd->result & 0xffff) | (DID_RESET << 16); 2868 cmd->result = (cmd->result & 0xffff) | (DID_RESET << 16);
2869 cmd->scsi_done( cmd ); 2869 cmd->scsi_done( cmd );
2870 } 2870 }
@@ -2876,7 +2876,7 @@ static int NCR5380_bus_reset(struct scsi_cmnd *cmd)
2876 cmd->scsi_done( cmd ); 2876 cmd->scsi_done( cmd );
2877 } 2877 }
2878 if (i > 0) 2878 if (i > 0)
2879 ABRT_PRINTK("scsi: reset aborted %d disconnected command(s)\n", i); 2879 dprintk(NDEBUG_ABORT, "scsi: reset aborted %d disconnected command(s)\n", i);
2880 2880
2881 2881
2882 /* since all commands have been explicitly terminated, we need to tell 2882 /* since all commands have been explicitly terminated, we need to tell
@@ -2910,11 +2910,11 @@ static int NCR5380_bus_reset(struct scsi_cmnd *cmd)
2910 */ 2910 */
2911 2911
2912 if (hostdata->issue_queue) 2912 if (hostdata->issue_queue)
2913 ABRT_PRINTK("scsi%d: reset aborted issued command(s)\n", H_NO(cmd)); 2913 dprintk(NDEBUG_ABORT, "scsi%d: reset aborted issued command(s)\n", H_NO(cmd));
2914 if (hostdata->connected) 2914 if (hostdata->connected)
2915 ABRT_PRINTK("scsi%d: reset aborted a connected command\n", H_NO(cmd)); 2915 dprintk(NDEBUG_ABORT, "scsi%d: reset aborted a connected command\n", H_NO(cmd));
2916 if (hostdata->disconnected_queue) 2916 if (hostdata->disconnected_queue)
2917 ABRT_PRINTK("scsi%d: reset aborted disconnected command(s)\n", H_NO(cmd)); 2917 dprintk(NDEBUG_ABORT, "scsi%d: reset aborted disconnected command(s)\n", H_NO(cmd));
2918 2918
2919 local_irq_save(flags); 2919 local_irq_save(flags);
2920 hostdata->issue_queue = NULL; 2920 hostdata->issue_queue = NULL;