Re: Regard of thermal power allocator's coefficients
From: Eduardo Valentin
Date: Sun Feb 14 2016 - 12:12:38 EST
Hello Leo,
On Sun, Feb 14, 2016 at 07:00:41PM +0800, Leo Yan wrote:
> Hi there,
>
> I'm trying to upstreaming IPA patches for 96board Hikey, but so far
> there have no standard DT binding for passing IPA coefficients for
> power modeling.
Thanks for your effort.
>
> So want to firstly to confirm if should we pass coefficients by using
> device tree? Is someone working on related work for this?
We pass the sustainable power, but not the coefficients. IIRC, the IPA
coefficients were considered (SW) implementation details. Sustainable power,
on the other hand, still describes hardware capabilities.
So, I don't think they will go via DT.
>
> Here has another more straightforward method is to directly to
> include power model's coefficients in thermal sensor driver (such like
> drivers/thermal/hisi_thermal.c), but my concern is this method will
> include SoC specific data in the common thermal sensor driver,
> so is this doable?
Yeah, unless you are sure that these coefficients are SoC dependent, and
not board dependent, for instance, (or even, use case dependent), I
would prefer you do not leave them configured in the driver.
Keep in mind that power allocator will compute defaults.
Also, userspace software may also tune these parameters, per thermal
zone.
>
> Welcome any suggestion.
>
> Thanks,
> Leo Yan
BR,
Eduardo Valentin