Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751937AbcKGHdS (ORCPT ); Mon, 7 Nov 2016 02:33:18 -0500 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:55721 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750953AbcKGHdQ (ORCPT ); Mon, 7 Nov 2016 02:33:16 -0500 From: Akshay Adiga To: Viresh Kumar Subject: Re: [PATCH 2/2] cpufreq: powernv: Use PMSR to verify global and local pstate References: <1478237255-4258-1-git-send-email-akshay.adiga@linux.vnet.ibm.com> <1478237255-4258-2-git-send-email-akshay.adiga@linux.vnet.ibm.com> <20161104064132.GB3414@vireshk-i7> Cc: linuxppc-dev@lists.ozlabs.org, rjw@rjwysocki.net, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org Date: Mon, 7 Nov 2016 13:02:10 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: <20161104064132.GB3414@vireshk-i7> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 16110707-0008-0000-0000-000000DABB92 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 16110707-0009-0000-0000-0000086DE77B Message-Id: X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2016-11-07_02:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=10 spamscore=10 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1609300000 definitions=main-1611070143 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1281 Lines: 40 Thanks Viresh for taking a look at it. I will make the mentioned changes in the next version of the patch and will add Shilpa and Gautham to the mail chain. Regards Akshay Adiga On 11/04/2016 12:11 PM, Viresh Kumar wrote: > On 04-11-16, 10:57, Akshay Adiga wrote: >> As fast_switch may get called in interrupt disable mode, it does not > s/in interrupt disable mode/with interrupts disabled > s/it does/it may > >> update the global_pstate_info data structure. Hence the global_pstate_info >> has stale data whenever pstate is updated through fast_swtich(). > s/has/may have > s/swtich/switch > >> So the gpstate_timer can fire after a fast_switch() call has update > s/So the/The > s/a fast_swtich() call has update/the fast_switch() call has updated > >> the pstates to a different value. Hence the timer handler cannot rely >> on the cached values of local and global pstate and needs to read it >> from the PMSR. >> >> Signed-off-by: Akshay Adiga >> >> --- >> drivers/cpufreq/powernv-cpufreq.c | 32 ++++++++++++++++++++++---------- >> 1 file changed, 22 insertions(+), 10 deletions(-) > I am not the best guy to judge the code changes here. Can you please include > Shilpa and Gautham to the mail chain and get there feedback. > > >