linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Javi Merino <javi.merino@arm.com>
To: Inhyuk Kang <hugh.kang@lge.com>, Zhang Rui <rui.zhang@intel.com>
Cc: Eduardo Valentin <edubezval@gmail.com>,
	linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] of: thermal: Fixed governor at each thermal zone
Date: Tue, 27 Sep 2016 12:28:27 +0100	[thread overview]
Message-ID: <20160927112827.GB2955@e104805> (raw)
In-Reply-To: <1474940817.4284.0.camel@intel.com>

On Tue, Sep 27, 2016 at 09:46:57AM +0800, Zhang Rui wrote:
> On 一, 2016-09-19 at 10:18 +0900, Inhyuk Kang wrote:
> > It is necessary to be added governor at each thermal_zone.
> > Because some governors should be operated in the during the kernel
> > booting
> > in order to avoid heating problem.
> > 
> > Default governor cannot be covered all thermal zones policy because
> > some thermal zones want to apply different one.
> > For example, the power allocator governor operates differently with
> > step wise governor.
> > Hence, it is better to parse governor parameter from the device tree.
> > 
> > Signed-off-by: Inhyuk Kang <hugh.kang@lge.com>
> > 
> The patch looks okay to me.
> Eduardo, what do you think of this patch?

This has been proposed in the past[0] and Eduardo said no[1] (as did
Krzysztof Kozlowski and Mark Rutland)

[0] https://marc.info/?l=linux-kernel&m=143893141227189&w=4
[1] https://marc.info/?l=linux-pm&m=144649947022547&w=4

Cheers,
Javi

> > diff --git a/drivers/thermal/of-thermal.c b/drivers/thermal/of-
> > thermal.c
> > index b8e509c..382c440 100644
> > --- a/drivers/thermal/of-thermal.c
> > +++ b/drivers/thermal/of-thermal.c
> > @@ -970,6 +970,7 @@ int __init of_parse_thermal_zones(void)
> >  		struct thermal_zone_device *zone;
> >  		struct thermal_zone_params *tzp;
> >  		int i, mask = 0;
> > +		const char *governor;
> >  		u32 prop;
> >  
> >  		tz = thermal_of_build_thermal_zone(child);
> > @@ -996,6 +997,9 @@ int __init of_parse_thermal_zones(void)
> >  		if (!of_property_read_u32(child, "sustainable-
> > power", &prop))
> >  			tzp->sustainable_power = prop;
> >  
> > +		if (!of_property_read_string(child, "governor-name", 
> > &governor))
> > +			strcpy(tzp->governor_name, governor);
> > +
> >  		for (i = 0; i < tz->ntrips; i++)
> >  			mask |= 1 << i;
> >  
> --
> To unsubscribe from this list: send the line "unsubscribe linux-pm" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 

  reply	other threads:[~2016-09-27 11:28 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-09-19  1:18 [PATCH] of: thermal: Fixed governor at each thermal zone Inhyuk Kang
2016-09-27  1:46 ` Zhang Rui
2016-09-27 11:28   ` Javi Merino [this message]
2016-09-27 11:52   ` Lukasz Luba
2016-09-27 13:22     ` Eduardo Valentin
2016-09-28  1:30       ` Zhang Rui
2016-09-28  7:13         ` 강인혁/책임연구원/SW Platform(연)AOT팀(hugh.kang@lge.com)

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=20160927112827.GB2955@e104805 \
    --to=javi.merino@arm.com \
    --cc=edubezval@gmail.com \
    --cc=hugh.kang@lge.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@vger.kernel.org \
    --cc=rui.zhang@intel.com \
    /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).