aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide/ide-io.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/ide/ide-io.c')
-rw-r--r--drivers/ide/ide-io.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/drivers/ide/ide-io.c b/drivers/ide/ide-io.c
index 32eaa3f80515..e2eb408a8a18 100644
--- a/drivers/ide/ide-io.c
+++ b/drivers/ide/ide-io.c
@@ -800,7 +800,20 @@ static ide_startstop_t do_special (ide_drive_t *drive)
800 s->b.set_tune = 0; 800 s->b.set_tune = 0;
801 801
802 if (set_pio_mode_abuse(drive->hwif, req_pio)) { 802 if (set_pio_mode_abuse(drive->hwif, req_pio)) {
803 if (hwif->set_pio_mode) 803
804 if (hwif->set_pio_mode == NULL)
805 return ide_stopped;
806
807 /*
808 * take ide_lock for drive->[no_]unmask/[no_]io_32bit
809 */
810 if (req_pio == 8 || req_pio == 9) {
811 unsigned long flags;
812
813 spin_lock_irqsave(&ide_lock, flags);
814 hwif->set_pio_mode(drive, req_pio);
815 spin_unlock_irqrestore(&ide_lock, flags);
816 } else
804 hwif->set_pio_mode(drive, req_pio); 817 hwif->set_pio_mode(drive, req_pio);
805 } else { 818 } else {
806 int keep_dma = drive->using_dma; 819 int keep_dma = drive->using_dma;