From owner-p4-projects@FreeBSD.ORG Sun May 30 19:31:25 2010 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 922A11065673; Sun, 30 May 2010 19:31:25 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 364E0106564A; Sun, 30 May 2010 19:31:25 +0000 (UTC) (envelope-from zec@freebsd.org) Received: from munja.zvne.fer.hr (munja.zvne.fer.hr [161.53.66.248]) by mx1.freebsd.org (Postfix) with ESMTP id B81368FC0A; Sun, 30 May 2010 19:31:24 +0000 (UTC) Received: from sluga.fer.hr ([161.53.66.244]) by munja.zvne.fer.hr with Microsoft SMTPSVC(6.0.3790.4675); Sun, 30 May 2010 21:19:18 +0200 Received: from localhost ([161.53.19.8]) by sluga.fer.hr over TLS secured channel with Microsoft SMTPSVC(6.0.3790.4675); Sun, 30 May 2010 21:19:17 +0200 From: Marko Zec To: Garrett Cooper Date: Sun, 30 May 2010 21:18:56 +0200 User-Agent: KMail/1.9.10 References: <201005301444.o4UEidHb057496@repoman.freebsd.org> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Message-Id: <201005302118.57240.zec@freebsd.org> X-OriginalArrivalTime: 30 May 2010 19:19:18.0207 (UTC) FILETIME=[FFE6D4F0:01CB002C] Cc: Perforce Change Reviews Subject: Re: PERFORCE change 178978 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 30 May 2010 19:31:25 -0000 On Sunday 30 May 2010 20:59:33 Garrett Cooper wrote: > On Sun, May 30, 2010 at 7:44 AM, Marko Zec wrote: > > http://p4web.freebsd.org/@@178978?ac=3D10 > > > > Change 178978 by zec@zec_tpx32 on 2010/05/30 14:43:53 > > > > =A0 =A0 =A0 =A0Attempt to reduce the diff against head a bit further and > > =A0 =A0 =A0 =A0improve style, though Ivor hasn't left much here to be d= one... > > > > Affected files ... > > > > .. //depot/projects/vimage/src/sys/net/vnet.c#12 edit > > .. //depot/projects/vimage/src/sys/netinet/ip_mroute.c#42 edit > > > > Differences ... > > > > =3D=3D=3D=3D //depot/projects/vimage/src/sys/net/vnet.c#12 (text+ko) = =3D=3D=3D=3D > > > > @@ -169,7 +169,7 @@ > > =A0* we want the virtualized global variable space to be page-sized, we= may > > =A0* have more space than that in practice. > > =A0*/ > > -#define =A0 =A0 =A0 =A0VNET_MODMIN =A0 =A0 (8192<<2) > > +#define =A0 =A0 =A0 =A0VNET_MODMIN =A0 =A0 32768 > > =A0#define =A0 =A0 =A0 =A0VNET_SIZE =A0 =A0 =A0 roundup2(VNET_BYTES, PA= GE_SIZE) > > =A0#define =A0 =A0 =A0 =A0VNET_MODSIZE =A0 =A0(VNET_SIZE - (VNET_BYTES = =2D VNET_MODMIN)) > > > > > > =3D=3D=3D=3D //depot/projects/vimage/src/sys/netinet/ip_mroute.c#42 (te= xt+ko) > > =3D=3D=3D=3D > > > > @@ -159,9 +159,9 @@ > > =A0 =A0 =A0 =A0 =A0((g).s_addr >> 20) ^ ((g).s_addr >> 10) ^ (g).s_addr= ) & > > V_mfchash) #define =A0 =A0 =A0 =A0MFCHASHSIZE =A0 =A0 256 > > > > -static VNET_DEFINE(u_char*, nexpire); > > +static u_long mfchashsize; =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 /* = Hash size */ > > +static VNET_DEFINE(u_char *, nexpire); =A0 =A0 =A0 =A0 /* 0..mfchashsi= ze-1 */ > > =A0#define =A0 =A0 =A0 =A0V_nexpire =A0 =A0 =A0 =A0 =A0 =A0 =A0 VNET(ne= xpire) > > -static u_long mfchashsize; =A0 =A0 /* Hash size */ > > =A0static VNET_DEFINE(LIST_HEAD(mfchashhdr, mfc)*, mfchashtbl); > > =A0#define =A0 =A0 =A0 =A0V_mfchashtbl =A0 =A0 =A0 =A0 =A0 =A0VNET(mfch= ashtbl) > > > > @@ -218,7 +218,7 @@ > > =A0*/ > > =A0static VNET_DEFINE(struct bw_upcall, bw_upcalls[BW_UPCALLS_MAX]); > > =A0#define =A0 =A0 =A0 =A0V_bw_upcalls =A0 =A0 =A0 =A0 =A0 =A0VNET(bw_u= pcalls) > > -static VNET_DEFINE(u_int, bw_upcalls_n); /* # of pending upcalls */ > > +static VNET_DEFINE(u_int, bw_upcalls_n) =3D 0; /* # of pending upcalls= */ > > =A0#define =A0 =A0 =A0 =A0V_bw_upcalls_n =A0 =A0 =A0 =A0 =A0VNET(bw_upc= alls_n) > > =A0static VNET_DEFINE(struct callout, bw_upcalls_ch); > > =A0#define =A0 =A0 =A0 =A0V_bw_upcalls_ch =A0 =A0 =A0 =A0 VNET(bw_upcal= ls_ch) > > @@ -367,9 +367,9 @@ > > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0= =A0 =A0 MRT_MFC_FLAGS_BORDER_VIF | > > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0= =A0 =A0 MRT_MFC_RP | > > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0= =A0 =A0 MRT_MFC_BW_UPCALL); > > -static VNET_DEFINE(uint32_t, mrt_api_config); > > +static VNET_DEFINE(uint32_t, mrt_api_config) =3D 0; > > =A0#define =A0 =A0 =A0 =A0V_mrt_api_config =A0 =A0 =A0 =A0VNET(mrt_api_= config) > > -static VNET_DEFINE(int, pim_assert_enabled); > > +static VNET_DEFINE(int, pim_assert_enabled) =3D 0; > > =A0#define =A0 =A0 =A0 =A0V_pim_assert_enabled =A0 =A0VNET(pim_assert_e= nabled) > > =A0static struct timeval pim_assert_interval =3D { 3, 0 }; =A0/* Rate l= imit */ > > > > @@ -663,7 +663,7 @@ > > =A0 =A0 =A0 =A0return EOPNOTSUPP; > > > > =A0 =A0 if (version !=3D 1) > > - =A0 =A0 =A0 return (ENOPROTOOPT); > > + =A0 =A0 =A0 return ENOPROTOOPT; > > That's actually a style regression (along with any other return calls > without parentheses). Yup - technically you're right, but this particular change was intended to= =20 minimize the scope of the diff against head - if you'd throw a look at=20 ip_mroute.c in head you'd spot a ton of other style violations, including=20 this one. My intention is to do a functional (V_irtualization) change in o= ne=20 commit, and then we can do a no-op style sweep on ip_mroute.c later. Marko