From owner-freebsd-net@FreeBSD.ORG Tue Apr 7 20:12:04 2009 Return-Path: Delivered-To: net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F0E48106566B for ; Tue, 7 Apr 2009 20:12:04 +0000 (UTC) (envelope-from wollman@hergotha.csail.mit.edu) Received: from hergotha.csail.mit.edu (hergotha.csail.mit.edu [66.92.79.170]) by mx1.freebsd.org (Postfix) with ESMTP id A13A38FC14 for ; Tue, 7 Apr 2009 20:12:04 +0000 (UTC) (envelope-from wollman@hergotha.csail.mit.edu) Received: from hergotha.csail.mit.edu (localhost [127.0.0.1]) by hergotha.csail.mit.edu (8.14.2/8.14.2) with ESMTP id n37KC3Wb050335; Tue, 7 Apr 2009 16:12:03 -0400 (EDT) (envelope-from wollman@hergotha.csail.mit.edu) Received: (from wollman@localhost) by hergotha.csail.mit.edu (8.14.2/8.13.8/Submit) id n37KC3lA050334; Tue, 7 Apr 2009 16:12:03 -0400 (EDT) (envelope-from wollman) Date: Tue, 7 Apr 2009 16:12:03 -0400 (EDT) From: Garrett Wollman Message-Id: <200904072012.n37KC3lA050334@hergotha.csail.mit.edu> To: rwatson@freebsd.org X-Newsgroups: mit.lcs.mail.freebsd-net In-Reply-To: References: Organization: None X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (hergotha.csail.mit.edu [127.0.0.1]); Tue, 07 Apr 2009 16:12:03 -0400 (EDT) X-Spam-Status: No, score=-1.4 required=5.0 tests=ALL_TRUSTED autolearn=disabled version=3.2.5 X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on hergotha.csail.mit.edu Cc: net@freebsd.org Subject: Re: Advice on a multithreaded netisr patch? X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 07 Apr 2009 20:12:05 -0000 In article , Robert Watson writes: >m_pullup() has to do with mbuf chain memory contiguity during packet >processing. Historically, m_pullup() also had one other extremely important function: to make sure that the header data you were about to modify was not stored in a (possibly shared) cluster. Thus, in the input path for a typical driver which puts the whole packet into a cluster, the very first m_pullup() would allocate a new plain mbuf, carefully align the data pointer to allow for both prepending more headers and pulling more header data out, and copy the requested data into the internal buffer of the mbuf. -GAWollman