|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v1 5/5] xentrace: Implement cpu mask range parsing of human values (-C).
On 06/04/2014 02:44 PM, Konrad Rzeszutek Wilk wrote: Instead of just using -c 0x<some hex value> we can also use -C <starting cpu>-<end cpu> or -C <cpu1>,<cpu2> Would it be better, I wonder, to just try to overload the -c operator, special-casing "0x[hex]" to use the old interface? Anyone who's currently using -c should almost certainly be using a hex string there, I should think -- using decimal would be pretty daft. All it would take, I think, would be to check for bytes 0 and 1 being "0x", and if so, calling strtoul() rather than parse_cpumask_range(). [snip] Is it possible for this to have a space at the beginning? Doesn't getopt() take care of that? + + if ( totaldigits && c && isspace(c_old) ) c_old doesn't seem to be set anywhere after it's initialized above. Isn't exp_digit a bit redundant, as if "in_range" is 1, "exp_digit" will also always be 1? Everything else looks reasonable. -George _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |