[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v18 06/10] x86: collect global CMT information
>>> On 30.09.14 at 12:49, <chao.p.peng@xxxxxxxxxxxxxxx> wrote: > + case XEN_SYSCTL_psr_cmt_op: > + if ( !psr_cmt_enabled() ) > + return -ENODEV; > + > + if ( sysctl->u.psr_cmt_op.flags != 0 ) > + return -EINVAL; > + > + switch ( sysctl->u.psr_cmt_op.cmd ) > + { > + case XEN_SYSCTL_PSR_CMT_enabled: > + sysctl->u.psr_cmt_op.data = > + (psr_cmt->features & PSR_RESOURCE_TYPE_L3) && > + (psr_cmt->l3.features & PSR_CMT_L3_OCCUPANCY); > + break; > + case XEN_SYSCTL_PSR_CMT_get_total_rmid: > + sysctl->u.psr_cmt_op.data = psr_cmt->rmid_max; > + break; > + case XEN_SYSCTL_PSR_CMT_get_l3_upscaling_factor: > + sysctl->u.psr_cmt_op.data = psr_cmt->l3.upscaling_factor; > + break; > + case XEN_SYSCTL_PSR_CMT_get_l3_cache_size: > + { > + struct cpuid4_info info; > + > + ret = cpuid4_cache_lookup(3, &info); > + if ( ret < 0 ) > + break; > + > + sysctl->u.psr_cmt_op.data = info.size / 1024; /* in KB unit */ > + } Now that I look at this again - is this really a useful operation without specifying a socket of CPU number? > + break; > + default: Please move the break inside the braces or separate it by a blank line from "default:". Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |