From owner-svn-src-stable-9@FreeBSD.ORG Fri May 16 05:06:47 2014 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 5A54CABA; Fri, 16 May 2014 05:06:47 +0000 (UTC) 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)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4762127CF; Fri, 16 May 2014 05:06:47 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s4G56l2L020842; Fri, 16 May 2014 05:06:47 GMT (envelope-from yongari@svn.freebsd.org) Received: (from yongari@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s4G56lOi020841; Fri, 16 May 2014 05:06:47 GMT (envelope-from yongari@svn.freebsd.org) Message-Id: <201405160506.s4G56lOi020841@svn.freebsd.org> From: Pyun YongHyeon Date: Fri, 16 May 2014 05:06:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org Subject: svn commit: r266211 - stable/9/sys/netinet X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 May 2014 05:06:47 -0000 Author: yongari Date: Fri May 16 05:06:46 2014 New Revision: 266211 URL: http://svnweb.freebsd.org/changeset/base/266211 Log: MFC r265942: Fix checksum computation. Previously it didn't include carry. Modified: stable/9/sys/netinet/ip_input.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/netinet/ip_input.c ============================================================================== --- stable/9/sys/netinet/ip_input.c Fri May 16 05:05:53 2014 (r266210) +++ stable/9/sys/netinet/ip_input.c Fri May 16 05:06:46 2014 (r266211) @@ -1108,8 +1108,9 @@ found: * (and not in for{} loop), though it implies we are not going to * reassemble more than 64k fragments. */ - m->m_pkthdr.csum_data = - (m->m_pkthdr.csum_data & 0xffff) + (m->m_pkthdr.csum_data >> 16); + while (m->m_pkthdr.csum_data & 0xffff0000) + m->m_pkthdr.csum_data = (m->m_pkthdr.csum_data & 0xffff) + + (m->m_pkthdr.csum_data >> 16); #ifdef MAC mac_ipq_reassemble(fp, m); mac_ipq_destroy(fp);