aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi
diff options
context:
space:
mode:
authorBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2008-07-15 15:21:54 -0400
committerBartlomiej Zolnierkiewicz <bzolnier@gmail.com>2008-07-15 15:21:54 -0400
commit568ca92774d2f6be4a7e2f8357559bfdc9424056 (patch)
treebde2cd61eafb613124923a6e57de91f0d0e4f016 /drivers/scsi
parent0b2eea4c5594ceaf13c57eaff7ff226263f1c36f (diff)
ide-{floppy,tape,scsi}: log device name instead of driver name
Log device name instead of driver name in *_pc_intr() and *_transfer_pc*(). While at it: * Merge two consecutive printk()-s in *_pc_intr() together. * Replace "floppy"/"tape"/"scsi" references in printk()-s by "device". Cc: Borislav Petkov <petkovbb@gmail.com> Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/scsi')
-rw-r--r--drivers/scsi/ide-scsi.c24
1 files changed, 13 insertions, 11 deletions
diff --git a/drivers/scsi/ide-scsi.c b/drivers/scsi/ide-scsi.c
index d2dad9039e0d..5b8a1931ac9b 100644
--- a/drivers/scsi/ide-scsi.c
+++ b/drivers/scsi/ide-scsi.c
@@ -391,7 +391,7 @@ static ide_startstop_t idescsi_pc_intr (ide_drive_t *drive)
391 ireason = hwif->INB(hwif->io_ports.nsect_addr); 391 ireason = hwif->INB(hwif->io_ports.nsect_addr);
392 392
393 if (ireason & CD) { 393 if (ireason & CD) {
394 printk(KERN_ERR "ide-scsi: CoD != 0 in idescsi_pc_intr\n"); 394 printk(KERN_ERR "%s: CoD != 0 in %s\n", drive->name, __func__);
395 return ide_do_reset (drive); 395 return ide_do_reset (drive);
396 } 396 }
397 if (((ireason & IO) == IO) == !!(pc->flags & PC_FLAG_WRITING)) { 397 if (((ireason & IO) == IO) == !!(pc->flags & PC_FLAG_WRITING)) {
@@ -406,9 +406,10 @@ static ide_startstop_t idescsi_pc_intr (ide_drive_t *drive)
406 temp = pc->xferred + bcount; 406 temp = pc->xferred + bcount;
407 if (temp > pc->req_xfer) { 407 if (temp > pc->req_xfer) {
408 if (temp > pc->buf_size) { 408 if (temp > pc->buf_size) {
409 printk(KERN_ERR "ide-scsi: The scsi wants to " 409 printk(KERN_ERR "%s: The device wants to send "
410 "send us more data than expected " 410 "us more data than expected - "
411 "- discarding data\n"); 411 "discarding data\n",
412 drive->name);
412 temp = pc->buf_size - pc->xferred; 413 temp = pc->buf_size - pc->xferred;
413 if (temp) { 414 if (temp) {
414 if (pc->sg) 415 if (pc->sg)
@@ -417,8 +418,9 @@ static ide_startstop_t idescsi_pc_intr (ide_drive_t *drive)
417 else 418 else
418 hwif->input_data(drive, NULL, 419 hwif->input_data(drive, NULL,
419 pc->cur_pos, temp); 420 pc->cur_pos, temp);
420 printk(KERN_ERR "ide-scsi: transferred" 421 printk(KERN_ERR "%s: transferred %d of "
421 " %d of %d bytes\n", 422 "%d bytes\n",
423 drive->name,
422 temp, bcount); 424 temp, bcount);
423 } 425 }
424 pc->xferred += temp; 426 pc->xferred += temp;
@@ -427,7 +429,7 @@ static ide_startstop_t idescsi_pc_intr (ide_drive_t *drive)
427 ide_set_handler(drive, &idescsi_pc_intr, get_timeout(pc), idescsi_expiry); 429 ide_set_handler(drive, &idescsi_pc_intr, get_timeout(pc), idescsi_expiry);
428 return ide_started; 430 return ide_started;
429 } 431 }
430 debug_log("The scsi wants to send us more data than " 432 debug_log("The device wants to send us more data than "
431 "expected - allowing transfer\n"); 433 "expected - allowing transfer\n");
432 } 434 }
433 xferfunc = hwif->input_data; 435 xferfunc = hwif->input_data;
@@ -458,14 +460,14 @@ static ide_startstop_t idescsi_transfer_pc(ide_drive_t *drive)
458 u8 ireason; 460 u8 ireason;
459 461
460 if (ide_wait_stat(&startstop,drive,DRQ_STAT,BUSY_STAT,WAIT_READY)) { 462 if (ide_wait_stat(&startstop,drive,DRQ_STAT,BUSY_STAT,WAIT_READY)) {
461 printk(KERN_ERR "ide-scsi: Strange, packet command " 463 printk(KERN_ERR "%s: Strange, packet command initiated yet "
462 "initiated yet DRQ isn't asserted\n"); 464 "DRQ isn't asserted\n", drive->name);
463 return startstop; 465 return startstop;
464 } 466 }
465 ireason = hwif->INB(hwif->io_ports.nsect_addr); 467 ireason = hwif->INB(hwif->io_ports.nsect_addr);
466 if ((ireason & CD) == 0 || (ireason & IO)) { 468 if ((ireason & CD) == 0 || (ireason & IO)) {
467 printk(KERN_ERR "ide-scsi: (IO,CoD) != (0,1) while " 469 printk(KERN_ERR "%s: (IO,CoD) != (0,1) while issuing "
468 "issuing a packet command\n"); 470 "a packet command\n", drive->name);
469 return ide_do_reset (drive); 471 return ide_do_reset (drive);
470 } 472 }
471 473