From owner-freebsd-stable@FreeBSD.ORG Tue Nov 23 19:04:57 2010 Return-Path: Delivered-To: stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id AF0A6106564A for ; Tue, 23 Nov 2010 19:04:57 +0000 (UTC) (envelope-from jfvogel@gmail.com) Received: from mail-gy0-f182.google.com (mail-gy0-f182.google.com [209.85.160.182]) by mx1.freebsd.org (Postfix) with ESMTP id 5C0168FC12 for ; Tue, 23 Nov 2010 19:04:56 +0000 (UTC) Received: by gyf3 with SMTP id 3so285064gyf.13 for ; Tue, 23 Nov 2010 11:04:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type; bh=ee1z7Szz9qKnMJEOrxXgsYqXrxPqiyK6A2hw0pEIA3w=; b=EJlH/Z8nc8zZw+hf/wTLa9WVlASMik1GtWpdF7e0PQXvU8zrUPkxaAoKat0YNMUvc4 HOEfmbNX7C2QF797PIVWXLycR0tVR5s4qVyApnE2BZTbSE6bIhm2hH50bEcBKs9pKueI NLYO4HkppXvde2oH1W0Ta/NLwYqHymYwRddLU= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=Y0ykUGvgmG0eENRTZ9Z69bUWHy7aIchu95TFfXOILao/IAexmgkvnGG5PSNF/2aXMP 8mdCcrs5QZofErgBa74IvCdo66LKNjxWs6x60GovO+S901pw8kNxYvZqCqulJ3Tckr5W XpLCCWsZuyz5TEzw2kuMywtjJ3H+PzF2bYT2A= MIME-Version: 1.0 Received: by 10.216.3.3 with SMTP id 3mr1430896weg.57.1290539092582; Tue, 23 Nov 2010 11:04:52 -0800 (PST) Received: by 10.216.2.206 with HTTP; Tue, 23 Nov 2010 11:04:52 -0800 (PST) In-Reply-To: <20101123175100.V24596@maildrop.int.zabbadoz.net> References: <201010221416.o9MEGSa0094817@lava.sentex.ca> <201010221425.o9MEPcWC094867@lava.sentex.ca> <201010221848.o9MIm7WF096197@lava.sentex.ca> <4CC1F3B8.3010302@bogus.com> <4CC225D3.1030502@ops-netman.net> <7.1.0.9.0.20101022210145.06fe25e8@sentex.net> <201010230159.o9N1xGGF098363@lava.sentex.ca> <201010230821.o9N8LVuR001382@lava.sentex.ca> <20101023091555.W66242@maildrop.int.zabbadoz.net> <20101123175100.V24596@maildrop.int.zabbadoz.net> Date: Tue, 23 Nov 2010 11:04:52 -0800 Message-ID: From: Jack Vogel To: "Bjoern A. Zeeb" Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: Randy Bush , Denis Ahrens , stable@freebsd.org, "George V. Neville-Neil" Subject: Re: repeating crashes with 8.1 X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 23 Nov 2010 19:04:57 -0000 I'm a bit dubious about this, if a descriptor still has an mbuf it was due to a discard, go look at em_rx_discard(), you will notice there that all these things are already being done at that point. So do you have a scenario where we can have an unused mbuf that didn't come thru that path?? Jack On Tue, Nov 23, 2010 at 10:47 AM, Bjoern A. Zeeb < bzeeb-lists@lists.zabbadoz.net> wrote: > On Sat, 23 Oct 2010, Bjoern A. Zeeb wrote: > > Hi, > > just to get this out. Jack you might want to review and if ok, include > in HEAD before we get feedback maybe. To my understanding worst it > would be overhead but not really harm. > > > >>>>> Oct 22 02:06:02 i4 kernel: em1: discard frame w/o packet header >>>> >>>>> Oct 22 02:06:10 i4 kernel: em2: discard frame w/o packet header >>>> >>> > The following is a random-guess by code reading that hasn't been tested > yet but believed to be correct; also ran it by gnn. > > http://people.freebsd.org/~bz/20101122-03-em-pkthdr.diff > > --- sys/dev/e1000/if_em.c.orig 2010-11-01 20:57:53.000000000 -0400 > +++ sys/dev/e1000/if_em.c 2010-11-16 01:28:00.000000000 -0500 > @@ -3754,8 +3769,13 @@ em_refresh_mbufs(struct rx_ring *rxr, in > ** they can only be due to an error > ** and are to be reused. > */ > - if (rxbuf->m_head != NULL) > + if (rxbuf->m_head != NULL) { > + rxbuf->m_head->m_len = rxbuf->m_head->m_pkthdr.len > = adapter->rx_mbuf_sz; > + rxbuf->m_head->m_flags |= M_PKTHDR; > + rxbuf->m_head->m_data = > rxbuf->m_head->m_ext.ext_buf; > + rxbuf->m_head->m_next = NULL; > goto reuse; > + } > m = m_getjcl(M_DONTWAIT, MT_DATA, > M_PKTHDR, adapter->rx_mbuf_sz); > /* > > I am not sure if igb and the others need a similar fix. Haven't > looked in detail. gnn mentioned similarities though good ones imho > in there. > > If you were able to reproduce the pkthdr issue it would be great to > test it. If you always paniced it with IPv6 you may also want to test > the applicable patch (use the direct URLs mentioned) from the very end of > http://www.freebsd.org/cgi/query-pr.cgi?pr=kern/148857 > to make sure you are not running into that race. > > > /bz > > -- > Bjoern A. Zeeb Welcome a new stage of life. > Going to jail sucks -- All my daemons like it! > http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/jails.html >