Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch/arm/allwinner write to vendor specific dma reg rela...



details:   https://anonhg.NetBSD.org/src/rev/8e635c3287ee
branches:  trunk
changeset: 326975:8e635c3287ee
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Mon Feb 24 15:47:43 2014 +0000

description:
write to vendor specific dma reg relative to the port, not the base. sata works on cubieboard2 now

diffstat:

 sys/arch/arm/allwinner/awin_ahcisata.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (25 lines):

diff -r 7195fa18bb70 -r 8e635c3287ee sys/arch/arm/allwinner/awin_ahcisata.c
--- a/sys/arch/arm/allwinner/awin_ahcisata.c    Mon Feb 24 14:26:11 2014 +0000
+++ b/sys/arch/arm/allwinner/awin_ahcisata.c    Mon Feb 24 15:47:43 2014 +0000
@@ -31,7 +31,7 @@
 
 #include <sys/cdefs.h>
 
-__KERNEL_RCSID(1, "$NetBSD: awin_ahcisata.c,v 1.9 2014/02/24 12:21:27 jmcneill Exp $");
+__KERNEL_RCSID(1, "$NetBSD: awin_ahcisata.c,v 1.10 2014/02/24 15:47:43 jmcneill Exp $");
 
 #include <sys/param.h>
 #include <sys/bus.h>
@@ -171,10 +171,10 @@
 {
        uint32_t dma;
 
-       dma = AHCI_READ(sc, AWIN_AHCI_DMA_REG);
+       dma = AHCI_READ(sc, 0x100 + AHCI_P_OFFSET(chp->ch_channel) + AWIN_AHCI_DMA_REG);
        dma &= ~0xff00;
        dma |= 0x4400;
-       AHCI_WRITE(sc, AWIN_AHCI_DMA_REG, dma);
+       AHCI_WRITE(sc, 0x100 + AHCI_P_OFFSET(chp->ch_channel) + AWIN_AHCI_DMA_REG, dma);
 }
 
 static void



Home | Main Index | Thread Index | Old Index