From: "Satoshi Uchida" Subject: RE: FW: Is it a correct place for VBD information? Date: Wed, 28 Jun 2006 10:15:08 +0900 Message-ID: <001001c69a50$4bc9b7d0$4c87380a@ad.spf.cl.nec.co.jp> References: <2e4c8dd38360b9ba7993cc9de7dba768@cl.cam.ac.uk> Mime-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: <2e4c8dd38360b9ba7993cc9de7dba768@cl.cam.ac.uk> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: 'Keir Fraser' Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org Hi, Kier. >=20 > On 27 Jun 2006, at 12:28, Satoshi Uchida wrote: >=20 > > > > Sorry. > > You will be sure What I mean hear by following patch. > > I sent this patch formally after applying the sysfs patch. > > This patch is to clear code, namely no give additional=20 > function, so I=20 > > do not sent now. >=20 > Do you really think that's better than just writing the=20 > string literals directly in the macro uses? >=20 > e.g., > VBD_SHOW(physical_device, "%x:%x", be->major, be->minor);=20 > VBD_SHOW(mode, "%s", be->mode); >=20 > Also, the "\n" can be removed from the caller strings and=20 > placed inside the VBD_SHOW macro: > .... format "\n" ..... >=20 > The compiler will concatenate the string literals. >=20 I think that it is OK using macros or literals. In Linux net/core/net-sysfs.c., the 'fmt' representation is used by = statistical data. In the other, it is used literals or define show function directly. Therefore, representation will be not unified in detail. (Perhaps, macro is not better in net/core/net-sysfs.c) I think that it is useful for recognizing data type and interesting, and so used fmt representation. In Linux, "\n" is written in format even if using literals. However, I think that above representation is interesting and=20 want to use idea if using literals. Please comment, using fmt macro or literals. Thanks Satoshi UCHIDA