tools/power turbostat: Harden probe_intel_uncore_frequency()
authorLen Brown <len.brown@intel.com>
Sun, 21 Apr 2024 18:45:10 +0000 (14:45 -0400)
committerLen Brown <len.brown@intel.com>
Sun, 21 Apr 2024 21:05:55 +0000 (17:05 -0400)
commitae3326ac5742506409a03ce5d69716a8dba4eabc
treeb8fb764a50a10fd0475785266f58da96ecf4b389
parent231ce08b662a58d4392da998699b3d4a7e2e87cf
tools/power turbostat: Harden probe_intel_uncore_frequency()

If sysfs directory "intel_uncore_frequency/cluster00/" exists,
then use uncore cluster code (now its own routine).

The previous check for
"intel_uncore_frequency/package_00_die_00/current_freq_khz",
could be unreliable in the face of sparse die id's.

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