Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp1631277imm; Thu, 18 Oct 2018 01:17:10 -0700 (PDT) X-Google-Smtp-Source: ACcGV62kOICMTDxFnP1o568NIT8i4Ox3Iw+YWazSyK+eKs/WdN1E3gfYhdpipCpcwIJYH+B94cLy X-Received: by 2002:a62:4799:: with SMTP id p25-v6mr29575334pfi.197.1539850630852; Thu, 18 Oct 2018 01:17:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1539850630; cv=none; d=google.com; s=arc-20160816; b=dpMGbVu8gRU9mA8BfbM3RXLgcm8SO2KaFNSFVmQr2L2XXmoQayfahas9E+VS+WhJFB XBVKKX8XjtvfXeE//XsWQWkBtuMv/aqLK1JgkvlJ5yi7K1IcCFIySV8imtiS2ryvC67V LahGAtR5X7bOZz14+owHj78Xcw0TNyES5Boz0yuw+uqmX3KmDQO0MFuqSW4JN1CRY7If 5IpKA8N8rhEplFgnFY9W90/1PDUB9ZMf1J8+jlskDeM/1MlbDNNcVhqS5zn/BImafX08 kOyFq9PrZxCkYhINgFTJw73ssGjObzd5n0cgIkZ22oU6Vv4uDrIFaupdhYlkdBjTk8mk Pvxw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version; bh=rZKFmPC9IalVIT7m9226OSd7RJ+swyggK4K3FEGQKRk=; b=A2PTMZ/KR2RMvsr5HxA/G6ihRcPhKOTpdwdlb/Bgtgr7NHM8I5Of5e97ONi2Ht513z qdfj41Xrcigmy61IbwBNKqVvG39cgtEuSmdQmXJ+OlhyzpJrubuZSQY5ZEX7ihVYNM2w vRmCXvPWcjA4wwWRcAiz5Up6UtSBQRZSsrWB2WDj9v8cKkEiRQo/XgFFfjm6rscoJNje eQM9GjFEQPmpT6w1RE5Mp7z0bJInbvoJKoLmberEdxRv7Ky7xxIUazS27rUWx1zdvjFS SRsvhxaphumQkf59N5Nxqwh18X6zznmq3YQt/+VWBtRcQmlAsMZLR9sqBG2nrq1MwvaY WTSA== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i23-v6si20234663pgl.230.2018.10.18.01.16.54; Thu, 18 Oct 2018 01:17:10 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727708AbeJRQOa (ORCPT + 99 others); Thu, 18 Oct 2018 12:14:30 -0400 Received: from mail-ot1-f67.google.com ([209.85.210.67]:38396 "EHLO mail-ot1-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727376AbeJRQOa (ORCPT ); Thu, 18 Oct 2018 12:14:30 -0400 Received: by mail-ot1-f67.google.com with SMTP id l1so28906339otj.5; Thu, 18 Oct 2018 01:14:39 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=rZKFmPC9IalVIT7m9226OSd7RJ+swyggK4K3FEGQKRk=; b=CNzplIOiFw4vQ48rkOIdjm2y5kqog21KiKbWpineJVmzu5ZUkp2g7TqfRk/i22jGVz YiwhqllNS7FLBlScVcuOgqqR8Seo3Ewixa9fDKtfRIp8JkGP1yfg/YglIR2NMA/720Dt RPbpxH79IDHASSY6KTtFUfV6Ufn3NfiyrUzt0RYtW8eRIe3i61QRYKfkRtKYziXiOpJF T5/13K3Qu10CNJWiKTzDqnJp88m4zMIxinIg7zBRW3eOJagoXguIoRVfdFCYYKF92O4z c6HUf0sqIvRswfpoNQHj6Pvnh0VzdTSTskbQHFvi/KOcl03u5vqLdQKzN1YmtvZLkt+D mTpw== X-Gm-Message-State: ABuFfoh13lznPpKWmkyWliRGzxMHgUxu4A7MtrNWkbdX+ptDG5lQrak8 heg8Bz1KCr6wl9313pu5tXcTgOksY3/lzNryRYQ= X-Received: by 2002:a9d:538c:: with SMTP id w12mr19648054otg.139.1539850479302; Thu, 18 Oct 2018 01:14:39 -0700 (PDT) MIME-Version: 1.0 References: <1539102302-9057-1-git-send-email-thara.gopinath@linaro.org> <20181010061751.GA37224@gmail.com> <5BBE1E1F.3030308@linaro.org> <20181016073305.GA64994@gmail.com> <5BC76181.90105@linaro.org> <20181018064849.GA42813@gmail.com> <20181018075033.GA58819@gmail.com> In-Reply-To: <20181018075033.GA58819@gmail.com> From: "Rafael J. Wysocki" Date: Thu, 18 Oct 2018 10:14:28 +0200 Message-ID: Subject: Re: [RFC PATCH 0/7] Introduce thermal pressure To: Ingo Molnar Cc: "Rafael J. Wysocki" , Thara Gopinath , Linux Kernel Mailing List , Ingo Molnar , Peter Zijlstra , "Zhang, Rui" , Greg Kroah-Hartman , Amit Kachhap , Viresh Kumar , Javi Merino , Eduardo Valentin , Daniel Lezcano , Linux PM , Quentin Perret , ionela.voinescu@arm.com, Vincent Guittot Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Oct 18, 2018 at 9:50 AM Ingo Molnar wrote: > > > * Rafael J. Wysocki wrote: > > > > The only long term maintainable solution is to move all high level > > > cpufreq logic and policy handling code into kernel/sched/cpufreq*.c, > > > which has been done to a fair degree already in the past ~2 years - but > > > it's unclear to me to what extent this is true for thermal throttling > > > policy currently: there might be more governor surgery and code > > > reshuffling required? > > > > It doesn't cover thermal management directly ATM. > > > > The EAS work kind of hopes to make a connection in there by adding a > > common energy model to underlie both the performance scaling and > > thermal management, but it doesn't change the thermal decision making > > part AFAICS. > > > > So it is fair to say that additional governor surgery and code > > reshuffling will be required IMO. > > BTW., when factoring out high level thermal management code it might make > sense to increase the prominence of the cpufreq code within the scheduler > and organize it a bit better, by introducing its own > kernel/sched/cpufreq/ directory and renaming things the following way: > > kernel/sched/cpufreq.c => kernel/sched/cpufreq/core.c > kernel/sched/cpufreq_schedutil.c => kernel/sched/cpufreq/metrics.c > kernel/sched/thermal.c => kernel/sched/cpufreq/thermal.c > > ... or so? > > With no change to functionality, this is just a re-organization and > expansion/preparation for the bright future. =B-) No disagreement here. :-) Cheers, Rafael