We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5165c17 commit c9aaf1bCopy full SHA for c9aaf1b
arch/powerpc/platforms/pseries/lpar.c
@@ -662,8 +662,12 @@ u64 pseries_paravirt_steal_clock(int cpu)
662
{
663
struct lppaca *lppaca = &lppaca_of(cpu);
664
665
- return be64_to_cpu(READ_ONCE(lppaca->enqueue_dispatch_tb)) +
666
- be64_to_cpu(READ_ONCE(lppaca->ready_enqueue_tb));
+ /*
+ * VPA steal time counters are reported at TB frequency. Hence do a
667
+ * conversion to ns before returning
668
+ */
669
+ return tb_to_ns(be64_to_cpu(READ_ONCE(lppaca->enqueue_dispatch_tb)) +
670
+ be64_to_cpu(READ_ONCE(lppaca->ready_enqueue_tb)));
671
}
672
#endif
673
0 commit comments