Commit c690dce5 authored by Rafael J. Wysocki's avatar Rafael J. Wysocki
Browse files

thermal: core: Introduce thermal_instance_delete()



It is not necessary to walk the thermal_instances list in a trip
descriptor under a cooling device lock, so acquire that lock only
for deleting the given thermal instance from the list of thermal
instances in the given cdev.

Moreover, in analogy with the previous change that introduced
thermal_instance_add(), put the code deleting the given thermal
instance from the lists it is on into a separate new function
called thermal_instance_delete().

No intentional functional impact.

Signed-off-by: default avatarRafael J. Wysocki <rafael.j.wysocki@intel.com>
Link: https://patch.msgid.link/3275745.5fSG56mABF@rjwysocki.net


Reviewed-by: default avatarLukasz Luba <lukasz.luba@arm.com>
parent 6d153f52
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment