Commit a444083
tools/power/turbostat: Fix microcode patch level output for AMD/Hygon
turbostat always used the same logic to read the microcode patch level,
which is correct for Intel but not for AMD/Hygon.
While Intel stores the patch level in the upper 32 bits of MSR, AMD
stores it in the lower 32 bits, which causes turbostat to report the
microcode version as 0x0 on AMD/Hygon.
Fix by shifting right by 32 for non-AMD/Hygon, preserving the existing
behavior for Intel and unknown vendors.
Fixes: 3e40484 ("tools/power turbostat: Add --no-msr option")
Signed-off-by: Serhii Pievniev <spevnev16@gmail.com>
Signed-off-by: Len Brown <len.brown@intel.com>1 parent 99b38fa commit a444083
1 file changed
Lines changed: 6 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9121 | 9121 | | |
9122 | 9122 | | |
9123 | 9123 | | |
9124 | | - | |
| 9124 | + | |
9125 | 9125 | | |
9126 | | - | |
| 9126 | + | |
9127 | 9127 | | |
| 9128 | + | |
| 9129 | + | |
| 9130 | + | |
9128 | 9131 | | |
9129 | 9132 | | |
9130 | 9133 | | |
| |||
9138 | 9141 | | |
9139 | 9142 | | |
9140 | 9143 | | |
9141 | | - | |
| 9144 | + | |
9142 | 9145 | | |
9143 | 9146 | | |
9144 | 9147 | | |
| |||
0 commit comments