From owner-freebsd-arch Sun Oct 13 11: 9:24 2002 Delivered-To: freebsd-arch@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1187C37B401 for ; Sun, 13 Oct 2002 11:09:23 -0700 (PDT) Received: from harmony.village.org (rover.bsdimp.com [204.144.255.66]) by mx1.FreeBSD.org (Postfix) with ESMTP id 339A143E7B for ; Sun, 13 Oct 2002 11:09:22 -0700 (PDT) (envelope-from imp@bsdimp.com) Received: from localhost (warner@rover2.village.org [10.0.0.1]) by harmony.village.org (8.12.3/8.12.3) with ESMTP id g9DI9Dpk014384; Sun, 13 Oct 2002 12:09:13 -0600 (MDT) (envelope-from imp@bsdimp.com) Date: Sun, 13 Oct 2002 12:08:47 -0600 (MDT) Message-Id: <20021013.120847.31902907.imp@bsdimp.com> To: tlambert2@mindspring.com Cc: ticso@cicely.de, hch@infradead.org, wes@softweyr.com, dillon@apollo.backplane.com, vova@sw.ru, nate@root.org, arch@FreeBSD.org Subject: Re: Database indexes and ram From: "M. Warner Losh" In-Reply-To: <3DA9B4A8.194A02FC@mindspring.com> References: <3DA954CF.98B0891A@mindspring.com> <20021013.060851.113437955.imp@bsdimp.com> <3DA9B4A8.194A02FC@mindspring.com> X-Mailer: Mew version 2.1 on Emacs 21.2 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG In message: <3DA9B4A8.194A02FC@mindspring.com> Terry Lambert writes: : "M. Warner Losh" wrote: : > In message: <3DA954CF.98B0891A@mindspring.com> : > Terry Lambert writes: : > : In most cases, the DMA gets put directly into memory mapped by the : > : VM of the kernel (the KVA). : > : > Actually, in most cases on i386 the memory gets DMAd to a phyiscal : > address, which is why there is a 4G limit in the hardware. Since it : > is a phyiscal address, knowing VM tricks I don't think is relevant. : > PAE is basically a vm trick. : : You've taken the argument out of context. The argument is about: : : 1) The interrupt handler for the completed DMA : : 2) The fact that most data which is DMA'ed ends up being shared : between multiple processes : : 3) The fact that the VM and buffer cache are unified, so that : even if you wanted to do explicit coherency between multiple : copies of DMA'ed data, you would not be able to, unless they : occurred into a region which was not replicated, which means : one which was shared, which means "in the KVA", which means : "not in the bank selected PAE/PSE-36 window". I think that's all irrelevant. Cards with 32bits can't go about 4GB. It is a far more fundamental problem. Even 32bit cards in 64bit slots can't do this. 64bit cards could DMA into anywhere in the first 64bits of RAM, of course. However, you are at least partially right about what you say, I think. When DMAing into high memory, you'd still have to arrange for those physical pages to be in the process that you are talking about (because each process still has a 4G size limit, and I think it has to be all in the same segment unless it is PAE/PSE aware). I was confusing what you said with "The DMA is based on a virtual address" which is not quite the same thing. Warner To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message