linux-arm-msm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Rafael J. Wysocki" <rafael@kernel.org>
To: Amit Kucheria <amit.kucheria@linaro.org>
Cc: Viresh Kumar <viresh.kumar@linaro.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	linux-arm-msm <linux-arm-msm@vger.kernel.org>,
	Eduardo Valentin <edubezval@gmail.com>,
	Stephen Boyd <swboyd@chromium.org>,
	Doug Anderson <dianders@chromium.org>,
	Matthias Kaehlcke <mka@chromium.org>,
	Zhang Rui <rui.zhang@intel.com>,
	Daniel Lezcano <daniel.lezcano@linaro.org>,
	Linux PM list <linux-pm@vger.kernel.org>
Subject: Re: [PATCH v2 1/9] thermal: cpu_cooling: Require thermal core to be compiled in
Date: Wed, 23 Jan 2019 11:54:15 +0100	[thread overview]
Message-ID: <CAJZ5v0hhjDpSgizMazsbXiOyEhycyVihdMmsT_i7eAQ7K6vqAA@mail.gmail.com> (raw)
In-Reply-To: <CAP245DWTyaOFhS3SYwAmLGpczQo9JR+gsDbGdHAnoxpTWayjgg@mail.gmail.com>

On Wed, Jan 23, 2019 at 11:53 AM Amit Kucheria <amit.kucheria@linaro.org> wrote:
>
> On Wed, Jan 23, 2019 at 4:04 PM Viresh Kumar <viresh.kumar@linaro.org> wrote:
> >
> > On 21-01-19, 21:10, Amit Kucheria wrote:
> > > The CPU cooling driver (cpu_cooling.c) allows the platform's cpufreq
> > > driver to register as a cooling device and cool down the platform by
> > > throttling the CPU frequency. In order to be able to auto-register a
> > > cpufreq driver as a cooling device from the cpufreq core, we need access
> > > to code inside cpu_cooling.c which, in turn, accesses code inside
> > > thermal core.
> > >
> > > CPU_FREQ is a bool while THERMAL is tristate.  In some configurations
> > > (e.g. allmodconfig), CONFIG_THERMAL ends up as a module while
> > > CONFIG_CPU_FREQ is compiled in. This leads to following error:
> > >
> > > drivers/cpufreq/cpufreq.o: In function `cpufreq_offline':
> > > cpufreq.c:(.text+0x407c): undefined reference to `cpufreq_cooling_unregister'
> > > drivers/cpufreq/cpufreq.o: In function `cpufreq_online':
> > > cpufreq.c:(.text+0x70c0): undefined reference to `of_cpufreq_cooling_register'
> > >
> > > Given that platforms using CPU_THERMAL usually want it compiled-in so it
> > > is available early in boot, make CPU_THERMAL depend on THERMAL being
> > > compiled-in instead of allowing it to be a module.
> > >
> > > Suggested-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> > > Signed-off-by: Amit Kucheria <amit.kucheria@linaro.org>
> > > ---
> > >  drivers/thermal/Kconfig | 1 +
> > >  1 file changed, 1 insertion(+)
> > >
> > > diff --git a/drivers/thermal/Kconfig b/drivers/thermal/Kconfig
> > > index 30323426902e..58bb7d72dc2b 100644
> > > --- a/drivers/thermal/Kconfig
> > > +++ b/drivers/thermal/Kconfig
> > > @@ -152,6 +152,7 @@ config CPU_THERMAL
> > >       bool "generic cpu cooling support"
> > >       depends on CPU_FREQ
> > >       depends on THERMAL_OF
> > > +     depends on THERMAL=y
> > >       help
> > >         This implements the generic cpu cooling mechanism through frequency
> > >         reduction. An ACPI version of this already exists
> >
> > Please remove all Kconfig crap, which gets fixed with this, as well in
> > this patch itself. Like:
>
> OK, I planned to if/when this series was accepted. Will send out a patch.

You can make it part of this series, though.

  reply	other threads:[~2019-01-23 10:54 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-21 15:40 [PATCH v2 0/9] cpufreq: Add flag to auto-register as cooling Amit Kucheria
2019-01-21 15:40 ` [PATCH v2 1/9] thermal: cpu_cooling: Require thermal core to be compiled in Amit Kucheria
2019-01-23 10:34   ` Viresh Kumar
2019-01-23 10:52     ` Amit Kucheria
2019-01-23 10:54       ` Rafael J. Wysocki [this message]
2019-01-21 15:40 ` [PATCH v2 2/9] cpufreq: Auto-register the driver as a thermal cooling device if asked Amit Kucheria
2019-01-23 10:36   ` Viresh Kumar
2019-01-23 10:39     ` Rafael J. Wysocki
2019-01-23 10:43       ` Viresh Kumar
2019-01-23 10:44         ` Viresh Kumar
2019-01-23 10:53           ` Rafael J. Wysocki
2019-01-21 15:40 ` [PATCH v2 3/9] cpufreq: qcom-hw: Register as a cpufreq cooling device Amit Kucheria
2019-01-21 15:40 ` [PATCH v2 4/9] cpufreq: imx6q: Use auto-registration of thermal " Amit Kucheria
2019-01-21 15:40 ` [PATCH v2 5/9] cpufreq: cpufreq-dt: " Amit Kucheria
2019-01-21 15:40 ` [PATCH v2 6/9] cpufreq: mediatek: " Amit Kucheria
2019-01-21 15:40 ` [PATCH v2 7/9] cpufreq: qoriq: " Amit Kucheria
2019-01-21 15:40 ` [PATCH v2 8/9] cpufreq: scmi: " Amit Kucheria
2019-01-21 15:40 ` [PATCH v2 9/9] cpufreq: scpi: " Amit Kucheria

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAJZ5v0hhjDpSgizMazsbXiOyEhycyVihdMmsT_i7eAQ7K6vqAA@mail.gmail.com \
    --to=rafael@kernel.org \
    --cc=amit.kucheria@linaro.org \
    --cc=daniel.lezcano@linaro.org \
    --cc=dianders@chromium.org \
    --cc=edubezval@gmail.com \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=mka@chromium.org \
    --cc=rui.zhang@intel.com \
    --cc=swboyd@chromium.org \
    --cc=viresh.kumar@linaro.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).