Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp3499707yba; Tue, 16 Apr 2019 12:39:51 -0700 (PDT) X-Google-Smtp-Source: APXvYqwkCwT0ChuIPQFkCKkRJJypztCrs1Njx0GJN70A3uzwPxQHbAebIjw4aBSTYmTsEebuUwIp X-Received: by 2002:a62:5a42:: with SMTP id o63mr85672732pfb.170.1555443591705; Tue, 16 Apr 2019 12:39:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555443591; cv=none; d=google.com; s=arc-20160816; b=bgx1UNB7HRZ+cJjnF7usvUl++4CNmKhR5hwwrMtS4iGLZCzXxcVrCrIioqsxsr0TzX repUagcD8aMBhRlYQTQAe0vVpfjpXHUYuvzILkL551eJaB56pwFCPh1Zf8jhB3XiFXVq JqtqywBRN09/kmbcfWsSFI4m0bIu1BUCk3ArJwJY/mCN7tJCUmAS30h88BAVx1vS8kwX 6RHt/3YMln4zmN8JfDjy6Q2RRkmAeV76OayBHaRM49u8YW+puIjiW4eU+adIIYrG4ogW rNdku0TCvnR77H44B33FOgDntHetqDPS9Fu4J7E8gknpjuSB45uhsfAJcJSWFqyr9dFv Twjw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=DHvwucClEuE6vcfN7CuEc8eFK+qMiBspP3oOBK+KZZE=; b=kzw08srF4KT205vam/k1IsfMrwS3IcF4hyhPuMXmJ+nVgG7/hWCoA+Vi2iyfcZX5uU fNeJfROn7OONVAUC3tdkjIJbfHrldHKJOg8N9lFCmWXesxi2fzANMDw2QBwXP9CMMPrf CYIY70H2qOgORtQC/NVJ+NCEkj1H1qHFkVyP6mZ+At6V8NqhkdG6prQjko608+fvGCq9 kFcRr/hDMx8f3Y6CXPCkMF3mlhOK3J6o/IswPoq9L5DuAXFp+Jlw6Pkl907S01z7h+Vw AZQvyu5WIPEN0JMlviF6M7R9I/Pa0R3VtBn88Pt7vaUAV72jILnwY0wm1UYSg8K5fgzF 7yPQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="sL/wnHvm"; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id j30si48931575pgl.338.2019.04.16.12.39.35; Tue, 16 Apr 2019 12:39:51 -0700 (PDT) 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; dkim=pass header.i=@linaro.org header.s=google header.b="sL/wnHvm"; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730219AbfDPTiw (ORCPT + 99 others); Tue, 16 Apr 2019 15:38:52 -0400 Received: from mail-qt1-f195.google.com ([209.85.160.195]:36418 "EHLO mail-qt1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729925AbfDPTiu (ORCPT ); Tue, 16 Apr 2019 15:38:50 -0400 Received: by mail-qt1-f195.google.com with SMTP id s15so24745951qtn.3 for ; Tue, 16 Apr 2019 12:38:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=DHvwucClEuE6vcfN7CuEc8eFK+qMiBspP3oOBK+KZZE=; b=sL/wnHvmS8sJ5Cgb3Z/Ioo4m4Apbm4Eve1PwNIh0xYbgNh9Vq/AFdwbWhtBb2XDgcH U+XlSoQjehVMSTlhE4hbEZ7fsx9HJDnkExCEXL9rTkN9QiX16Y2FvKWTLyT4HumqseVu 3ejFYFn/9cM5kSutWvOF6wi2ClYNEOBzACNvN/CDnG329cP6gI53yhlzJRTjCSIQZuo7 6qA5W4s7vHgrSoYYlAMXt7iV6XhbeOTSAR2ztxVcDNpOh4+ysiRzXhm3XgUHRVQY6hRw t7RPjuVGg3NiDSZQXMlwDW5XqbAHI28D6/FSvuHTxGdAIBe5IgdW7a3r0lBMLh8AuB0O LhSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=DHvwucClEuE6vcfN7CuEc8eFK+qMiBspP3oOBK+KZZE=; b=rgRlBDYREevXegaD5BqZaz+VbktMkH01IBSczsa3/F4G7T4wNIFuWFt54vAnRlKxt0 t55shLH/bEphhxwpsRhL2KhuKoL87LlXVRmjMTaDrh3fyah0ziek6IzZWRogImHFuQVr mgvsuhv1mXSqkK7jy2y4p+aVgOU0MNipiMb3Pj1VSKufTWtmjSr4I/eg/N9/qsT0vxpn OKKf59oduSeeC7QVHJcaBmU5gcaR5PqaadKSIF7aL43XvQAaBokb3I3JGPx30b1WvA0n Vi/4e39SKvNtA2gil2vT8INar1xa+p7ROgwtssDuJFYHub1zBMqcSDZL3NLZ946gmfRe 9n2g== X-Gm-Message-State: APjAAAWx2o8RlIcnJW80l6h6TW+JtK2+YoOm/IBZwwa1kjE2wzrN/D0h YFPs3Hnxfjy7S2Kx8A5NuWmmHg== X-Received: by 2002:aed:3f49:: with SMTP id q9mr69900551qtf.279.1555443528979; Tue, 16 Apr 2019 12:38:48 -0700 (PDT) Received: from Thara-Work-Ubuntu.fios-router.home (pool-71-255-245-97.washdc.fios.verizon.net. [71.255.245.97]) by smtp.googlemail.com with ESMTPSA id k41sm46150797qtc.89.2019.04.16.12.38.47 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 16 Apr 2019 12:38:48 -0700 (PDT) From: Thara Gopinath To: mingo@redhat.com, peterz@infradead.org, rui.zhang@intel.com Cc: linux-kernel@vger.kernel.org, amit.kachhap@gmail.com, viresh.kumar@linaro.org, javi.merino@kernel.org, edubezval@gmail.com, daniel.lezcano@linaro.org, vincent.guittot@linaro.org, nicolas.dechesne@linaro.org, bjorn.andersson@linaro.org, dietmar.eggemann@arm.com Subject: [PATCH V3 3/3] thermal/cpu-cooling: Update thermal pressure in case of a maximum frequency capping Date: Tue, 16 Apr 2019 15:38:41 -0400 Message-Id: <1555443521-579-4-git-send-email-thara.gopinath@linaro.org> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1555443521-579-1-git-send-email-thara.gopinath@linaro.org> References: <1555443521-579-1-git-send-email-thara.gopinath@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Enable cpufreq cooling device to update the thermal pressure in event of a capped maximum frequency or removal of capped maximum frequency. Signed-off-by: Thara Gopinath --- drivers/thermal/cpu_cooling.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/thermal/cpu_cooling.c b/drivers/thermal/cpu_cooling.c index 6fff161..d5cc3c3 100644 --- a/drivers/thermal/cpu_cooling.c +++ b/drivers/thermal/cpu_cooling.c @@ -31,6 +31,7 @@ #include #include #include +#include #include @@ -177,6 +178,9 @@ static int cpufreq_thermal_notifier(struct notifier_block *nb, if (policy->max > clipped_freq) cpufreq_verify_within_limits(policy, 0, clipped_freq); + + sched_update_thermal_pressure(policy->cpus, + policy->max, policy->cpuinfo.max_freq); break; } mutex_unlock(&cooling_list_lock); -- 2.1.4