From owner-svn-src-head@FreeBSD.ORG Fri May 9 14:15:48 2014 Return-Path: Delivered-To: svn-src-head@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 9B17B4DB; Fri, 9 May 2014 14:15:48 +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 886DBA9F; Fri, 9 May 2014 14:15:48 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.8/8.14.8) with ESMTP id s49EFmkA082934; Fri, 9 May 2014 14:15:48 GMT (envelope-from tuexen@svn.freebsd.org) Received: (from tuexen@localhost) by svn.freebsd.org (8.14.8/8.14.8/Submit) id s49EFm1v082933; Fri, 9 May 2014 14:15:48 GMT (envelope-from tuexen@svn.freebsd.org) Message-Id: <201405091415.s49EFm1v082933@svn.freebsd.org> From: Michael Tuexen Date: Fri, 9 May 2014 14:15:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r265776 - 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.18 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: Fri, 09 May 2014 14:15:48 -0000 Author: tuexen Date: Fri May 9 14:15:48 2014 New Revision: 265776 URL: http://svnweb.freebsd.org/changeset/base/265776 Log: Fix a logic bug which prevented the sending of UDP packet with 0 checksum. This bug was introduced in r264212 and should be X-MFCed with that revision, if UDP-Lite support if MFCed. Modified: head/sys/netinet/udp_usrreq.c Modified: head/sys/netinet/udp_usrreq.c ============================================================================== --- head/sys/netinet/udp_usrreq.c Fri May 9 14:02:18 2014 (r265775) +++ head/sys/netinet/udp_usrreq.c Fri May 9 14:15:48 2014 (r265776) @@ -1375,7 +1375,8 @@ udp_output(struct inpcb *inp, struct mbu faddr.s_addr = INADDR_BROADCAST; if ((ui->ui_sum = in_cksum(m, sizeof(struct ip) + cscov)) == 0) ui->ui_sum = 0xffff; - } else if (V_udp_cksum || !cscov_partial) { + } else if (V_udp_cksum || pr == IPPROTO_UDPLITE) { + /* for UDP-Lite full checksum coverage is requested */ if (inp->inp_flags & INP_ONESBCAST) faddr.s_addr = INADDR_BROADCAST; ui->ui_sum = in_pseudo(ui->ui_src.s_addr, faddr.s_addr,