From owner-freebsd-net@FreeBSD.ORG Fri Nov 26 20:42:47 2010 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 62BCA106566C for ; Fri, 26 Nov 2010 20:42:47 +0000 (UTC) (envelope-from rysto32@gmail.com) Received: from mail-ey0-f182.google.com (mail-ey0-f182.google.com [209.85.215.182]) by mx1.freebsd.org (Postfix) with ESMTP id E68338FC15 for ; Fri, 26 Nov 2010 20:42:46 +0000 (UTC) Received: by eyb7 with SMTP id 7so1156655eyb.13 for ; Fri, 26 Nov 2010 12:42:45 -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=J/5uKnWbeNTgNcAyuruM5qDOblM8IWbaAlt7W3nSKLY=; b=oulhU3wAJCUrC0bhITFeITT8JjpgoU2Ek9UOykR4g32BKP1VpoLFzVGd3kp9EDYIAD 5GAvHo6p9ev26FjxmHGn6yAy0FLxijPW/7DD2QAI9PdyWCjIka8MMeBLW/3vF1h7c9sa nqTkJjM0W/IUfQhtlj3PaDDI3JmSvSqsJ/vP0= 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=t/AQVUfRQ0on86Gur+lw8nkkhL8ZY660YdZnqKUMeDfXW20tcQNx5ZBJ5vG/lYl+9v i+Un+Pmy2CzWH3Xz/Kt+6ajk/jWJLlqq+l36HkBg6ygYRqm7Wf5eme/ByPSgWuDMrsCi Y9C3byZRX2N7q6KqPp4cbJ4xiEZ6Y7WdrNJMQ= MIME-Version: 1.0 Received: by 10.213.8.146 with SMTP id h18mr6944464ebh.87.1290804165665; Fri, 26 Nov 2010 12:42:45 -0800 (PST) Received: by 10.213.14.138 with HTTP; Fri, 26 Nov 2010 12:42:45 -0800 (PST) In-Reply-To: References: <201011261037105152721@yahoo.com.cn> Date: Fri, 26 Nov 2010 15:42:45 -0500 Message-ID: From: Ryan Stone To: Jack Vogel Content-Type: text/plain; charset=ISO-8859-1 Cc: beezarliu , freebsd-net Subject: Re: 82599 receiving packets with vlan tag=0 (vlan strip problem)? 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: Fri, 26 Nov 2010 20:42:47 -0000 If vlan stripping is disabled on the 82599(i.e. RXDCTL.VME is 0 for that queue is clear) and a vlan-tagged packet is received, then the descriptor for that packet will have the VP bit set even though the vlan was not stripped, and the VLAN Tag field in the descriptor is set to 0. ixgbe_rxeof will see that the VP bit is set and set the M_VLANTAG on the mbuf, and put 0 in m_pkthdr.ether_vtag. This means that the stack will treat the packet as if it was double vlan tagged, with outer tag being 0. Ryan Stone