From owner-svn-src-all@FreeBSD.ORG Mon Feb 9 02:06:15 2009 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 94A9C1065672; Mon, 9 Feb 2009 02:06:15 +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 814818FC18; Mon, 9 Feb 2009 02:06:15 +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 n1926Foh041602; Mon, 9 Feb 2009 02:06:15 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n1926Fgg041601; Mon, 9 Feb 2009 02:06:15 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <200902090206.n1926Fgg041601@svn.freebsd.org> From: Pyun YongHyeon Date: Mon, 9 Feb 2009 02:06:15 +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: r188363 - in stable/7/sys: . contrib/pf dev/ath/ath_hal dev/cxgb dev/msk X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 09 Feb 2009 02:06:16 -0000 Author: yongari Date: Mon Feb 9 02:06:15 2009 New Revision: 188363 URL: http://svn.freebsd.org/changeset/base/188363 Log: MFC r187207: Correct frame length argument of in_cksum_skip. While I'm here remove intermediate variable csum. 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/msk/if_msk.c Modified: stable/7/sys/dev/msk/if_msk.c ============================================================================== --- stable/7/sys/dev/msk/if_msk.c Mon Feb 9 02:03:49 2009 (r188362) +++ stable/7/sys/dev/msk/if_msk.c Mon Feb 9 02:06:15 2009 (r188363) @@ -2608,17 +2608,14 @@ msk_encap(struct msk_if_softc *sc_if, st */ if (m->m_pkthdr.len < MSK_MIN_FRAMELEN && (m->m_pkthdr.csum_flags & CSUM_TCP) != 0) { - uint16_t csum; - m = m_pullup(m, offset + sizeof(struct tcphdr)); if (m == NULL) { *m_head = NULL; return (ENOBUFS); } - csum = in_cksum_skip(m, ntohs(ip->ip_len) + offset - - (ip->ip_hl << 2), offset); *(uint16_t *)(m->m_data + offset + - m->m_pkthdr.csum_data) = csum; + m->m_pkthdr.csum_data) = in_cksum_skip(m, + m->m_pkthdr.len, offset); m->m_pkthdr.csum_flags &= ~CSUM_TCP; } if ((m->m_pkthdr.csum_flags & CSUM_TSO) != 0) {