All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jeff Garzik <jgarzik@pobox.com>
To: Brett Russ <russb@emc.com>
Cc: linux-ide@vger.kernel.org, ric@emc.com
Subject: [PATCH] Re: AHCI: support for tf_read (RFC)
Date: Fri, 25 Feb 2005 18:19:14 -0500	[thread overview]
Message-ID: <421FB272.4030502@pobox.com> (raw)
In-Reply-To: <20050224232413.4869514FC5@lns1032.lss.emc.com>

[-- Attachment #1: Type: text/plain, Size: 468 bytes --]

Brett Russ wrote:
> I coded this because ata_pass_thru_cc() (in the dev branch) and other
> functions call tf_read() which is supported for most except ahci.
> I've been unable to test because I'm leaving on vacation and am in a
> last minute rush but wanted to get this out there for comments.
> 
> Signed-off-by: Brett Russ <russb@emc.com>

I checked the attached patch into a local repository, but haven't yet 
merged it into libata-dev-2.6, or tested it.

	Jeff



[-- Attachment #2: patch --]
[-- Type: text/plain, Size: 1416 bytes --]

# This is a BitKeeper generated diff -Nru style patch.
#
# ChangeSet
#   2005/02/25 18:18:09-05:00 jgarzik@pobox.com 
#   [libata ahci] support ->tf_read hook
# 
# drivers/scsi/ahci.c
#   2005/02/25 18:18:03-05:00 jgarzik@pobox.com +11 -0
#   [libata ahci] support ->tf_read hook
# 
diff -Nru a/drivers/scsi/ahci.c b/drivers/scsi/ahci.c
--- a/drivers/scsi/ahci.c	2005-02-25 18:18:23 -05:00
+++ b/drivers/scsi/ahci.c	2005-02-25 18:18:23 -05:00
@@ -177,6 +177,7 @@
 static int ahci_port_start(struct ata_port *ap);
 static void ahci_port_stop(struct ata_port *ap);
 static void ahci_host_stop(struct ata_host_set *host_set);
+static void ahci_tf_read(struct ata_port *ap, struct ata_taskfile *tf);
 static void ahci_qc_prep(struct ata_queued_cmd *qc);
 static u8 ahci_check_status(struct ata_port *ap);
 static u8 ahci_check_err(struct ata_port *ap);
@@ -209,6 +210,8 @@
 	.check_err		= ahci_check_err,
 	.dev_select		= ata_noop_dev_select,
 
+	.tf_read		= ahci_tf_read,
+
 	.phy_reset		= ahci_phy_reset,
 
 	.qc_prep		= ahci_qc_prep,
@@ -460,6 +463,14 @@
 	void *mmio = (void *) ap->ioaddr.cmd_addr;
 
 	return (readl(mmio + PORT_TFDATA) >> 8) & 0xFF;
+}
+
+static void ahci_tf_read(struct ata_port *ap, struct ata_taskfile *tf)
+{
+	struct ahci_port_priv *pp = ap->private_data;
+	u8 *d2h_fis = pp->rx_fis + RX_FIS_D2H_REG;
+
+	ata_tf_from_fis(d2h_fis, tf);
 }
 
 static void ahci_fill_sg(struct ata_queued_cmd *qc)

  parent reply	other threads:[~2005-02-25 23:19 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-02-24 23:24 [PATCH libata-2.6] AHCI: support for tf_read (RFC) Brett Russ
2005-02-24 23:33 ` Jeff Garzik
2005-02-25 23:19 ` Jeff Garzik [this message]
2005-03-07 16:43   ` [PATCH] " Brett Russ
2005-03-10 16:50   ` Brett Russ
2005-03-10 18:32     ` Jeff Garzik

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=421FB272.4030502@pobox.com \
    --to=jgarzik@pobox.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=ric@emc.com \
    --cc=russb@emc.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.