linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] cpufreq: powernv: Return the actual CPU frequency in /proc/cpuinfo
@ 2017-10-06  7:24 Shriya
  2017-10-06 10:30 ` Michael Ellerman
  2017-11-16 15:14 ` Nicholas Piggin
  0 siblings, 2 replies; 4+ messages in thread
From: Shriya @ 2017-10-06  7:24 UTC (permalink / raw)
  To: linux-kernel, linuxppc-dev, mpe, paulus; +Cc: mikey, aneesh.kumar, ego, Shriya

Make /proc/cpuinfo read the frequency of the CPU it is running at
instead of reading the cached value of the last requested frequency.
In conditions like WOF/throttle CPU can be running at a different
frequency than the requested frequency.

Signed-off-by: Shriya <shriyak@linux.vnet.ibm.com>
---
 arch/powerpc/platforms/powernv/setup.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/powerpc/platforms/powernv/setup.c b/arch/powerpc/platforms/powernv/setup.c
index 897aa14..55ea4bf 100644
--- a/arch/powerpc/platforms/powernv/setup.c
+++ b/arch/powerpc/platforms/powernv/setup.c
@@ -311,7 +311,7 @@ static unsigned long pnv_get_proc_freq(unsigned int cpu)
 {
 	unsigned long ret_freq;
 
-	ret_freq = cpufreq_quick_get(cpu) * 1000ul;
+	ret_freq = cpufreq_get(cpu) * 1000ul;
 
 	/*
 	 * If the backend cpufreq driver does not exist,
-- 
1.9.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2017-11-16 15:15 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-06  7:24 [PATCH] cpufreq: powernv: Return the actual CPU frequency in /proc/cpuinfo Shriya
2017-10-06 10:30 ` Michael Ellerman
2017-10-06 11:22   ` shriyak
2017-11-16 15:14 ` Nicholas Piggin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).