From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A9AC1C433F5 for ; Tue, 26 Oct 2021 16:52:28 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 69C79601FF for ; Tue, 26 Oct 2021 16:52:28 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 69C79601FF Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date: Message-ID:From:References:Cc:To:Subject:Reply-To:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:List-Owner; bh=z3tO3KBzo2pOJVUyzVg3eC8sGZDcMBS5SBKu3AS3i+c=; b=eCQ2vlCu32K+ihcry8Zw7E/NV+ 91VCq1hAY6g2IL0nObb0r7RFiWo2ewdLT8zr4suJekAMepT/v3iodQ37kl0jCCa+iVel3qbdc7Ajd ZdzpHrE37xKHeSTZVZgSX6RwibAbONm0IucyjbMI//nZNnbWCsU52U3hBAt/b0JtW6K59vvkv53qn UPg5gn+O5qhTiPpw+9OKHVwp/l+LI93bbyY6/o6Rm6w4bIUUbmhNCW+G+XQqK89EA1IC2UNco02HT r6kd69RG5YRe8pAquqoM9KQpRVAuAjWqdUFJ0FZS0Ydp+ZntSrkLAyBfm9LNG2Vjwv61YMkK2Se4W X/pAakBg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mfPfM-002X0t-RM; Tue, 26 Oct 2021 16:51:12 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1mfPfG-002WwI-0t for linux-arm-kernel@lists.infradead.org; Tue, 26 Oct 2021 16:51:07 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 0FCBE1FB; Tue, 26 Oct 2021 09:51:04 -0700 (PDT) Received: from [192.168.185.184] (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 6F9823F70D; Tue, 26 Oct 2021 09:50:59 -0700 (PDT) Subject: Re: [PATCH v2 2/5] thermal: cpufreq_cooling: Use new thermal pressure update function To: Lukasz Luba , linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org Cc: linux-arm-kernel@lists.infradead.org, linux-arm-msm@vger.kernel.org, sudeep.holla@arm.com, will@kernel.org, catalin.marinas@arm.com, linux@armlinux.org.uk, gregkh@linuxfoundation.org, rafael@kernel.org, viresh.kumar@linaro.org, amitk@kernel.org, daniel.lezcano@linaro.org, amit.kachhap@gmail.com, thara.gopinath@linaro.org, bjorn.andersson@linaro.org, agross@kernel.org References: <20211015144550.23719-1-lukasz.luba@arm.com> <20211015144550.23719-3-lukasz.luba@arm.com> From: Dietmar Eggemann Message-ID: <495d461a-d643-5dbf-7da8-74ddbdc486ca@arm.com> Date: Tue, 26 Oct 2021 18:51:18 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 MIME-Version: 1.0 In-Reply-To: <20211015144550.23719-3-lukasz.luba@arm.com> Content-Language: en-US X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20211026_095106_147721_99CA8852 X-CRM114-Status: UNSURE ( 8.82 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 15/10/2021 16:45, Lukasz Luba wrote: [...] > @@ -479,10 +478,7 @@ static int cpufreq_set_cur_state(struct thermal_cooling_device *cdev, > if (ret >= 0) { > cpufreq_cdev->cpufreq_state = state; > cpus = cpufreq_cdev->policy->related_cpus; > - max_capacity = arch_scale_cpu_capacity(cpumask_first(cpus)); > - capacity = frequency * max_capacity; > - capacity /= cpufreq_cdev->policy->cpuinfo.max_freq; Took me a while to realize that `cpufreq_cdev->policy->cpuinfo.max_freq` is 1000 * per_cpu(freq_factor, cpu), the latter being used now in arch_thermal_pressure_update(). Maybe worth mentioning in the patch header? _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel