From owner-svn-src-head@FreeBSD.ORG Tue Sep 30 21:04:03 2014 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 3AC3CA2C; Tue, 30 Sep 2014 21:04:03 +0000 (UTC) Received: from mail-n.franken.de (drew.ipv6.franken.de [IPv6:2001:638:a02:a001:20e:cff:fe4a:feaa]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "mail-n.franken.de", Issuer "Thawte DV SSL CA" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id ED940D90; Tue, 30 Sep 2014 21:04:02 +0000 (UTC) Received: from [192.168.1.102] (p508F16E6.dip0.t-ipconnect.de [80.143.22.230]) (Authenticated sender: macmic) by mail-n.franken.de (Postfix) with ESMTP id C387A1C104FDB; Tue, 30 Sep 2014 23:03:58 +0200 (CEST) Content-Type: text/plain; charset=us-ascii Mime-Version: 1.0 (Mac OS X Mail 7.3 \(1878.6\)) Subject: Re: svn commit: r272326 - head/sys/netinet From: Michael Tuexen In-Reply-To: Date: Tue, 30 Sep 2014 23:03:56 +0200 Content-Transfer-Encoding: quoted-printable Message-Id: <4A8FE3A2-B085-4EBC-8E3E-F5A91129EEDE@freebsd.org> References: <201409302029.s8UKTx0e098653@svn.freebsd.org> To: Adrian Chadd X-Mailer: Apple Mail (2.1878.6) Cc: "svn-src-head@freebsd.org" , "svn-src-all@freebsd.org" , "src-committers@freebsd.org" X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.18-1 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: Tue, 30 Sep 2014 21:04:03 -0000 On 30 Sep 2014, at 22:47, Adrian Chadd wrote: > Hi, >=20 > I think you should consider adding a new set of protocol counters for > UDPLITE. :) Yepp. There is http://tools.ietf.org/html/rfc5097 which needs to be implemented. Best regards Michael >=20 >=20 >=20 > -a >=20 > On 30 September 2014 13:29, Michael Tuexen wrote: >> Author: tuexen >> Date: Tue Sep 30 20:29:58 2014 >> New Revision: 272326 >> URL: http://svnweb.freebsd.org/changeset/base/272326 >>=20 >> Log: >> UDPLite requires a checksum. Therefore, discard a received packet if >> the checksum is 0. >>=20 >> MFC after: 3 days >>=20 >> Modified: >> head/sys/netinet/udp_usrreq.c >>=20 >> Modified: head/sys/netinet/udp_usrreq.c >> = =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D >> --- head/sys/netinet/udp_usrreq.c Tue Sep 30 20:18:10 2014 = (r272325) >> +++ head/sys/netinet/udp_usrreq.c Tue Sep 30 20:29:58 2014 = (r272326) >> @@ -498,8 +498,16 @@ udp_input(struct mbuf **mp, int *offp, i >> m_freem(m); >> return (IPPROTO_DONE); >> } >> - } else >> - UDPSTAT_INC(udps_nosum); >> + } else { >> + if (proto =3D=3D IPPROTO_UDP) { >> + UDPSTAT_INC(udps_nosum); >> + } else { >> + /* UDPLite requires a checksum */ >> + /* XXX: What is the right UDPLite MIB counter = here? */ >> + m_freem(m); >> + return (IPPROTO_DONE); >> + } >> + } >>=20 >> pcbinfo =3D get_inpcbinfo(proto); >> if (IN_MULTICAST(ntohl(ip->ip_dst.s_addr)) || >>=20 >=20 >=20