Re: [PATCH] intel_pstate: Change busy calculation to use fixed point math.

From: Greg KH
Date: Fri Feb 28 2014 - 17:46:14 EST


On Tue, Feb 25, 2014 at 10:35:37AM -0800, dirk.brandewie@xxxxxxxxx wrote:
> From: Dirk Brandewie <dirk.j.brandewie@xxxxxxxxx>
>
> Commit fcb6a15c2e Take core C0 time into account for core busy calculation.
>
> Introduced a regression on some processor SKUs supported by
> intel_pstate. This was caused by the truncation caused by using
> integer math to calculate core busy and C0 percentages.
>
> On a i7-4770K processor operating at 800Mhz going to 100% utilization
> the percent busy of the CPU using integer math is 22% it actually is
> 22.85%. This value scaled to the current frequency returned 97 which
> the PID interpreted as no error and did not adjust the P state.
>
> Tested on i7-4770K, i7-2600, i5-3230M
>
> References:
> https://lkml.org/lkml/2014/2/19/626
> https://bugzilla.kernel.org/show_bug.cgi?id=70941
>
> Signed-off-by: Dirk Brandewie <dirk.j.brandewie@xxxxxxxxx>

Thanks, this fixed the issue for me:

Tested-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/