From owner-svn-src-head@FreeBSD.ORG Mon Aug 19 10:30:16 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id AB32A2AE; Mon, 19 Aug 2013 10:30:16 +0000 (UTC) (envelope-from andre@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 98C1F2263; Mon, 19 Aug 2013 10:30:16 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r7JAUG6O024867; Mon, 19 Aug 2013 10:30:16 GMT (envelope-from andre@svn.freebsd.org) Received: (from andre@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r7JAUGR6024866; Mon, 19 Aug 2013 10:30:16 GMT (envelope-from andre@svn.freebsd.org) Message-Id: <201308191030.r7JAUGR6024866@svn.freebsd.org> From: Andre Oppermann Date: Mon, 19 Aug 2013 10:30:16 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r254517 - head/sys/netinet X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 19 Aug 2013 10:30:16 -0000 Author: andre Date: Mon Aug 19 10:30:15 2013 New Revision: 254517 URL: http://svnweb.freebsd.org/changeset/base/254517 Log: Remove unused M_FRAG, M_FIRSTFRAG and M_LASTFRAG tagging from ip_fragment(). There wasn't any real driver (and hardware) support for it. Modern hardware does full fragmentation/segmentation offload instead. Modified: head/sys/netinet/ip_output.c Modified: head/sys/netinet/ip_output.c ============================================================================== --- head/sys/netinet/ip_output.c Mon Aug 19 10:20:20 2013 (r254516) +++ head/sys/netinet/ip_output.c Mon Aug 19 10:30:15 2013 (r254517) @@ -784,7 +784,7 @@ smart_frag_failure: IPSTAT_INC(ips_odropped); goto done; } - m->m_flags |= (m0->m_flags & M_MCAST) | M_FRAG; + m->m_flags |= (m0->m_flags & M_MCAST); /* * In the first mbuf, leave room for the link header, then * copy the original IP header including options. The payload @@ -801,10 +801,9 @@ smart_frag_failure: m->m_len = mhlen; /* XXX do we need to add ip_off below ? */ mhip->ip_off = ((off - hlen) >> 3) + ip_off; - if (off + len >= ip_len) { /* last fragment */ + if (off + len >= ip_len) len = ip_len - off; - m->m_flags |= M_LASTFRAG; - } else + else mhip->ip_off |= IP_MF; mhip->ip_len = htons((u_short)(len + mhlen)); m->m_next = m_copym(m0, off, len, M_NOWAIT); @@ -831,10 +830,6 @@ smart_frag_failure: } IPSTAT_ADD(ips_ofragments, nfrags); - /* set first marker for fragment chain */ - m0->m_flags |= M_FIRSTFRAG | M_FRAG; - m0->m_pkthdr.csum_data = nfrags; - /* * Update first fragment by trimming what's been copied out * and updating header.