From owner-svn-src-head@freebsd.org Tue Jan 22 18:57:22 2019 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 5141614AB8C7; Tue, 22 Jan 2019 18:57:22 +0000 (UTC) (envelope-from brooks@spindle.one-eyed-alien.net) Received: from spindle.one-eyed-alien.net (spindle.one-eyed-alien.net [199.48.129.229]) (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 EC4506A4D8; Tue, 22 Jan 2019 18:57:21 +0000 (UTC) (envelope-from brooks@spindle.one-eyed-alien.net) Received: by spindle.one-eyed-alien.net (Postfix, from userid 3001) id 00EAB3C475F; Tue, 22 Jan 2019 18:57:14 +0000 (UTC) Date: Tue, 22 Jan 2019 18:57:14 +0000 From: Brooks Davis To: Mark Johnston Cc: Ian Lepore , Brooks Davis , src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: Re: svn commit: r343305 - head/sys/net Message-ID: <20190122185714.GA77653@spindle.one-eyed-alien.net> References: <201901221739.x0MHdQps047360@repo.freebsd.org> <20190122181257.GA81189@raichu> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="lrZ03NoBR/3+SXJZ" Content-Disposition: inline In-Reply-To: <20190122181257.GA81189@raichu> User-Agent: Mutt/1.9.4 (2018-02-28) X-Rspamd-Queue-Id: EC4506A4D8 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-6.92 / 15.00]; NEURAL_HAM_MEDIUM(-1.00)[-0.999,0]; NEURAL_HAM_SHORT(-0.92)[-0.923,0]; REPLY(-4.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0] X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.29 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, 22 Jan 2019 18:57:22 -0000 --lrZ03NoBR/3+SXJZ Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Jan 22, 2019 at 01:12:57PM -0500, Mark Johnston wrote: > On Tue, Jan 22, 2019 at 10:45:16AM -0700, Ian Lepore wrote: > > On Tue, 2019-01-22 at 17:39 +0000, Brooks Davis wrote: > > > Author: brooks > > > Date: Tue Jan 22 17:39:26 2019 > > > New Revision: 343305 > > > URL: https://svnweb.freebsd.org/changeset/base/343305 > > >=20 > > > Log: > > > Rework CASE_IOC_IFGROUPREQ() to require a case before the macro. > > > =20 > > > This is more compatible with formatting tools and looks more > > > normal. > > > =20 > > > Reported by: jhb (on a different review) > > > Sponsored by: DARPA, AFRL > > > Differential Revision: https://reviews.freebsd.org/D18442 > > >=20 > > > Modified: > > > head/sys/net/if.c > > >=20 > > > Modified: head/sys/net/if.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.c Tue Jan 22 17:34:53 2019 (r343304) > > > +++ head/sys/net/if.c Tue Jan 22 17:39:26 2019 (r343305) > > > @@ -168,14 +168,14 @@ struct ifmediareq32 { > > > #define SIOCGIFXMEDIA32 _IOC_NEWTYPE(SIOCGIFXMEDIA, struct > > > ifmediareq32) > > > =20 > > > #define _CASE_IOC_IFGROUPREQ_32(cmd) =09 > > > \ > > > - case _IOC_NEWTYPE((cmd), struct ifgroupreq32): > > > + _IOC_NEWTYPE((cmd), struct ifgroupreq32): case > >=20 > > That 'case' at the end of the line doesn't look right. >=20 > With the change, CASE_IOC_IFGROUPREQ(cmd) yields >=20 > case 32: case : >=20 > which seems to be the intent. This is the intent. This macro avoids a pile of #ifdef macros in the actual code (and makes more sense in my upstream branch where I have another set of ioctl values). -- Brooks --lrZ03NoBR/3+SXJZ Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEcBAEBAgAGBQJcR2eKAAoJEKzQXbSebgfAOZMH/AsOazzb8/739uR36FiMCnov 8nJ9RrKUo2QYjvgsoHQi6yW+ol8NzZNyohKZgjt127l70I4Gdes0aovLSi8Rwkjn vaRsu0N4c9DqqVpZvRYPeU6feVC1FGCXie8HHZY8JpLHsJBgXBnZDnGZhodgNFqq xhFBhSBb5AWIOC0VIq1puCc76sTYUcu5KSS60ioxjpFzPH/7Iy34/F+pn2WeqtVU MwKmyxwmQKKC5GmJgIAdGDGD9cDC450p/Gj0Ix7tRx67eOElFfBf+7lHPdoPLbqV 9WLiwMOcyyuLQhgB4A93wowCohvhij8SSKKUxt8NcWEltyIUHHYo876XUUO2B3o= =8ILk -----END PGP SIGNATURE----- --lrZ03NoBR/3+SXJZ--