[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH XEN v2 08/15] tools: Refactor /dev/xen/gnt{dev, shr} wrappers into libxengnttab.
On Tue, 2015-09-22 at 13:41 +0100, Ian Jackson wrote: > Andrew Cooper writes ("Re: [Xen-devel] [PATCH XEN v2 08/15] tools: > Refactor /dev/xen/gnt{dev, shr} wrappers into libxengnttab."): > > On 22/09/15 12:25, Ian Campbell wrote: > > > Any thoughts/preferences on this library interface regarding: > > > > > > The use of a (perhaps to be added) grant_ref_t in preference to > > > uint32_t as > > > it is now? > > Is a grant_ref_t uint32_t ? Yes (in xen/include/public/grant_table.h). > > Probably a good idea. We should also introduce/use domid_t > > consistently > > through the new API as well. > > domid_it is a uint16_t. The problem with that is that there is no > space for sentinel or magic values which are assigned meanings outside > the hypervisor. Correct. We don't necessarily need to use the same domid_t as the hypervisor interface, but not doing so would seem confusing... > > Given that it is 2015, I vote for -std=c99 and all the niceties it > > brings, such as bool. > > We should certainly consider some GNU extensions. I don't know which > are widely available, but we should consider: > * Statement expressions > * Some of the function and data attributes, particularly > format, noreturn, unused. (Maybe via some compatibility macros.) > * Anonymous struct/union members. > * typeof For the implementation side, sure, few of these seem relevant to the interface headers being discussed here (apart maybe from anon members, which is moot because none of the libraries in question have a need for such a thing AFAICT). Ian. _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |