• Alan Cox's avatar
    libata-sff: Fix oops reported in kerneloops.org for pnp devices with no ctl · a57c1bad
    Alan Cox authored
    - Make ata_sff_altstatus private so nobody uses it by mistake
    - Drop the 400nS delay from it
    ata_sff_irq_status	-	encapsulates the IRQ check logic
    This function keeps the existing behaviour for altstatus using devices. I
    actually suspect the logic was wrong before the changes but -rc isn't the
    time to play with that
    ata_sff_sync		-	ensure writes hit the device
    Really we want an io* operation for 'is posted' eg ioisposted(ioaddr) so
    that we can fix the nasty delay this causes on most systems.
    - ata_sff_pause		-	400nS delay
    Ensure the command hit the device and delay 400nS
    - ata_sff_dma_pause
    Ensure the I/O hit the device and enforce an HDMA1:0 transition delay.
    Requires altstatus register exists, BUG if not so we don't risk
    corruption in MWDMA modes. (UDMA the checksum will save your backside in
    The only other complication then is devices with their own handlers.
    rb532 can use dma_pause but scc needs to access its own altstatus
    register for internal errata workarounds so directly call the drivers own
    altstatus function.
    Signed-off-by: default avatarAlan Cox <alan@redhat.com>
    Signed-off-by: default avatarJeff Garzik <jgarzik@redhat.com>
pata_icside.c 16.3 KB