From owner-svn-src-head@FreeBSD.ORG Wed Mar 7 07:01:42 2012 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 90986106564A; Wed, 7 Mar 2012 07:01:42 +0000 (UTC) (envelope-from pluknet@gmail.com) Received: from mail-lpp01m010-f54.google.com (mail-lpp01m010-f54.google.com [209.85.215.54]) by mx1.freebsd.org (Postfix) with ESMTP id 6B4DE8FC08; Wed, 7 Mar 2012 07:01:41 +0000 (UTC) Received: by lagv3 with SMTP id v3so9791774lag.13 for ; Tue, 06 Mar 2012 23:01:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=+D+k8oRJUcnfWPXyker5NpArCDuK3p01CRDj2ewzmJM=; b=gFXPhbgDNHCh90HIDBe1oHr7XnC+EGnnmqsDOc2V2EKzk02U+kkCVWPetYIa9hdUzq PLVqSkdo5VE+HPia3ezBBi9Ib1ogLUp5L66moeSa8AFLVYb3Ta8dX7x6FzTRgyeQOVIP Jlx0NpLbJ/EhbuESa7YMz1CREfFpCfhJWUmFwdJwhoS7uRbsy8ubCAoT6X3kfNlYnHDc S+LMWQwJa2UWebKMs8pMWoIYV9BqEl9quCLsjV422ERb2Gbs5mmae4w8tv/mfIcpKL1a 9hteTZp3WSx04vffVH8MrmOhVlv0sHOIwlShoV0WwxhVl/pFnYvCy9nyfoX0Cucjm4On lagA== MIME-Version: 1.0 Received: by 10.112.102.161 with SMTP id fp1mr279551lbb.71.1331103700061; Tue, 06 Mar 2012 23:01:40 -0800 (PST) Sender: pluknet@gmail.com Received: by 10.152.21.73 with HTTP; Tue, 6 Mar 2012 23:01:37 -0800 (PST) In-Reply-To: <201203062258.q26MwDI6061226@svn.freebsd.org> References: <201203062258.q26MwDI6061226@svn.freebsd.org> Date: Wed, 7 Mar 2012 10:01:37 +0300 X-Google-Sender-Auth: DQckszJ9E0051U1uMQtCXk52scU Message-ID: From: Sergey Kandaurov To: Andrew Thompson Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Cc: svn-src-head@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org Subject: Re: svn commit: r232629 - in head: sbin/ifconfig sys/net X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.5 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: Wed, 07 Mar 2012 07:01:42 -0000 On 7 March 2012 02:58, Andrew Thompson wrote: > Author: thompsa > Date: Tue Mar =A06 22:58:13 2012 > New Revision: 232629 > URL: http://svn.freebsd.org/changeset/base/232629 > > Log: > =A0Add the ability to set which packet layers are used for the load balan= ce hash > =A0calculation. > > Modified: > =A0head/sbin/ifconfig/ifconfig.8 > =A0head/sbin/ifconfig/iflagg.c > =A0head/sys/net/ieee8023ad_lacp.c > =A0head/sys/net/if_lagg.c > =A0head/sys/net/if_lagg.h HI. This change breaks LINT-NOIP. Something like this shoud fix it: Index: sys/net/if_lagg.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 --- sys/net/if_lagg.c (revision 232637) +++ sys/net/if_lagg.c (working copy) @@ -1449,6 +1449,7 @@ const struct ip6_hdr *ip6; uint32_t flow; #endif +#if defined(INET) || defined(INET6) union { #ifdef INET struct ip ip; @@ -1458,8 +1459,8 @@ #endif uint32_t port; } buf; +#endif - off =3D sizeof(*eh); if (m->m_len < off) goto out; > Modified: head/sys/net/if_lagg.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/net/if_lagg.c =A0 =A0 =A0Tue Mar =A06 22:45:54 2012 =A0 =A0 = =A0 =A0(r232628) > +++ head/sys/net/if_lagg.c =A0 =A0 =A0Tue Mar =A06 22:58:13 2012 =A0 =A0 = =A0 =A0(r232629) [..] > @@ -1413,34 +1432,46 @@ lagg_gethdr(struct mbuf *m, u_int off, u > =A0} > > =A0uint32_t > -lagg_hashmbuf(struct mbuf *m, uint32_t key) > +lagg_hashmbuf(struct lagg_softc *sc, struct mbuf *m, uint32_t key) > =A0{ > =A0 =A0 =A0 =A0uint16_t etype; > - =A0 =A0 =A0 uint32_t p =3D 0; > + =A0 =A0 =A0 uint32_t p =3D key; > =A0 =A0 =A0 =A0int off; > =A0 =A0 =A0 =A0struct ether_header *eh; > =A0 =A0 =A0 =A0struct ether_vlan_header vlanbuf; > =A0 =A0 =A0 =A0const struct ether_vlan_header *vlan; > =A0#ifdef INET > =A0 =A0 =A0 =A0const struct ip *ip; > - =A0 =A0 =A0 struct ip ipbuf; > + =A0 =A0 =A0 const uint32_t *ports; > + =A0 =A0 =A0 int iphlen; > =A0#endif > =A0#ifdef INET6 > =A0 =A0 =A0 =A0const struct ip6_hdr *ip6; > - =A0 =A0 =A0 struct ip6_hdr ip6buf; > =A0 =A0 =A0 =A0uint32_t flow; > =A0#endif > + =A0 =A0 =A0 union { > +#ifdef INET > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 struct ip ip; > +#endif > +#ifdef INET6 > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 struct ip6_hdr ip6; > +#endif > + =A0 =A0 =A0 =A0 =A0 =A0 =A0 uint32_t port; > + =A0 =A0 =A0 } buf; > + > [..] --=20 wbr, pluknet