Re: [PATCH 3/8] platform: arm64: qcom-hamoa-ec: Switch fan profile based on power supply state

From: Anvesh Jain P

Date: Tue Sep 29 2026 - 02:57:54 EST




On 9/21/2026 5:53 PM, Konrad Dybcio wrote:
> On 8/19/26 7:19 AM, Anvesh Jain P wrote:
>>
>>
>> On 7/30/2026 11:51 AM, Anvesh Jain P wrote:
>>>> Is being on a (powerful) charger a prerequisite for entering this profile?
>>>> Currently plugging in a 5W charger would trigger the switch as well.
>>>>
>>>> Should this instead be exposed as a fan profile for userspace?
>>>>
>>>> Konrad
>>> Fair point — power_supply_is_system_supplied() only checks mains
>>> presence, not charger wattage, so even a 5W charger triggers the "best
>>> performance" profile. And exposing this via platform_profile instead of
>>> an automatic AC/battery switch would let userspace make the call
>>> instead. Will check on the feasibility of making this possible.
>> Even at 5W we're still not battery-constrained, so best performance
>> still makes sense, it's about wall power vs battery, not wattage. And I
>> don't think userspace needs control over this either, it's just an
>> automatic fan curve pick, not a performance setting users would want to
>> tune themselves.
>
> I believe fan profile control is very much within the expected
> feature scope of a personal computer..
>
> Konrad

Fan-profile control need not be user-facing, since it is only a
thermal-management policy.
--
Best Regards,
Anvesh