Hi ,Rafael

> -----Original Message-----
> From: Rafael J. Wysocki [mailto:[email protected]]
> Sent: Tuesday, September 08, 2015 5:47 AM
> To: Chen, Yu C; [email protected]
> Cc: [email protected]; [email protected]; linux-
> [email protected]; Zhang, Rui; [email protected]
> Subject: Re: [PATCH][rfc] intel_pstate: Fix user input of min/max to legal
> policy region
> 
> On Wednesday, August 12, 2015 11:49:19 AM Chen Yu wrote:
> > In current code, if system is using performance policy, user can
> > modify the max_perf_pct to any values lower than 100:
> >
> > $ grep . /sys/devices/system/cpu/intel_pstate/m*_perf_pct
> > /sys/devices/system/cpu/intel_pstate/max_perf_pct:100
> > /sys/devices/system/cpu/intel_pstate/min_perf_pct:100
> >
> > $ echo 80 > /sys/devices/system/cpu/intel_pstate/max_perf_pct
> >
> > $ grep . /sys/devices/system/cpu/intel_pstate/m*_perf_pct
> > /sys/devices/system/cpu/intel_pstate/max_perf_pct:80
> > /sys/devices/system/cpu/intel_pstate/min_perf_pct:100
> >
> > the max_perf_pct above is lower than min_perf_pct, which is not
> > reasonable.
> >
> > This patch solves this problem by clamping min_perf_pct and
> > max_perf_pct to be strictly inside [min_policy_pct,max_policy_pct].
> >
> > Signed-off-by: Chen Yu <[email protected]>
> 
> Looks reasonable to me.
> 
> Kristen, any objections?
> 
Thanks for your reply! 
According to suggestion from  Seiichi, will re-send a V2 version patch,
to make some update.

Best Regards,
Yu 

Reply via email to