linux-mips
[Top] [All Lists]

[PATCH V2 11/16] ata: Use 32-bit DMA in AHCI for Loongson-3.

To: Ralf Baechle <ralf@linux-mips.org>
Subject: [PATCH V2 11/16] ata: Use 32-bit DMA in AHCI for Loongson-3.
From: Huacai Chen <chenhuacai@gmail.com>
Date: Tue, 19 Jun 2012 14:50:19 +0800
Cc: linux-mips@linux-mips.org, Fuxin Zhang <zhangfx@lemote.com>, Zhangjin Wu <wuzhangjin@gmail.com>, Huacai Chen <chenhc@lemote.com>, Hongliang Tao <taohl@lemote.com>, Hua Yan <yanh@lemote.com>, linux-ide@vger.kernel.org
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references; bh=a31830jXnnt13N19MjJvevkkwwauZ7koV5Gic6FXk84=; b=00bZKadi7X0Dvrmf2aSLY2Eti1HMhCEt/FulPEIoBHgLb6duHER3AkB+PjYLssLgQt dH2in7UrVSs/nr0TX6s10PoEsHZ4nXbx4XWESas0I0/kzaOrHVhZp0znoyUE8h2NQ5lG BnB9R5O8Q/v3/p//GZeGmFGdy9vnwEwyvwp1bXpf5qNb+gleC3pHiMXmun5/Mea2cUSG L8QIzMAervww0bWs1UTZdsf3/G1KGV2XIQyGOElggVad7Oh3J9llR7G7SgC2ai1Ych8P s52lo5dc0wr8CpJrylRGcJZJto/YAMmvah5FW/bFuN5WCKGSsatd3nd7qPIIw7ZgS8eS ih+w==
In-reply-to: <1340088624-25550-1-git-send-email-chenhc@lemote.com>
List-archive: <http://www.linux-mips.org/archives/linux-mips/>
List-help: <mailto:ecartis@linux-mips.org?Subject=help>
List-id: linux-mips <linux-mips.eddie.linux-mips.org>
List-owner: <mailto:ralf@linux-mips.org>
List-post: <mailto:linux-mips@linux-mips.org>
List-software: Ecartis version 1.0.0
List-subscribe: <mailto:ecartis@linux-mips.org?subject=subscribe%20linux-mips>
List-unsubscribe: <mailto:ecartis@linux-mips.org?subject=unsubscribe%20linux-mips>
References: <1340088624-25550-1-git-send-email-chenhc@lemote.com>
Sender: linux-mips-bounce@linux-mips.org
This is a workaround because Loongson-3 has a hardware bug that it
doesn't support DMA address above 4GB.

Signed-off-by: Huacai Chen <chenhc@lemote.com>
Signed-off-by: Hongliang Tao <taohl@lemote.com>
Signed-off-by: Hua Yan <yanh@lemote.com>
Cc: linux-ide@vger.kernel.org
---
 drivers/ata/ahci.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c
index ebaf67e..3e3cfd8 100644
--- a/drivers/ata/ahci.c
+++ b/drivers/ata/ahci.c
@@ -183,7 +183,12 @@ static const struct ata_port_info ahci_port_info[] = {
        },
        [board_ahci_sb700] =    /* for SB700 and SB800 */
        {
+#ifndef CONFIG_CPU_LOONGSON3
                AHCI_HFLAGS     (AHCI_HFLAG_IGN_SERR_INTERNAL),
+#else
+               AHCI_HFLAGS     (AHCI_HFLAG_IGN_SERR_INTERNAL |
+                                               AHCI_HFLAG_32BIT_ONLY),
+#endif
                .flags          = AHCI_FLAG_COMMON,
                .pio_mask       = ATA_PIO4,
                .udma_mask      = ATA_UDMA6,
-- 
1.7.7.3


<Prev in Thread] Current Thread [Next in Thread>