diff options
-rw-r--r-- | tools/power/x86/turbostat/turbostat.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/tools/power/x86/turbostat/turbostat.c b/tools/power/x86/turbostat/turbostat.c index 5db4addbe1d9..5ce88dd8c95a 100644 --- a/tools/power/x86/turbostat/turbostat.c +++ b/tools/power/x86/turbostat/turbostat.c | |||
@@ -223,6 +223,8 @@ void print_header(void) | |||
223 | if (has_aperf) | 223 | if (has_aperf) |
224 | outp += sprintf(outp, " GHz"); | 224 | outp += sprintf(outp, " GHz"); |
225 | outp += sprintf(outp, " TSC"); | 225 | outp += sprintf(outp, " TSC"); |
226 | if (extra_msr_offset) | ||
227 | outp += sprintf(outp, " MSR 0x%04X", extra_msr_offset); | ||
226 | if (do_nhm_cstates) | 228 | if (do_nhm_cstates) |
227 | outp += sprintf(outp, " %%c1"); | 229 | outp += sprintf(outp, " %%c1"); |
228 | if (do_nhm_cstates) | 230 | if (do_nhm_cstates) |
@@ -239,8 +241,6 @@ void print_header(void) | |||
239 | outp += sprintf(outp, " %%pc6"); | 241 | outp += sprintf(outp, " %%pc6"); |
240 | if (do_snb_cstates) | 242 | if (do_snb_cstates) |
241 | outp += sprintf(outp, " %%pc7"); | 243 | outp += sprintf(outp, " %%pc7"); |
242 | if (extra_msr_offset) | ||
243 | outp += sprintf(outp, " MSR 0x%x ", extra_msr_offset); | ||
244 | 244 | ||
245 | outp += sprintf(outp, "\n"); | 245 | outp += sprintf(outp, "\n"); |
246 | } | 246 | } |
@@ -361,6 +361,10 @@ int format_counters(struct thread_data *t, struct core_data *c, | |||
361 | /* TSC */ | 361 | /* TSC */ |
362 | outp += sprintf(outp, "%5.2f", 1.0 * t->tsc/units/interval_float); | 362 | outp += sprintf(outp, "%5.2f", 1.0 * t->tsc/units/interval_float); |
363 | 363 | ||
364 | /* MSR */ | ||
365 | if (extra_msr_offset) | ||
366 | outp += sprintf(outp, " 0x%016llx", t->extra_msr); | ||
367 | |||
364 | if (do_nhm_cstates) { | 368 | if (do_nhm_cstates) { |
365 | if (!skip_c1) | 369 | if (!skip_c1) |
366 | outp += sprintf(outp, " %6.2f", 100.0 * t->c1/t->tsc); | 370 | outp += sprintf(outp, " %6.2f", 100.0 * t->c1/t->tsc); |
@@ -392,8 +396,6 @@ int format_counters(struct thread_data *t, struct core_data *c, | |||
392 | if (do_snb_cstates) | 396 | if (do_snb_cstates) |
393 | outp += sprintf(outp, " %6.2f", 100.0 * p->pc7/t->tsc); | 397 | outp += sprintf(outp, " %6.2f", 100.0 * p->pc7/t->tsc); |
394 | done: | 398 | done: |
395 | if (extra_msr_offset) | ||
396 | outp += sprintf(outp, " 0x%016llx", t->extra_msr); | ||
397 | outp += sprintf(outp, "\n"); | 399 | outp += sprintf(outp, "\n"); |
398 | 400 | ||
399 | return 0; | 401 | return 0; |