From owner-freebsd-net@FreeBSD.ORG Sat Jul 14 20:32:46 2007 Return-Path: X-Original-To: freebsd-net@freebsd.org Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 85F4D16A406; Sat, 14 Jul 2007 20:32:46 +0000 (UTC) (envelope-from sam@errno.com) Received: from ebb.errno.com (ebb.errno.com [69.12.149.25]) by mx1.freebsd.org (Postfix) with ESMTP id 2A6E213C4A3; Sat, 14 Jul 2007 20:32:46 +0000 (UTC) (envelope-from sam@errno.com) Received: from trouble.errno.com (trouble.errno.com [10.0.0.248]) (authenticated bits=0) by ebb.errno.com (8.13.6/8.12.6) with ESMTP id l6EK3IcK049070 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sat, 14 Jul 2007 13:03:19 -0700 (PDT) (envelope-from sam@errno.com) Message-ID: <46992C9C.8040308@errno.com> Date: Sat, 14 Jul 2007 13:05:48 -0700 From: Sam Leffler User-Agent: Thunderbird 2.0.0.0 (X11/20070530) MIME-Version: 1.0 To: karels@karels.net References: <200707140327.l6E3RqWA007006@redrock.karels.net> In-Reply-To: <200707140327.l6E3RqWA007006@redrock.karels.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: Bill Moran , Stephen.Clark@seclark.us, Julian Elischer , freebsd-net@freebsd.org, "Bruce M. Simpson" , Sten Daniel Soersdal Subject: Re: 6.2 mtu now limits size of incomming packet 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: Sat, 14 Jul 2007 20:32:46 -0000 Mike Karels wrote: >> In -CURRENT my changes to the ethernet input path maintain the use of >> ETHER_MAX_FRAME() however the check is folded under #ifdef DIAGNOSTIC. I >> don't recall adding this conditional or touching it so it seems to be >> something which was already thereo radded by someone else. > > It has been there at least since 6.0. The issue is that ETHER_MAX_FRAME > is computed using ifp->if_mtu, as opposed to something like ETHER_MAX_LEN. > This is under #ifdef DIAGNOSTIC in -current, not in -stable. > >> Could be pilot error; its use in -CURRENT seems to apply strictly to the >> use of large-receive offload (LRO). > > LRO relaxes the requirement, otherwise LRO packets would never pass the > check. I can't recall if I brought the check in when I moved a lot of common logic out of 802.3 drivers' rx intr handler or if it pre-dated that. I believe the code is shared with netbsd (which I cross-checked when I did that cleanup work). I think removing it is fine. As has been said mtu was never intended to be applied to the rx path. Sam