From owner-svn-src-stable@FreeBSD.ORG Thu May 7 01:14:59 2009 Return-Path: Delivered-To: svn-src-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8A229106566C; Thu, 7 May 2009 01:14:59 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 770B48FC18; Thu, 7 May 2009 01:14:59 +0000 (UTC) (envelope-from yongari@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id n471ExG6035632; Thu, 7 May 2009 01:14:59 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n471Exp3035631; Thu, 7 May 2009 01:14:59 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <200905070114.n471Exp3035631@svn.freebsd.org> From: Pyun YongHyeon Date: Thu, 7 May 2009 01:14:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r191867 - in stable/7/sys: . contrib/pf dev/ath/ath_hal dev/cxgb dev/fxp X-BeenThere: svn-src-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for all the -stable branches of the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 07 May 2009 01:15:00 -0000 Author: yongari Date: Thu May 7 01:14:59 2009 New Revision: 191867 URL: http://svn.freebsd.org/changeset/base/191867 Log: MFC r190982: Don't blindly set IP packet length from interface MTU in TSO case. Remote host can advertise smaller MSS than that of sender so upper stack might have adjusted the MSS which in turn generates IP packets that are less size than that of interface MTU. Reported by: Bjoern Koenig ( bkoenig <> alpha-tierchen dot de ) Modified: stable/7/sys/ (props changed) stable/7/sys/contrib/pf/ (props changed) stable/7/sys/dev/ath/ath_hal/ (props changed) stable/7/sys/dev/cxgb/ (props changed) stable/7/sys/dev/fxp/if_fxp.c Modified: stable/7/sys/dev/fxp/if_fxp.c ============================================================================== --- stable/7/sys/dev/fxp/if_fxp.c Thu May 7 00:35:32 2009 (r191866) +++ stable/7/sys/dev/fxp/if_fxp.c Thu May 7 01:14:59 2009 (r191867) @@ -1486,7 +1486,8 @@ fxp_encap(struct fxp_softc *sc, struct m * checksum in the first frame driver should compute it. */ ip->ip_sum = 0; - ip->ip_len = htons(ifp->if_mtu); + ip->ip_len = htons(m->m_pkthdr.tso_segsz + (ip->ip_hl << 2) + + (tcp->th_off << 2)); tcp->th_sum = in_pseudo(ip->ip_src.s_addr, ip->ip_dst.s_addr, htons(IPPROTO_TCP + (tcp->th_off << 2) + m->m_pkthdr.tso_segsz));