From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dario Faggioli Subject: Re: [PATCH v2] sched: credit2: respect per-vcpu hard affinity Date: Wed, 4 Mar 2015 11:03:35 +0000 Message-ID: <1425467012.2614.22.camel@citrix.com> References: <1423453550-3526-1-git-send-email-jtweaver@hawaii.edu> <1425352508.10194.241.camel@citrix.com> <54F5892A0200007800065854@mail.emea.novell.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============5564640179597573294==" Return-path: In-Reply-To: <54F5892A0200007800065854@mail.emea.novell.com> Content-Language: en-US List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: "JBeulich@suse.com" Cc: "xen-devel@lists.xen.org" , "jtweaver@hawaii.edu" , George Dunlap , "henric@hawaii.edu" List-Id: xen-devel@lists.xenproject.org --===============5564640179597573294== Content-Language: en-US Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-S57LRuo8y2E0/DyABSyn" --=-S57LRuo8y2E0/DyABSyn Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, 2015-03-03 at 09:12 +0000, Jan Beulich wrote: > >>> On 03.03.15 at 04:15, wrote: > > On Sun, 2015-02-08 at 17:45 -1000, Justin T. Weaver wrote: > >> +#define csched2_cpumask cpumask[smp_processor_id()] > >> + > > I like the idea, but put the right side between parentheses. >=20 > Parentheses? Why? There's no operator with higher precedence > than postfix ones. >=20 There certainly isn't. The why is my personal taste, mostly, which does not count much, I know, so I grep-ed around the sources and found other similar examples which have parentheses, and so I went ahead and asked. However, I can certainly live without them. :-) > >> +static int get_safe_pcpu(struct csched2_vcpu *svc) > >> +{ > >> > > I also don't like the name... __choose_cpu() maybe ? >=20 > Why is everyone liking these double underscore prefixed names so > much? They're in conflict with the library name space and hence > should be avoided. Single underscore prefixed names (and the > underscore not followed by an upper case letter) is what the > standard sets aside for file scope (i.e. static) identifiers. >=20 Well, I'm not sure I know why, but --from a purely aesthetic point of view-- I actually like __foo more than _foo. However, the main reason why I'm suggesting it here, is to follow suit, since __foo is what is always used (in sched_credit2.c, but also in most of other files AFAICT) for similar functions. I see the point you're making, and I can live with _choose_cpu(), but the result would look a bit inconsistent, IMO. Regards, Dario --=-S57LRuo8y2E0/DyABSyn Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iEYEABECAAYFAlT25oQACgkQk4XaBE3IOsRzywCeKbWCpD86hGDXOshPPstuexrX RhwAn1VdzBrdQoAa/tJrACbQQ5pJBRuF =uOg9 -----END PGP SIGNATURE----- --=-S57LRuo8y2E0/DyABSyn-- --===============5564640179597573294== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel --===============5564640179597573294==--