linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Marc C <marc.ceeeee@gmail.com>
To: tj@kernel.org, linux-ide@vger.kernel.org
Cc: Marc Carino <marc.ceeeee@gmail.com>
Subject: [PATCH v5 2/4] libata: Add H2D FIS "auxiliary" port flag
Date: Sat, 24 Aug 2013 23:22:49 -0700	[thread overview]
Message-ID: <1377411771-3733-3-git-send-email-marc.ceeeee@gmail.com> (raw)
In-Reply-To: <1377411771-3733-1-git-send-email-marc.ceeeee@gmail.com>

From: Marc Carino <marc.ceeeee@gmail.com>

Add a new port flag, ATA_FLAG_FPDMA_AUX, used to indicate
support for transmission of the H2D FIS 'auxiliary' field.

Signed-off-by: Marc Carino <marc.ceeeee@gmail.com>
---
 drivers/ata/ahci.c     | 8 ++++++++
 include/linux/libata.h | 1 +
 2 files changed, 9 insertions(+)

diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c
index 5064f3e..8d41c57 100644
--- a/drivers/ata/ahci.c
+++ b/drivers/ata/ahci.c
@@ -1288,6 +1288,14 @@ static int ahci_init_one(struct pci_dev *pdev, const struct pci_device_id *ent)
 		 */
 		if (!(hpriv->flags & AHCI_HFLAG_NO_FPDMA_AA))
 			pi.flags |= ATA_FLAG_FPDMA_AA;
+
+		/*
+		 * All AHCI controllers should be forward-compatible
+		 * with the new auxiliary field. This code should be
+		 * conditionalized if any buggy AHCI controllers are
+		 * encountered.
+		 */
+		pi.flags |= ATA_FLAG_FPDMA_AUX;
 	}
 
 	if (hpriv->cap & HOST_CAP_PMP)
diff --git a/include/linux/libata.h b/include/linux/libata.h
index 47122f4..6539c50 100644
--- a/include/linux/libata.h
+++ b/include/linux/libata.h
@@ -223,6 +223,7 @@ enum {
 	ATA_FLAG_ACPI_SATA	= (1 << 17), /* need native SATA ACPI layout */
 	ATA_FLAG_AN		= (1 << 18), /* controller supports AN */
 	ATA_FLAG_PMP		= (1 << 19), /* controller supports PMP */
+	ATA_FLAG_FPDMA_AUX	= (1 << 20), /* controller supports H2DFIS aux field */
 	ATA_FLAG_EM		= (1 << 21), /* driver supports enclosure
 					      * management */
 	ATA_FLAG_SW_ACTIVITY	= (1 << 22), /* driver supports sw activity
-- 
1.8.1.2


  parent reply	other threads:[~2013-08-25  6:23 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-25  6:22 [PATCH v5 0/4] Introduce new SATA queued commands Marc C
2013-08-25  6:22 ` [PATCH v5 1/4] libata: Populate host-to-device FIS "auxiliary" field Marc C
2013-08-25  6:22 ` Marc C [this message]
2013-08-25  6:22 ` [PATCH v5 3/4] libata: Add support for SEND/RECEIVE FPDMA QUEUED Marc C
2013-08-25  6:22 ` [PATCH v5 4/4] libata: Add support for queued DSM TRIM Marc C
2013-08-25 13:40 ` [PATCH v5 0/4] Introduce new SATA queued commands Tejun Heo

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=1377411771-3733-3-git-send-email-marc.ceeeee@gmail.com \
    --to=marc.ceeeee@gmail.com \
    --cc=linux-ide@vger.kernel.org \
    --cc=tj@kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).