Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-13 Thread Stratos Karafotis
On 13/06/2014 09:49 πμ, Doug Smythies wrote: > On 2014.06.12 13:03 Rafael J. Wysocki wrote: >> On Thursday, June 12, 2014 05:35:59 PM Stratos Karafotis wrote: >>> On 12/06/2014 12:15 πμ, Doug Smythies wrote: On 2014.06.11 13:20 Stratos Karafotis wrote: > On 11/06/2014 06:02 μμ, D

Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-13 Thread Stratos Karafotis
essage- >>>> From: Stratos Karafotis [mailto:strat...@semaphore.gr] >>>> Sent: June-11-2014 13:20 >>>> To: Doug Smythies >>>> Cc: linux...@vger.kernel.org; linux-kernel@vger.kernel.org; >>>> r...@rjwysocki.net; viresh.ku...@linaro.org;

RE: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-13 Thread Doug Smythies
On 2014.06.12 06:49 Dirk Brandewie wrote: > On 06/12/2014 01:03 PM, Rafael J. Wysocki wrote: >> On Thursday, June 12, 2014 05:35:59 PM Stratos Karafotis wrote: >>> On 12/06/2014 12:15 πμ, Doug Smythies wrote: > Could you please elaborate a little bit more what we need these 2 lines > bel

Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-13 Thread Dirk Brandewie
...@vger.kernel.org; linux-kernel@vger.kernel.org; r...@rjwysocki.net; viresh.ku...@linaro.org; dirk.j.brande...@intel.com Subject: Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct On 2014.06.11 13:20 Stratos Karafotis wrote: On 11/06/2014 06:02 μμ, Doug Smythies wrote: On 2104.06.11

RE: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-12 Thread Doug Smythies
On 2014.06.12 13:03 Rafael J. Wysocki wrote: > On Thursday, June 12, 2014 05:35:59 PM Stratos Karafotis wrote: >> On 12/06/2014 12:15 πμ, Doug Smythies wrote: >>> >>> >>> On 2014.06.11 13:20 Stratos Karafotis wrote: On 11/06/2014 06:02 μμ, Doug Smythies wrote: > > On 2104.06.11 07:08

Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-12 Thread Rafael J. Wysocki
ythies > > Cc: linux...@vger.kernel.org; linux-kernel@vger.kernel.org; > > r...@rjwysocki.net; viresh.ku...@linaro.org; dirk.j.brande...@intel.com > > Subject: Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct > > > > On 2014.06.11 13:20 Stratos Karafotis wr

Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-12 Thread Stratos Karafotis
viresh.ku...@linaro.org; dirk.j.brande...@intel.com > Subject: Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct > > On 2014.06.11 13:20 Stratos Karafotis wrote: >> On 11/06/2014 06:02 μμ, Doug Smythies wrote: >>> >>> On 2104.06.11 07:08 Stratos Karafoti

RE: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-11 Thread Doug Smythies
On 2014.06.11 14:45 Rafael J. Wysocki wrote: > On Wed, Jun 11, 2014 at 11:40 PM, Doug Smythies wrote: > >> Myself, I consider the issue of excessive deferred timer times to be a much >> higher priority (see my on-list e-mail from Monday). Correct me if I am >> wrong. >> Even without the "excess

Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-11 Thread Rafael J. Wysocki
rg; Linux Kernel Mailing List; > Rafael J. Wysocki; viresh.ku...@linaro.org; dirk.j.brande...@intel.com > Subject: Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct > > On 2014.06.11 11:29 Rafael J. Wysocki wrote: >> On Wed, Jun 11, 2014 at 5:02 PM, Doug Smythies wrote:

RE: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-11 Thread Doug Smythies
...@intel.com Subject: Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct On 2014.06.11 11:29 Rafael J. Wysocki wrote: > On Wed, Jun 11, 2014 at 5:02 PM, Doug Smythies wrote: >> On 2104.06.11 07:08 Stratos Karafotis wrote: >>> On 11/06/2014 04:41 μμ, Doug Smythies

RE: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-11 Thread Doug Smythies
: intel_pstate: Fix rounding of core_pct On 2014.06.11 13:20 Stratos Karafotis wrote: > On 11/06/2014 06:02 μμ, Doug Smythies wrote: >> >> On 2104.06.11 07:08 Stratos Karafotis wrote: >>> On 11/06/2014 04:41 μμ, Doug Smythies wrote: >>> >>> No. >> >>&

Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-11 Thread Stratos Karafotis
On 11/06/2014 06:02 μμ, Doug Smythies wrote: > > On 2104.06.11 07:08 Stratos Karafotis wrote: >> On 11/06/2014 04:41 μμ, Doug Smythies wrote: >> >> No. >> >> The intent was only ever to round properly the pseudo floating point result >> of the divide. >> It was much more important (ugh, well 4 ti

Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-11 Thread Rafael J. Wysocki
On Wed, Jun 11, 2014 at 5:02 PM, Doug Smythies wrote: > > On 2104.06.11 07:08 Stratos Karafotis wrote: >> On 11/06/2014 04:41 μμ, Doug Smythies wrote: >> >> No. >> >> The intent was only ever to round properly the pseudo floating point result >> of the divide. >> It was much more important (ugh,

RE: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-11 Thread Doug Smythies
On 2104.06.11 07:08 Stratos Karafotis wrote: > On 11/06/2014 04:41 μμ, Doug Smythies wrote: > > No. > > The intent was only ever to round properly the pseudo floating point result > of the divide. > It was much more important (ugh, well 4 times more) when FRACBITS was still > 6, which also got

RE: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-11 Thread Doug Smythies
On 2014.06.11 06:42 Doug Smythies wrote: On 2014.06.11 05:34 Stratos Karafotis wrote: >> if ((rem << 1) >= int_tofp(sample->mperf)) >> -core_pct += 1; >> +core_pct += int_tofp(1); >> >> sample->freq = fp_toint( >> mul_fp(int_tofp(cpu->pstate.max_pst

Re: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-11 Thread Stratos Karafotis
On 11/06/2014 04:41 μμ, Doug Smythies wrote: > > On 2014.06.11 05:34 Stratos Karafotis wrote: > >> Local variable core_pct holds fixed point values. >> When we round it we add "1" to core_pct. This has almost >> no effect. >> >> So, add int_toftp(1) to core_pct when rounding. >> >> For example, i

RE: [PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-11 Thread Doug Smythies
On 2014.06.11 05:34 Stratos Karafotis wrote: > Local variable core_pct holds fixed point values. > When we round it we add "1" to core_pct. This has almost > no effect. > > So, add int_toftp(1) to core_pct when rounding. > > For example, in a given sample point (values taken from > tracepoint) wi

[PATCH] cpufreq: intel_pstate: Fix rounding of core_pct

2014-06-11 Thread Stratos Karafotis
Local variable core_pct holds fixed point values. When we round it we add "1" to core_pct. This has almost no effect. So, add int_toftp(1) to core_pct when rounding. For example, in a given sample point (values taken from tracepoint) with: aperf = 5024 mperf = 10619 the core_pct is (before round