Commit 0a67933
iommu/arm-smmu: Set rpm auto_suspend once during probe
The current code calls arm_smmu_rpm_use_autosuspend() during device
attach, which seems unusual as it sets the autosuspend delay and the
'use_autosuspend' flag for the smmu device. These parameters can be
simply set once during the smmu probe and in order to avoid bouncing
rpm states, we can simply mark_last_busy() during a client dev attach
as discussed in [1].
Move the handling of arm_smmu_rpm_use_autosuspend() to the SMMU probe
and modify the arm_smmu_rpm_put() function to mark_last_busy() before
calling __pm_runtime_put_autosuspend(). Additionally,
s/pm_runtime_put_autosuspend/__pm_runtime_put_autosuspend/ to help with
the refactor of the pm_runtime_put_autosuspend() API [2].
Link: https://lore.kernel.org/r/20241023164835.GF29251@willie-the-truck [1]
Link: https://git.kernel.org/linus/b7d46644e554 [2]
Signed-off-by: Pranjal Shrivastava <praan@google.com>
Link: https://lore.kernel.org/r/20250123195636.4182099-1-praan@google.com
Signed-off-by: Will Deacon <will@kernel.org>1 parent 0ad2507 commit 0a67933
1 file changed
+6
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
82 | | - | |
83 | | - | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
84 | 87 | | |
85 | 88 | | |
86 | 89 | | |
| |||
1195 | 1198 | | |
1196 | 1199 | | |
1197 | 1200 | | |
1198 | | - | |
1199 | 1201 | | |
1200 | 1202 | | |
1201 | 1203 | | |
| |||
1218 | 1220 | | |
1219 | 1221 | | |
1220 | 1222 | | |
1221 | | - | |
1222 | 1223 | | |
1223 | 1224 | | |
1224 | 1225 | | |
| |||
2246 | 2247 | | |
2247 | 2248 | | |
2248 | 2249 | | |
| 2250 | + | |
2249 | 2251 | | |
2250 | 2252 | | |
2251 | 2253 | | |
| |||
0 commit comments