Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp3822699imm; Tue, 29 May 2018 14:33:03 -0700 (PDT) X-Google-Smtp-Source: ADUXVKIL8fAqj/8E+APpiZzVRCuIeiSlH9Y8DwdAj26DboP+leMM0HvYiM6ple9xET7fhharZxAe X-Received: by 2002:a65:5d8e:: with SMTP id f14-v6mr80601pgt.25.1527629583213; Tue, 29 May 2018 14:33:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1527629583; cv=none; d=google.com; s=arc-20160816; b=SwGpA35UUpX5hkc51Sg0izDl+MuuHp97EfKIp4tuD0EUtuL8Z7yNB3DK0tw94iPdFc NZY7+xmn2QvGNzaMXMC2bajBk1b3YG7HZwdoZFDI+xj5/K8p27Lyxe+qSNnuV/ayR7BL 6njBmizj0GEFnChT0IcXj8lSD5XUMrMMeW7a5+dScLlosxoccYPE1fAPIMsK/THQRlAz vwt78BaCsNRhRDh/nTMvOQgmRPrf7b/sSC7pAHapaf3NdhQUZhgTxlxJATFmKXf0WAqx GpQcY/CrVHXDqcL6QC2Ag/0XYmzwFuP6+y+a8hPKpycE+w02OdWDIwQ7/LKF9WHDaU7w BEIw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=1V1tX3Y+hmCgUjRART4mJA/C2YOJyzpVtTGM55FnuOE=; b=KORBllQG/vIcNEblt0Bo0HLjs2r3IZzyu8n1X3aywKF3XLRluIfxK3Tv50q1ZQTj64 lkPlnMi56wQu4v+nYekCQ6nX4/XtQT7L2xPsbVSijKjymSSK+y+fzkf1Df1T6iuOmq90 +JEQmqbx58UVcA5G7O4T0j9LLmPBBDCdDe1H4CNrkfzloC63BT13SXzwrUFTDc3SkAaA YWhuWcDoMxWalb4IPIgkj5pN4pdUzu3CmmCcAQTDYneYnmtceFgLY3WhatGwGudZ/PVn jxQls7tDh9hDT7OxgzKXUNidSPWj9DufmoC3lQZ3ROBqHllQpEiCIlExHL3uyukonSLY 4a6A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=dG8aod5A; 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=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a18-v6si26434648pgu.59.2018.05.29.14.32.49; Tue, 29 May 2018 14:33:03 -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=@chromium.org header.s=google header.b=dG8aod5A; 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=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S967290AbeE2Vav (ORCPT + 99 others); Tue, 29 May 2018 17:30:51 -0400 Received: from mail-pf0-f195.google.com ([209.85.192.195]:45371 "EHLO mail-pf0-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S966945AbeE2Vat (ORCPT ); Tue, 29 May 2018 17:30:49 -0400 Received: by mail-pf0-f195.google.com with SMTP id c10-v6so7888039pfi.12 for ; Tue, 29 May 2018 14:30:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=1V1tX3Y+hmCgUjRART4mJA/C2YOJyzpVtTGM55FnuOE=; b=dG8aod5AxcE3l5q7Wp3VNFLkkZwfQyVllj7VT8F29p1OKrFzf6TbNmhBo3hB/8mkgA BmdX5jD5eycbpMcllepmTx8MU2XNww90Gtk/w8eIRQerrBusbygoii/5E8KnkVAcz/Ls 4XAjtDWHdTg+2Ku7I1zwoP2BE4QBd8BQI8J/o= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=1V1tX3Y+hmCgUjRART4mJA/C2YOJyzpVtTGM55FnuOE=; b=QxfMNa6g237rSUb7E2xMESHMXWCG2J6f7SsCK7Ly7y5upkjGCfOqrUVLqBTgsLe7+i jNQ1yti6uOmM6y0u3J1c3uTp6OKJzVx2O1w0cLtjrXB7JiGe/M8htkrIg2jT6ZYiSzGx ePzCxitA7kEJ1NcaRDo+jkfKD1wZuovIukbRE2lKWbynM2XxbfRdp5FGL5F7ZmbRzJnp zGH+xiRJlg21Ws4awjOBeftF179dlZv7KZvE1PI0jb+7VwlFJ6gyCnh2ar/Fr1ivWP7Z BIOvshMWFqHACs1D3MrO8imCyRilkxDTQUahM+Vx/kn6TnMW1HicBG/a5x2bBV8oVWhp y7wQ== X-Gm-Message-State: ALKqPwefAi+wACm/Vo8X0O/U7K30rbwAs8EoIbHyOGf3ceqBvOwl8kRt GVgK8G7t1zueyG08jmZp6SuMmQ== X-Received: by 2002:a65:6592:: with SMTP id u18-v6mr78134pgv.366.1527629449055; Tue, 29 May 2018 14:30:49 -0700 (PDT) Received: from localhost ([2620:0:1000:1501:8e2d:4727:1211:622]) by smtp.gmail.com with ESMTPSA id z68-v6sm20071655pff.177.2018.05.29.14.30.48 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 29 May 2018 14:30:48 -0700 (PDT) Date: Tue, 29 May 2018 14:30:47 -0700 From: Matthias Kaehlcke To: Greg Kroah-Hartman Cc: MyungJoo Ham , Kyungmin Park , Chanwoo Choi , Arnd Bergmann , Rob Herring , Mark Rutland , linux-pm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Brian Norris , Douglas Anderson Subject: Re: [PATCH 09/11] misc: throttler: Add core support for non-thermal throttling Message-ID: <20180529213047.GK168650@google.com> References: <20180525203043.249193-1-mka@chromium.org> <20180525203043.249193-10-mka@chromium.org> <20180528080826.GA17162@kroah.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20180528080826.GA17162@kroah.com> User-Agent: Mutt/1.9.2 (2017-12-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, May 28, 2018 at 10:08:26AM +0200, Greg Kroah-Hartman wrote: > On Fri, May 25, 2018 at 01:30:41PM -0700, Matthias Kaehlcke wrote: > > diff --git a/drivers/misc/Makefile b/drivers/misc/Makefile > > index 20be70c3f118..01a1714dd2ad 100644 > > --- a/drivers/misc/Makefile > > +++ b/drivers/misc/Makefile > > @@ -57,3 +57,4 @@ obj-$(CONFIG_ASPEED_LPC_SNOOP) += aspeed-lpc-snoop.o > > obj-$(CONFIG_PCI_ENDPOINT_TEST) += pci_endpoint_test.o > > obj-$(CONFIG_OCXL) += ocxl/ > > obj-$(CONFIG_MISC_RTSX) += cardreader/ > > +obj-y += throttler/ > > Shouldn't you depend on a Kconfig option to traverse into this > directory? Ack > > diff --git a/drivers/misc/throttler/Kconfig b/drivers/misc/throttler/Kconfig > > new file mode 100644 > > index 000000000000..ef8388f6bc0a > > --- /dev/null > > +++ b/drivers/misc/throttler/Kconfig > > @@ -0,0 +1,13 @@ > > +menuconfig THROTTLER > > + bool "Throttler support" > > + default n > > the default is always 'n' no need to say it again here :) Will remove > > + depends on OF > > + select CPU_FREQ > > + select PM_DEVFREQ > > + help > > + This option enables core support for non-thermal throttling of CPUs > > + and devfreq devices. > > + > > + Note that you also need a event monitor module usually called > > + *_throttler. > > + > > diff --git a/drivers/misc/throttler/Makefile b/drivers/misc/throttler/Makefile > > new file mode 100644 > > index 000000000000..c8d920cee315 > > --- /dev/null > > +++ b/drivers/misc/throttler/Makefile > > @@ -0,0 +1 @@ > > +obj-$(CONFIG_THROTTLER) += core.o > > diff --git a/drivers/misc/throttler/core.c b/drivers/misc/throttler/core.c > > new file mode 100644 > > index 000000000000..c058d03212b8 > > --- /dev/null > > +++ b/drivers/misc/throttler/core.c > > @@ -0,0 +1,373 @@ > > +/* > > + * Core code for non-thermal throttling > > + * > > + * Copyright (C) 2018 Google, Inc. > > + * > > + * This software is licensed under the terms of the GNU General Public > > + * License version 2, as published by the Free Software Foundation, and > > + * may be copied, distributed, and modified under those terms. > > + * > > + * This program is distributed in the hope that it will be useful, > > + * but WITHOUT ANY WARRANTY; without even the implied warranty of > > + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the > > + * GNU General Public License for more details. > > + * > > + */ > > Please just use a single SPDX line, like checkpatch.pl would have warned > you about. No need for the full verbous license boiler-plate text here > at all. Ok