From owner-svn-src-stable-8@FreeBSD.ORG Fri Mar 25 12:53:09 2011 Return-Path: Delivered-To: svn-src-stable-8@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C53D6106566B; Fri, 25 Mar 2011 12:53:09 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B34788FC20; Fri, 25 Mar 2011 12:53:09 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p2PCr9X4081881; Fri, 25 Mar 2011 12:53:09 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p2PCr9ZY081879; Fri, 25 Mar 2011 12:53:09 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201103251253.p2PCr9ZY081879@svn.freebsd.org> From: Marius Strobl Date: Fri, 25 Mar 2011 12:53:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r219995 - stable/8/sys/dev/sound/pcm X-BeenThere: svn-src-stable-8@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 8-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Mar 2011 12:53:09 -0000 Author: marius Date: Fri Mar 25 12:53:09 2011 New Revision: 219995 URL: http://svn.freebsd.org/changeset/base/219995 Log: MFC: r219548 Allocate the sound buffer DMA memory coherent. While NetBSD typically also does this for sound drivers it's probably not necessary for all combinations of controllers and drivers. However, given that our sound drivers completely lack bus_dmamap_sync(9) calls this at least serves as a workaround when enabling use of the IOMMU streaming buffers on sparc64 and generally for arm and mips. Modified: stable/8/sys/dev/sound/pcm/buffer.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) Modified: stable/8/sys/dev/sound/pcm/buffer.c ============================================================================== --- stable/8/sys/dev/sound/pcm/buffer.c Fri Mar 25 12:50:50 2011 (r219994) +++ stable/8/sys/dev/sound/pcm/buffer.c Fri Mar 25 12:53:09 2011 (r219995) @@ -93,7 +93,7 @@ sndbuf_alloc(struct snd_dbuf *b, bus_dma int ret; b->dmatag = dmatag; - b->dmaflags = dmaflags | BUS_DMA_NOWAIT; + b->dmaflags = dmaflags | BUS_DMA_NOWAIT | BUS_DMA_COHERENT; b->maxsize = size; b->bufsize = b->maxsize; b->buf_addr = 0;