[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-id: <20141117135142.6692c9d5@amdc2363>
Date: Mon, 17 Nov 2014 13:51:42 +0100
From: Lukasz Majewski <l.majewski@...sung.com>
To: Thierry Reding <thierry.reding@...il.com>
Cc: Mikko Perttunen <mikko.perttunen@...si.fi>,
Eduardo Valentin <edubezval@...il.com>,
Zhang Rui <rui.zhang@...el.com>,
Ezequiel Garcia <ezequiel.garcia@...e-electrons.com>,
Kuninori Morimoto <kuninori.morimoto.gx@...esas.com>,
Linux PM list <linux-pm@...r.kernel.org>,
Vincenzo Frascino <vincenzo.frascino@...com>,
Bartlomiej Zolnierkiewicz <b.zolnierkie@...sung.com>,
Lukasz Majewski <l.majewski@...ess.pl>,
Nobuhiro Iwamatsu <iwamatsu@...auri.org>,
Mikko Perttunen <mperttunen@...dia.com>,
Stephen Warren <swarren@...dotorg.org>,
Alexandre Courbot <gnurou@...il.com>,
linux-tegra@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 5/8] thermal:cpu cooling:tegra: Provide deferred probing
for tegra driver
Hi Thierry,
> On Fri, Nov 14, 2014 at 12:24:37PM +0100, Lukasz Majewski wrote:
> > Hi Mikko,
> >
> > > Tested-by: Mikko Perttunen <mikko.perttunen@...si.fi>
> >
> > Thanks for testing.
> >
> > >
> > > One potential issue I can see is that if the cpufreq driver fails
> > > to probe then you'll never get the thermal driver either. For
> > > example, Tegra124 currently has no cpufreq driver, so if
> > > CONFIG_CPU_THERMAL was enabled, then the soctherm driver would
> > > never be able to probe.
> >
> > Yes, this is a potential issue. However, this option in
> > tegra_defconfig is by default disabled when thermal is enabled.
>
> Not everybody uses tegra_defconfig for their kernel builds. In fact
> I'd imagine that the majority of kernels use a variant of
> multi_v7_defconfig and therefore CPU_THERMAL might get enabled
> irrespective of any Tegra support.
I see your point.
>
> I think a better solution would be to add this check only when proper
> support for CPU frequency based cooling is added. That is, when a call
> to cpufreq_cooling_register() (or a variant thereof) is added.
For the above reason the code is only compiled in when user enable
CONFIG_CPU_THERMAL.
>
> But while at it, why not make it so that cpufreq_cooling_register()
> detects if a cpufreq driver has been registered yet and propagate
> -EPROBE_DEFER if necessary?
cpufreq_cooling_register() may be a good place to add check for
deferred probe.
The problem with cpufreq_cooling_register() is that it may be called
late in the probe function (as it is done now in Exynos).
>
> Thierry
--
Best regards,
Lukasz Majewski
Samsung R&D Institute Poland (SRPOL) | Linux Platform Group
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists