[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v3 2/6] xen/PMU: Sysfs interface for setting Xen PMU mode
On 03/07/14 20:14, Boris Ostrovsky wrote: > Set Xen's PMU mode via /sys/hypervisor/pmu/pmu_mode. Add XENPMU hypercall. > [...] > +static ssize_t pmu_mode_store(struct hyp_sysfs_attr *attr, > + const char *buffer, size_t len) > +{ > + int ret; > + struct xen_pmu_params xp; > + int i; > + > + for (i = 0; i < ARRAY_SIZE(pmu_modes); i++) { > + if (strncmp(buffer, pmu_modes[i].name, > + strlen(pmu_modes[i].name)) == 0) { > + xp.val = pmu_modes[i].mode; > + break; > + } > + } This looks like it would accept "office" as "off" (etc) which I don't think it is what we want. I assume the intention is to allow either "off\n" or "off"? David _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |