From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751915AbdJFKam (ORCPT ); Fri, 6 Oct 2017 06:30:42 -0400 Received: from ozlabs.org ([103.22.144.67]:44271 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751702AbdJFKaj (ORCPT ); Fri, 6 Oct 2017 06:30:39 -0400 From: Michael Ellerman To: Shriya , linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, paulus@samba.org Cc: mikey@neuling.org, aneesh.kumar@linux.vnet.ibm.com, ego@linux.vnet.ibm.com, Shriya Subject: Re: [PATCH] cpufreq: powernv: Return the actual CPU frequency in /proc/cpuinfo In-Reply-To: <1507274648-14221-1-git-send-email-shriyak@linux.vnet.ibm.com> References: <1507274648-14221-1-git-send-email-shriyak@linux.vnet.ibm.com> Date: Fri, 06 Oct 2017 21:30:36 +1100 Message-ID: <87mv544lgz.fsf@concordia.ellerman.id.au> MIME-Version: 1.0 Content-Type: text/plain Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Shriya writes: > 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. Sounds like a bug fix to me ? cheers > 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