From owner-freebsd-current Sat Jan 18 6: 2:46 2003 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7976F37B401 for ; Sat, 18 Jan 2003 06:02:45 -0800 (PST) Received: from duke.cs.duke.edu (duke.cs.duke.edu [152.3.140.1]) by mx1.FreeBSD.org (Postfix) with ESMTP id C4F3A43EB2 for ; Sat, 18 Jan 2003 06:02:44 -0800 (PST) (envelope-from gallatin@cs.duke.edu) Received: from grasshopper.cs.duke.edu (grasshopper.cs.duke.edu [152.3.145.30]) by duke.cs.duke.edu (8.12.6/8.12.6) with ESMTP id h0IE2dro027099 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO) for ; Sat, 18 Jan 2003 09:02:39 -0500 (EST) Received: (from gallatin@localhost) by grasshopper.cs.duke.edu (8.11.6/8.9.1) id h0IE2YA83227; Sat, 18 Jan 2003 09:02:34 -0500 (EST) (envelope-from gallatin@cs.duke.edu) From: Andrew Gallatin MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-ID: <15913.24185.962327.437269@grasshopper.cs.duke.edu> Date: Sat, 18 Jan 2003 09:02:33 -0500 (EST) To: freebsd-current@freebsd.org Subject: which is preferred: vm_page_hold() or vm_map_wire()? X-Mailer: VM 6.75 under 21.1 (patch 12) "Channel Islands" XEmacs Lucid Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG I'm re-examining some of our driver code where we need to wire down a portion of a user's address space for DMA for os-bypass networking. We currently do vm_map_wire(). This is nice, as it presents a simple interface, but I think its pretty high overhead the way our driver calls it (a page at a time). Since this should be a short-lived mapping, I assume we could also get away with using vm_page_hold() like vmapbuf() does? Note that I don't want all of vmapbuf, as I don't want to waste kva space by mapping the page into the kernel... I just need to dma it, not read or write it. Which is the preferred api for somebody like me? Thanks, Drew To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message