Commit c690dce
committed
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: Rafael J. Wysocki <[email protected]>
Link: https://patch.msgid.link/[email protected]
Reviewed-by: Lukasz Luba <[email protected]>1 parent 6d153f5 commit c690dce
1 file changed
+12
-5
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
868 | 868 | | |
869 | 869 | | |
870 | 870 | | |
| 871 | + | |
| 872 | + | |
| 873 | + | |
| 874 | + | |
| 875 | + | |
| 876 | + | |
| 877 | + | |
| 878 | + | |
| 879 | + | |
| 880 | + | |
| 881 | + | |
871 | 882 | | |
872 | 883 | | |
873 | 884 | | |
| |||
884 | 895 | | |
885 | 896 | | |
886 | 897 | | |
887 | | - | |
888 | 898 | | |
889 | 899 | | |
890 | | - | |
891 | | - | |
892 | | - | |
| 900 | + | |
893 | 901 | | |
894 | 902 | | |
895 | 903 | | |
896 | | - | |
897 | 904 | | |
898 | 905 | | |
899 | 906 | | |
| |||
0 commit comments