Commit c4cd42e
committed
thermal: core: Update thermal zones after cooling device binding
If a new cooling device is registered and it is bound to at least one
trip point in a given thermal zone, that thermal zone needs to be
updated via __thermal_zone_device_update().
Instead of doing this with the help of the need_update atomic field in
struct thermal_zone_device, which is not particularly straightforward,
make __thermal_zone_cdev_bind() return a bool value indicating whether
or not the given thermal zone needs to be updated because a new cooling
device has been bound to it and update thermal_zone_cdev_bind() to
call __thermal_zone_device_update() when this value is "true".
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 fa4f9c9 commit c4cd42e
1 file changed
+13
-10
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
935 | 935 | | |
936 | 936 | | |
937 | 937 | | |
938 | | - | |
| 938 | + | |
939 | 939 | | |
940 | 940 | | |
941 | 941 | | |
| 942 | + | |
942 | 943 | | |
943 | 944 | | |
944 | | - | |
| 945 | + | |
945 | 946 | | |
946 | 947 | | |
947 | 948 | | |
| |||
956 | 957 | | |
957 | 958 | | |
958 | 959 | | |
959 | | - | |
| 960 | + | |
960 | 961 | | |
| 962 | + | |
| 963 | + | |
| 964 | + | |
| 965 | + | |
961 | 966 | | |
| 967 | + | |
| 968 | + | |
962 | 969 | | |
963 | 970 | | |
964 | 971 | | |
965 | 972 | | |
966 | 973 | | |
967 | 974 | | |
968 | 975 | | |
969 | | - | |
| 976 | + | |
| 977 | + | |
970 | 978 | | |
971 | 979 | | |
972 | 980 | | |
| |||
993 | 1001 | | |
994 | 1002 | | |
995 | 1003 | | |
996 | | - | |
| 1004 | + | |
997 | 1005 | | |
998 | 1006 | | |
999 | 1007 | | |
| |||
1069 | 1077 | | |
1070 | 1078 | | |
1071 | 1079 | | |
1072 | | - | |
1073 | | - | |
1074 | | - | |
1075 | | - | |
1076 | | - | |
1077 | 1080 | | |
1078 | 1081 | | |
1079 | 1082 | | |
| |||
0 commit comments