Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp3937369ybp; Sun, 13 Oct 2019 18:00:50 -0700 (PDT) X-Google-Smtp-Source: APXvYqzyF3SNcMl7HgxoudN3KXIS6dxWZI/odV6pp75C37T4tZfwCsnFyDMZAteU1tzRfobq2SsL X-Received: by 2002:a17:906:f54:: with SMTP id h20mr26637652ejj.55.1571014850126; Sun, 13 Oct 2019 18:00:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1571014850; cv=none; d=google.com; s=arc-20160816; b=Qp2EL0jk4HTcB53iUbzfPH07O1SB+jgrGt+9b2PR/WpgPefU00avWGx7eRp5sKJfL4 dE5BzRdsRkx+VZ6uHaFxv2O2oYi5TJlvQW/nw5x+mhVkYBiVubePNCStNvGJJA9y3gx4 9AkXqFmGiqSwjqFmEgz/zxtt6QeAYqySL1yxy2/XMzOiNoRQVOH99VzqVBeAXzk3yARF 6N55mrnyG3gLAAuPHI6MxrB2l++kyxrN010viZiPx7Qc205ZWXn22+Bx6BpLUmQJuMlV 8CgSxKDbJbVxrE37IiZhWTpYqGxeI7bNtBjRy1Xyu2zydkPOObhDeS/mtlC44RYmA1nM JBHg== 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=wKxSPMl7EPM6ok8Zx7OEY5cb3mUO9ZZjqXNAqG0TCKE=; b=fo+yJkkF0SVr4GLV/JbQ5U5xjogxqg+ojDwNtVAM64RwSJ1TNV/o+qIhfSaDdGfVYj j0rpPg0hSo8ijk8z8T2cHE3IAobAoBqPlzw+ln7PVx/2UPfvoDB6W4UVL1ZOSiUhECGg vlgMWJJ0XplkuR3rFcpe4h2WPTDoJquXWxm4V6jPb1H2h9pYkWDyLhKnWubXfbTUw89b N5Ch93Sa4tmAa3Hp1hIXoWtiojUHOnG1/j4kjiDZjCUqezo8yFbO7OT+B2TjvjOm0xbl tewLRv51yx5l+PCWETm3t+s3W2T/Vw3ngpQJqRHjmRjJP96e0k+SdWxgga95FBxjGDLY 8SBw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=UZR7YFFW; 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 l2si9934772ejh.389.2019.10.13.18.00.26; Sun, 13 Oct 2019 18:00:50 -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=UZR7YFFW; 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 S1729757AbfJNA6f (ORCPT + 99 others); Sun, 13 Oct 2019 20:58:35 -0400 Received: from mail-qk1-f196.google.com ([209.85.222.196]:42757 "EHLO mail-qk1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729737AbfJNA6d (ORCPT ); Sun, 13 Oct 2019 20:58:33 -0400 Received: by mail-qk1-f196.google.com with SMTP id f16so14444226qkl.9 for ; Sun, 13 Oct 2019 17:58:33 -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=wKxSPMl7EPM6ok8Zx7OEY5cb3mUO9ZZjqXNAqG0TCKE=; b=UZR7YFFWzMKcXxJ9dqs7MxnGNzG8a7Oahd6jRqFl17qBcCT2ZZTsf+ArewfUbYNN+w Ie8AcxY33Y6pyzpr/3teLmy1IwRmU7b0QhxBlBYeo9FkFGYVz8h8y1wOlMNtR3eiV+1n vDDQAAfmtw6It/CQwfDk/a7jXhEmgp3zCroGxG4kG3abDt+C67s+xYPDcAh+895sxAyE L3oG7HBa4PHAEqOvkm9oaysZ4yty+HdaN/tt9fy7iBthAPqEJwqyuuCVotRANKOGRYlv kB8pXhZfN5NWRpQ7hyyiMivjBtviVDArOVvvwojB6OQrJ57+co6nbh9wnGh9OjsD2EUG lCjg== 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=wKxSPMl7EPM6ok8Zx7OEY5cb3mUO9ZZjqXNAqG0TCKE=; b=izSqWoTALjHowtHc15XrWoQ/Ih4ewwzi0VrtaFavG2D2soh9LM4WBuumgrU0QXOtsN bW1JzQ9nJRhmSsG3bcR5WWOMGhupOy24zBivDklICWOcoFuKke3SiuYU+LPC5ef7ZTBm ZuNHPsvoQjhMJJF/wSIXgH0ZNvNOGOkqdFWlVq6naJWESfQnsbnDMutE6BUgPT0g1Hw5 aLtgofSeZ7hZx4EQNA16dC9OxTeJZoGhKiLXgQYhQnGid8kG/m+v8Py3ONkRn4vi/Isg D3KElhji/atRPygOTw7tQscn0NNF4Gvtj5hFvWnaJpISJ6FV8nuOc968tF8txRTVs737 RdXA== X-Gm-Message-State: APjAAAWFVILKG4NxAiNmyVlNA/+qRbUO+RGZ7CHiV2jIL0uqs/aN6+GB 6T+VRhAZ2CEhTrUL4nSJM+tezg== X-Received: by 2002:a05:620a:696:: with SMTP id f22mr27017261qkh.91.1571014712537; Sun, 13 Oct 2019 17:58:32 -0700 (PDT) Received: from Thara-Work-Ubuntu.fios-router.home (pool-71-255-246-27.washdc.fios.verizon.net. [71.255.246.27]) by smtp.googlemail.com with ESMTPSA id c185sm7663901qkf.122.2019.10.13.17.58.31 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 13 Oct 2019 17:58:31 -0700 (PDT) From: Thara Gopinath To: mingo@redhat.com, peterz@infradead.org, ionela.voinescu@arm.com, vincent.guittot@linaro.org, rui.zhang@intel.com, edubezval@gmail.com Cc: linux-kernel@vger.kernel.org, amit.kachhap@gmail.com, javi.merino@kernel.org, daniel.lezcano@linaro.org Subject: [Patch v3 4/7] sched/fair: Enable CFS periodic tick to update thermal pressure Date: Sun, 13 Oct 2019 20:58:22 -0400 Message-Id: <1571014705-19646-5-git-send-email-thara.gopinath@linaro.org> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1571014705-19646-1-git-send-email-thara.gopinath@linaro.org> References: <1571014705-19646-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 Introduce support in CFS periodic tick to trigger the process of computing average thermal pressure for a cpu. Signed-off-by: Thara Gopinath --- kernel/sched/fair.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c index 83ab35e..fe7c165 100644 --- a/kernel/sched/fair.c +++ b/kernel/sched/fair.c @@ -21,6 +21,7 @@ * Copyright (C) 2007 Red Hat, Inc., Peter Zijlstra */ #include "sched.h" +#include "thermal.h" #include @@ -7566,6 +7567,8 @@ static void update_blocked_averages(int cpu) done = false; update_blocked_load_status(rq, !done); + + update_periodic_maxcap(rq); rq_unlock_irqrestore(rq, &rf); } @@ -9925,6 +9928,8 @@ static void task_tick_fair(struct rq *rq, struct task_struct *curr, int queued) update_misfit_status(curr, rq); update_overutilized_status(task_rq(curr)); + + update_periodic_maxcap(rq); } /* -- 2.1.4