From owner-p4-projects@FreeBSD.ORG Mon Sep 17 16:48:21 2007 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 115AB16A469; Mon, 17 Sep 2007 16:48:21 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D6C7E16A41A; Mon, 17 Sep 2007 16:48:20 +0000 (UTC) (envelope-from hselasky@c2i.net) Received: from swip.net (mailfe05.swip.net [212.247.154.129]) by mx1.freebsd.org (Postfix) with ESMTP id 554D913C491; Mon, 17 Sep 2007 16:48:19 +0000 (UTC) (envelope-from hselasky@c2i.net) X-Cloudmark-Score: 0.000000 [] Received: from [194.248.135.20] (account mc467741@c2i.net HELO [192.168.2.105]) by mailfe05.swip.net (CommuniGate Pro SMTP 5.1.10) with ESMTPA id 515923220; Mon, 17 Sep 2007 17:48:17 +0200 From: Hans Petter Selasky To: Kip Macy Date: Mon, 17 Sep 2007 17:48:36 +0200 User-Agent: KMail/1.9.7 References: <200709152326.l8FNQwPq024216@repoman.freebsd.org> In-Reply-To: <200709152326.l8FNQwPq024216@repoman.freebsd.org> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200709171748.36573.hselasky@c2i.net> Cc: Perforce Change Reviews Subject: Re: PERFORCE change 126455 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 17 Sep 2007 16:48:21 -0000 On Sunday 16 September 2007, Kip Macy wrote: > http://perforce.freebsd.org/chv.cgi?CH=126455 > > Change 126455 by kmacy@kmacy_home:ethng on 2007/09/15 23:26:15 > > skip busdma rx setup on x86 > increases rx throughput by about 15% on udp netperf recv Really this should be done for all platforms. The mbuf m_data field should have a companion pointer for example m_databuffer of type "struct usbd_page_chache *" : struct usbd_page_cache { struct usbd_page *page_start; struct usbd_page *page_end; struct usbd_page *page_cur; uint32_t page_offset_buf; uint32_t page_offset_cur; }; struct usbd_page { void *buffer; bus_size_t physaddr; #ifdef __FreeBSD__ bus_dma_tag_t tag; bus_dmamap_t map; register_t intr_temp; #endif #ifdef __NetBSD__ bus_dma_tag_t tag; bus_dmamap_t map; bus_dma_segment_t seg; register_t intr_temp; int32_t seg_count; #endif uint32_t length; }; Then based on the "tag" and "map" from the structures pointed to by "m_databuffer" you perform a flush/invalidate before setting up DMA. What do you think Kip ? --HPS