[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v8 2/5] tools: add routine to get CMT L3 event mask
On Wed, Jan 28, 2015 at 01:40:25PM +0000, Ian Campbell wrote: > On Wed, 2015-01-28 at 16:04 +0800, Chao Peng wrote: > > This is the tools side wrapper for XEN_SYSCTL_PSR_CMT_get_l3_event_mask > > of XEN_SYSCTL_psr_cmt_op. > > > > Signed-off-by: Chao Peng <chao.p.peng@xxxxxxxxxxxxxxx> > > --- > > tools/libxc/include/xenctrl.h | 1 + > > tools/libxc/xc_psr.c | 17 +++++++++++++++++ > > tools/libxl/libxl.h | 1 + > > This needs a LIBXL_HAVE #define in libxl.h to advertise the new > functionality. OK. > > > +int xc_psr_cmt_get_l3_event_mask(xc_interface *xch, uint32_t *event_mask); > > What are the possible values of the event mask? Is there a guarantee > from somewhere that 32-bits is always sufficient? It comes directly from cpuid which is 32 bit now and look like not possible to extend it to 64 bit. Only bits[0:2] is used at present. > > How can the libxl caller decode the meaning of the bits since they are > not defined in the libxl.h header? > > Perhaps a struct of booleans would be a better interface at the libxl > level? > > Or perhaps the interface should be more along the lines of "is psr > feature X available", like libxl_psr_..._feature_enabled(ctx, > SOME_SYMBOL)? > > Or perhaps the function to actual access the info should have an > ERROR_PSR_FUNCTION NOT_SUPPORTED return? As answered in another reply, I'd use it as: int libxl_psr_cmt_type_supported(libxl_ctx *ctx, libxl_psr_cmt_type type); Thanks, Chao _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |