]> err.no Git - linux-2.6/blobdiff - drivers/ide/ide-floppy.c
ide: add __ide_default_irq() inline helper
[linux-2.6] / drivers / ide / ide-floppy.c
index e2bcd3af45db3ea6d9a4e6cd1834c17ca464407d..f05fbc2bd7a89ac597c1261acfc143f6df21d173 100644 (file)
@@ -262,10 +262,7 @@ static void ide_floppy_io_buffers(ide_drive_t *drive, struct ide_atapi_pc *pc,
        if (bcount) {
                printk(KERN_ERR "%s: leftover data in %s, bcount == %d\n",
                                drive->name, __func__, bcount);
-               if (direction)
-                       ide_atapi_write_zeros(drive, bcount);
-               else
-                       ide_atapi_discard_data(drive, bcount);
+               ide_pad_transfer(drive, direction, bcount);
        }
 }
 
@@ -491,7 +488,7 @@ static ide_startstop_t idefloppy_pc_intr(ide_drive_t *drive)
                                printk(KERN_ERR "ide-floppy: The floppy wants "
                                        "to send us more data than expected "
                                        "- discarding data\n");
-                               ide_atapi_discard_data(drive, bcount);
+                               ide_pad_transfer(drive, 0, bcount);
 
                                ide_set_handler(drive,
                                                &idefloppy_pc_intr,
@@ -696,7 +693,7 @@ static ide_startstop_t idefloppy_issue_pc(ide_drive_t *drive,
                return ide_started;
        } else {
                /* Issue the packet command */
-               hwif->OUTB(WIN_PACKETCMD, hwif->io_ports.command_addr);
+               ide_execute_pkt_cmd(drive);
                return (*pkt_xfer_routine) (drive);
        }
 }