Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp49785imj; Thu, 14 Feb 2019 15:07:21 -0800 (PST) X-Google-Smtp-Source: AHgI3IYGGTQ93q6MeXoPiJ/XhwwjVfjAiZnvA+tuwobU5gCBZIj6dPTrOhl9VIoSxo8yI7sikXLE X-Received: by 2002:a17:902:8f8d:: with SMTP id z13mr6712144plo.95.1550185641362; Thu, 14 Feb 2019 15:07:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550185641; cv=none; d=google.com; s=arc-20160816; b=zop0zJcAsB4yrim5wbNPMGP68nOHnUIfYLL6PCcGdUXSWWky9We4B8zAv0dSadAI5H QE9AcSVMYhWUlgwq9CFxuZxmnXwYc8pf1TgWHjgwC587qrXUEs8qNNMt5vjX2qJVLFB6 fZWVjoFbldrCeRnXo5yYCgdb179xuvKBgKkQPBfzLDgZc6We1Hm6K8hOdr/wI/1WPmic xbIwV14rshDJxow5jwR7KhEpputu87qwHGmXcfqqGPAk5i1Kj876F7mOLQzSsN2U457N T9gjuoI1s3e0jDWPGelyYo/ZJ+yc7D3G/OywSQm4B7UaYnasKWjG55WYARDu7c7mSI2n yn3Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:in-reply-to :mime-version:user-agent:date:message-id:from:cc:references:to :subject; bh=7iGs+26lA8EHVvXVOmFe2PQWK9Bl79NAXlyVcmOiPg4=; b=IW5Q1zyxG1ANkzY8LAxsdI2aBBqBPNMEn/Vra1uZ/9wSCdojYfr5TBbS46PGSD56KZ rUfvCPRots7/ntaozPNjezRjaaiNokq3Jqry66lbAMAkmkjVu/uf04+YDXQkfVHAKjVX nffSl/RUowCl5R7HLcCylJL14CaJSoykUK9pcKfTu0Zs8tQCAyz+Kh2zAFgkPXRT/pvZ XupPDNfLjEEwpF0Vf5uKqoU00PYhfTwX7Uu+nCV4yTfIWzi0vvFblaUQCD6e8VHmCC+I MvURkTHhpimgyWO2I9RR83cDW7oFp8fxYibH7n4aBXgPogeSss7qx0bEEeEXHRoSce+T KfSQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h6si3506435pgc.589.2019.02.14.15.06.39; Thu, 14 Feb 2019 15:07:21 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2437092AbfBNLkD (ORCPT + 99 others); Thu, 14 Feb 2019 06:40:03 -0500 Received: from szxga05-in.huawei.com ([45.249.212.191]:3726 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2388002AbfBNLkC (ORCPT ); Thu, 14 Feb 2019 06:40:02 -0500 Received: from DGGEMS414-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id ACFA64FFB4C498C3A9F2; Thu, 14 Feb 2019 19:39:37 +0800 (CST) Received: from [127.0.0.1] (10.202.227.238) by DGGEMS414-HUB.china.huawei.com (10.3.19.214) with Microsoft SMTP Server id 14.3.408.0; Thu, 14 Feb 2019 19:39:29 +0800 Subject: Re: [PATCH v2 0/2] Work around for Hisilicon CPPC cpufreq To: Xiongfeng Wang , , , , , , References: <1550130368-60513-1-git-send-email-wangxiongfeng2@huawei.com> CC: , , From: John Garry Message-ID: <2f397788-fcb0-a781-c497-9e698494f508@huawei.com> Date: Thu, 14 Feb 2019 11:39:22 +0000 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.3.0 MIME-Version: 1.0 In-Reply-To: <1550130368-60513-1-git-send-email-wangxiongfeng2@huawei.com> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.202.227.238] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 14/02/2019 07:46, Xiongfeng Wang wrote: > Hisilicon chips do not support delivered performance counter register > and reference performance counter register. But the platform can > calculate the real performance using its own method. This patch provide > a workaround for this problem, and other platforms can also use this > workaround framework. We reuse the desired performance register to > store the real performance calculated by the platform. After the > platform finished the frequency adjust, it gets the real performance and > writes it into desired performance register. OS can use it to calculate > the real frequency. > It would be convenient for reviewers to detail what changed between versions in future. John > Xiongfeng Wang (2): > ACPI / CPPC: Add a helper to get desired performance > cpufreq / cppc: Work around for Hisilicon CPPC cpufreq > > drivers/acpi/cppc_acpi.c | 38 +++++++++++++++++++++++ > drivers/cpufreq/cppc_cpufreq.c | 70 ++++++++++++++++++++++++++++++++++++++++++ > include/acpi/cppc_acpi.h | 1 + > 3 files changed, 109 insertions(+) >