Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/ic bus_space_write_multi_4 takes a count, not number...



details:   https://anonhg.NetBSD.org/src/rev/96cebef2a956
branches:  trunk
changeset: 824532:96cebef2a956
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Thu Jun 08 11:05:16 2017 +0000

description:
bus_space_write_multi_4 takes a count, not number of bytes. With this,
audio works in qemu.

diffstat:

 sys/dev/ic/pl041.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r 02aea92f210b -r 96cebef2a956 sys/dev/ic/pl041.c
--- a/sys/dev/ic/pl041.c        Thu Jun 08 10:40:38 2017 +0000
+++ b/sys/dev/ic/pl041.c        Thu Jun 08 11:05:16 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: pl041.c,v 1.2 2017/06/08 10:40:13 jmcneill Exp $ */
+/* $NetBSD: pl041.c,v 1.3 2017/06/08 11:05:16 jmcneill Exp $ */
 
 /*-
  * Copyright (c) 2017 Jared McNeill <jmcneill%invisible.ca@localhost>
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pl041.c,v 1.2 2017/06/08 10:40:13 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pl041.c,v 1.3 2017/06/08 11:05:16 jmcneill Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -109,7 +109,7 @@
                const int len = min(AACI_FIFO_DEPTH / 2, min(sc->sc_pblkresid,
                    (uintptr_t)sc->sc_pend - (uintptr_t)sc->sc_pcur));
                KASSERT((len & 3) == 0);
-               AACI_WRITE_MULTI(sc, AACIDR, sc->sc_pcur, len);
+               AACI_WRITE_MULTI(sc, AACIDR, sc->sc_pcur, len >> 2);
                sc->sc_pcur += (len >> 2);
                if (sc->sc_pcur == sc->sc_pend)
                        sc->sc_pcur = sc->sc_pstart;



Home | Main Index | Thread Index | Old Index