Skip to content
Commit 1057c4c3 authored by Nikita Travkin's avatar Nikita Travkin Committed by Rafael J. Wysocki
Browse files

thermal: gov_power_allocator: Allow binding without cooling devices

IPA was recently refactored to split out memory allocation into a
separate funciton. That funciton was made to return -EINVAL if there is
zero power_actors and thus no memory to allocate. This causes IPA to
fail probing when the thermal zone has no attached cooling devices.

Since cooling devices can attach after the thermal zone is created and
the governer is attached to it, failing probe due to the lack of cooling
devices is incorrect.

Change the allocate_actors_buffer() to return success when there is no
cooling devices present.

Fixes: 912e97c6

 ("thermal: gov_power_allocator: Move memory allocation out of throttle()")
Signed-off-by: default avatarNikita Travkin <nikita@trvn.ru>
Reviewed-by: default avatarLukasz Luba <lukasz.luba@arm.com>
Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
parent 39cd87c4
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment