[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [Xen-devel] FW: Is it a correct place for VBD information?



Hi, Kier.

> 
> On 27 Jun 2006, at 12:28, Satoshi Uchida wrote:
> 
> >
> > 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 
> function, so I 
> > do not sent now.
> 
> Do you really think that's better than just writing the 
> string literals directly in the macro uses?
> 
> e.g.,
> VBD_SHOW(physical_device, "%x:%x", be->major, be->minor); 
> VBD_SHOW(mode, "%s", be->mode);
> 
> Also, the "\n" can be removed from the caller strings and 
> placed inside the VBD_SHOW macro:
>   .... format "\n" .....
> 
> The compiler will concatenate the string literals.
> 

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 
want to use idea if using literals.

Please comment, using fmt macro or literals.



Thanks
Satoshi UCHIDA


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.