Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/arm/xscale Don't write DMAC_DINT register on PXA270...



details:   https://anonhg.NetBSD.org/src/rev/b7ce955fbcb0
branches:  trunk
changeset: 335985:b7ce955fbcb0
user:      nonaka <nonaka%NetBSD.org@localhost>
date:      Thu Feb 05 13:27:18 2015 +0000

description:
Don't write DMAC_DINT register on PXA270, because read-only register.

diffstat:

 sys/arch/arm/xscale/pxa2x0_dmac.c |  10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diffs (31 lines):

diff -r 6cd8115ef03b -r b7ce955fbcb0 sys/arch/arm/xscale/pxa2x0_dmac.c
--- a/sys/arch/arm/xscale/pxa2x0_dmac.c Thu Feb 05 12:23:27 2015 +0000
+++ b/sys/arch/arm/xscale/pxa2x0_dmac.c Thu Feb 05 13:27:18 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: pxa2x0_dmac.c,v 1.12 2012/11/12 18:00:38 skrll Exp $   */
+/*     $NetBSD: pxa2x0_dmac.c,v 1.13 2015/02/05 13:27:18 nonaka Exp $  */
 
 /*
  * Copyright (c) 2003, 2005 Wasabi Systems, Inc.
@@ -321,8 +321,9 @@
                dmac_reg_write(sc, DMAC_DRCMR(i), 0);
                sc->sc_active[i] = NULL;
        }
-       dmac_reg_write(sc, DMAC_DINT,
-           dmac_reg_read(sc, DMAC_DINT) & DMAC_DINT_MASK);
+       if (!CPU_IS_PXA270)
+               dmac_reg_write(sc, DMAC_DINT,
+                   dmac_reg_read(sc, DMAC_DINT) & DMAC_DINT_MASK);
 
        /*
         * Initialise the request queues
@@ -1212,7 +1213,8 @@
        /*
         * Clear down the interrupt in the DMA Interrupt Register
         */
-       dmac_reg_write(sc, DMAC_DINT, (1u << channel));
+       if (!CPU_IS_PXA270)
+               dmac_reg_write(sc, DMAC_DINT, (1u << channel));
 
        /*
         * If this is a looping request, invoke the 'done' callback and



Home | Main Index | Thread Index | Old Index