]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
libata-sff: tf_load
authorAlan Cox <alan@lxorguk.ukuu.org.uk>
Mon, 19 Nov 2007 14:34:56 +0000 (14:34 +0000)
committerJeff Garzik <jeff@garzik.org>
Wed, 23 Jan 2008 10:24:09 +0000 (05:24 -0500)
Jeff said he preferred that the SFF tf_load followed the spec and we
documented that anyone who needed different overrode it, rather than it
using the ->check_status methods. No driver relies on the current behaviour.

Signed-off-by: Alan Cox <alan@redhat.com>
Signed-off-by: Jeff Garzik <jeff@garzik.org>
drivers/ata/libata-sff.c

index b7ac80b4b1fbd91135e2e6b8f8b83b4d4bf8d300..fd5fe4e7e75abdec5af004f9af1da8f18f6310c1 100644 (file)
@@ -147,7 +147,9 @@ void ata_exec_command(struct ata_port *ap, const struct ata_taskfile *tf)
  *     @tf: ATA taskfile register set for storing input
  *
  *     Reads ATA taskfile registers for currently-selected device
- *     into @tf.
+ *     into @tf. Assumes the device has a fully SFF compliant task file
+ *     layout and behaviour. If you device does not (eg has a different
+ *     status method) then you will need to provide a replacement tf_read
  *
  *     LOCKING:
  *     Inherited from caller.
@@ -156,7 +158,7 @@ void ata_tf_read(struct ata_port *ap, struct ata_taskfile *tf)
 {
        struct ata_ioports *ioaddr = &ap->ioaddr;
 
-       tf->command = ata_chk_status(ap);
+       tf->command = ata_check_status(ap);
        tf->feature = ioread8(ioaddr->error_addr);
        tf->nsect = ioread8(ioaddr->nsect_addr);
        tf->lbal = ioread8(ioaddr->lbal_addr);