From owner-freebsd-multimedia@FreeBSD.ORG Thu Aug 4 07:37:03 2005 Return-Path: X-Original-To: freebsd-multimedia@freebsd.org Delivered-To: freebsd-multimedia@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 02E7716A41F for ; Thu, 4 Aug 2005 07:37:03 +0000 (GMT) (envelope-from yuka.muromachi@gmail.com) Received: from zproxy.gmail.com (zproxy.gmail.com [64.233.162.196]) by mx1.FreeBSD.org (Postfix) with ESMTP id 97EED43D45 for ; Thu, 4 Aug 2005 07:37:02 +0000 (GMT) (envelope-from yuka.muromachi@gmail.com) Received: by zproxy.gmail.com with SMTP id z6so184550nzd for ; Thu, 04 Aug 2005 00:37:02 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=p3pwUOlyKvqobTizXKEj1wg4p3W0jxGt1iyxKQign/ndDSsguZJmB9a3kucpXE22ecYPzZvR3VYx6kOg4pbHIG2yswbc8Laph6lh5k4nTDra56lg6Ys09zBOHTfkX4qYVvkTXWLcbKRWuReyFxTOvt+ZCi0Z8ogGVpGBDEd27qw= Received: by 10.36.252.56 with SMTP id z56mr787836nzh; Thu, 04 Aug 2005 00:37:02 -0700 (PDT) Received: by 10.36.221.16 with HTTP; Thu, 4 Aug 2005 00:37:01 -0700 (PDT) Message-ID: Date: Thu, 4 Aug 2005 15:37:02 +0800 From: Yuka Muromachi To: freebsd-multimedia@freebsd.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Subject: How alloc non-cache type memory? X-BeenThere: freebsd-multimedia@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Yuka Muromachi List-Id: Multimedia discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 04 Aug 2005 07:37:03 -0000 I meet some problem with nvidia chip, the dma buffer data seems incorrect. Windows NT can use MmAllocatePagesForMdl() to allocate nonpaged physical memory and use MmMapLockedPagesSpecifyCache() map to kernel speace. MmMapLockedPagesSpecifyCache() also can set page cachetype to MmNonCached. Then use MmGetPhysicalAddress() to get physical address fill to DMA address register. If I set cache type to MmNonCached, it will work.=20 Is there any way to allocate Non-Cached type physical memory for dma transfer in FreeBSD?