tools/power/turbostat: Relocate cstate probing code
authorZhang Rui <rui.zhang@intel.com>
Tue, 29 Aug 2023 05:47:58 +0000 (13:47 +0800)
committerZhang Rui <rui.zhang@intel.com>
Wed, 27 Sep 2023 14:14:20 +0000 (22:14 +0800)
commit045acf6064c5567011163e97c28906e0a7791414
treebb29ab91eefe090a18e934760ef32cf63991cef5
parent32e8c6169af7ef7c938b1bd996d27ab171e27d80
tools/power/turbostat: Relocate cstate probing code

Move all cstate probing related code into probe_cstates().

Note that dump_platform_info() actually dumps both MSR_PLATFORM_INFO and
MSR_IA32_POWER_CTL. MSR_PLATFORM_INFO is for pstate and
MSR_IA32_POWER_CTL is for cstate. So split dump_platform_info() and dump
MSR_IA32_POWER_CTL in probe_cstates().

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