]> git.baikalelectronics.ru Git - kernel.git/commit
tools/power turbostat: set max_num_cpus equal to the cpumask length
authorPrarit Bhargava <prarit@redhat.com>
Fri, 1 Jun 2018 14:04:28 +0000 (10:04 -0400)
committerLen Brown <len.brown@intel.com>
Sat, 2 Jun 2018 03:12:46 +0000 (23:12 -0400)
commit01e5c314c7914f088258f16ef3a76c3ded1d4dbd
tree84762eb24cde5bd74d899949eb41719e458b88d3
parent5dd4ec9ca8bf1a10d5e0bf5a447cff486cc55ca4
tools/power turbostat: set max_num_cpus equal to the cpumask length

Future fixes will use sysfs files that contain cpumask output.  The code
needs to know the length of the cpumask in order to determine which cpus
are set in a cpumask.  Currently topo.max_cpu_num is the maximum cpu
number.  It can be increased the the maximum value of cpus represented in
cpumasks.

Set max_num_cpus to the length of a cpumask.

Signed-off-by: Prarit Bhargava <prarit@redhat.com>
Signed-off-by: Len Brown <len.brown@intel.com>
tools/power/x86/turbostat/turbostat.c