aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide')
-rw-r--r--drivers/ide/ide-floppy.c3
-rw-r--r--drivers/ide/ide-lib.c21
-rw-r--r--drivers/ide/ide-tape.c3
3 files changed, 12 insertions, 15 deletions
diff --git a/drivers/ide/ide-floppy.c b/drivers/ide/ide-floppy.c
index 7b94c7aff256..2a37a08ddd57 100644
--- a/drivers/ide/ide-floppy.c
+++ b/drivers/ide/ide-floppy.c
@@ -772,9 +772,8 @@ static void idefloppy_retry_pc (ide_drive_t *drive)
772{ 772{
773 idefloppy_pc_t *pc; 773 idefloppy_pc_t *pc;
774 struct request *rq; 774 struct request *rq;
775 atapi_error_t error;
776 775
777 error.all = HWIF(drive)->INB(IDE_ERROR_REG); 776 (void)drive->hwif->INB(IDE_ERROR_REG);
778 pc = idefloppy_next_pc_storage(drive); 777 pc = idefloppy_next_pc_storage(drive);
779 rq = idefloppy_next_rq_storage(drive); 778 rq = idefloppy_next_rq_storage(drive);
780 idefloppy_create_request_sense_cmd(pc); 779 idefloppy_create_request_sense_cmd(pc);
diff --git a/drivers/ide/ide-lib.c b/drivers/ide/ide-lib.c
index dc7e539b4d0b..562f5efae9c6 100644
--- a/drivers/ide/ide-lib.c
+++ b/drivers/ide/ide-lib.c
@@ -562,9 +562,8 @@ static u8 ide_dump_ata_status(ide_drive_t *drive, const char *msg, u8 stat)
562static u8 ide_dump_atapi_status(ide_drive_t *drive, const char *msg, u8 stat) 562static u8 ide_dump_atapi_status(ide_drive_t *drive, const char *msg, u8 stat)
563{ 563{
564 unsigned long flags; 564 unsigned long flags;
565 atapi_error_t error; 565 u8 err = 0;
566 566
567 error.all = 0;
568 local_irq_save(flags); 567 local_irq_save(flags);
569 printk("%s: %s: status=0x%02x { ", drive->name, msg, stat); 568 printk("%s: %s: status=0x%02x { ", drive->name, msg, stat);
570 if (stat & BUSY_STAT) 569 if (stat & BUSY_STAT)
@@ -580,19 +579,19 @@ static u8 ide_dump_atapi_status(ide_drive_t *drive, const char *msg, u8 stat)
580 } 579 }
581 printk("}\n"); 580 printk("}\n");
582 if ((stat & (BUSY_STAT|ERR_STAT)) == ERR_STAT) { 581 if ((stat & (BUSY_STAT|ERR_STAT)) == ERR_STAT) {
583 error.all = HWIF(drive)->INB(IDE_ERROR_REG); 582 err = drive->hwif->INB(IDE_ERROR_REG);
584 printk("%s: %s: error=0x%02x { ", drive->name, msg, error.all); 583 printk("%s: %s: error=0x%02x { ", drive->name, msg, err);
585 if (error.b.ili) printk("IllegalLengthIndication "); 584 if (err & ILI_ERR) printk("IllegalLengthIndication ");
586 if (error.b.eom) printk("EndOfMedia "); 585 if (err & EOM_ERR) printk("EndOfMedia ");
587 if (error.b.abrt) printk("AbortedCommand "); 586 if (err & ABRT_ERR) printk("AbortedCommand ");
588 if (error.b.mcr) printk("MediaChangeRequested "); 587 if (err & MCR_ERR) printk("MediaChangeRequested ");
589 if (error.b.sense_key) printk("LastFailedSense=0x%02x ", 588 if (err & LFS_ERR) printk("LastFailedSense=0x%02x ",
590 error.b.sense_key); 589 (err & LFS_ERR) >> 4);
591 printk("}\n"); 590 printk("}\n");
592 } 591 }
593 ide_dump_opcode(drive); 592 ide_dump_opcode(drive);
594 local_irq_restore(flags); 593 local_irq_restore(flags);
595 return error.all; 594 return err;
596} 595}
597 596
598/** 597/**
diff --git a/drivers/ide/ide-tape.c b/drivers/ide/ide-tape.c
index c91039505436..2c03f469f06e 100644
--- a/drivers/ide/ide-tape.c
+++ b/drivers/ide/ide-tape.c
@@ -1808,9 +1808,8 @@ static ide_startstop_t idetape_retry_pc (ide_drive_t *drive)
1808 idetape_tape_t *tape = drive->driver_data; 1808 idetape_tape_t *tape = drive->driver_data;
1809 idetape_pc_t *pc; 1809 idetape_pc_t *pc;
1810 struct request *rq; 1810 struct request *rq;
1811 atapi_error_t error;
1812 1811
1813 error.all = HWIF(drive)->INB(IDE_ERROR_REG); 1812 (void)drive->hwif->INB(IDE_ERROR_REG);
1814 pc = idetape_next_pc_storage(drive); 1813 pc = idetape_next_pc_storage(drive);
1815 rq = idetape_next_rq_storage(drive); 1814 rq = idetape_next_rq_storage(drive);
1816 idetape_create_request_sense_cmd(pc); 1815 idetape_create_request_sense_cmd(pc);