Commit 6ddde3e
usb: hub: Fix flushing of delayed work used for post resume purposes
commit 9bd9c80 upstream.
Delayed work that prevents USB3 hubs from runtime-suspending too early
needed to be flushed in hub_quiesce() to resolve issues detected on
QC SC8280XP CRD board during suspend resume testing.
This flushing did however trigger new issues on Raspberry Pi 3B+, which
doesn't have USB3 ports, and doesn't queue any post resume delayed work.
The flushed 'hub->init_work' item is used for several purposes, and
is originally initialized with a 'NULL' work function. The work function
is also changed on the fly, which may contribute to the issue.
Solve this by creating a dedicated delayed work item for post resume work,
and flush that delayed work in hub_quiesce()
Cc: stable <stable@kernel.org>
Fixes: a49e1e2 ("usb: hub: Fix flushing and scheduling of delayed work that tunes runtime pm")
Reported-by: Mark Brown <broonie@kernel.org>
Closes: https://lore.kernel.org/linux-usb/aF5rNp1l0LWITnEB@finisterre.sirena.org.uk
Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com>
Tested-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com> # SC8280XP CRD
Tested-by: Mark Brown <broonie@kernel.org>
Link: https://lore.kernel.org/r/20250627164348.3982628-2-mathias.nyman@linux.intel.com
[florian: adjust for lack of hub_{get,put} and timer_delete_sync]
Signed-off-by: Florian Fainelli <florian.fainelli@broadcom.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>1 parent 08c21a7 commit 6ddde3e
2 files changed
+9
-13
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1030 | 1030 | | |
1031 | 1031 | | |
1032 | 1032 | | |
1033 | | - | |
| 1033 | + | |
1034 | 1034 | | |
1035 | 1035 | | |
1036 | 1036 | | |
1037 | 1037 | | |
1038 | | - | |
1039 | 1038 | | |
1040 | 1039 | | |
1041 | 1040 | | |
| |||
1059 | 1058 | | |
1060 | 1059 | | |
1061 | 1060 | | |
1062 | | - | |
1063 | | - | |
1064 | | - | |
1065 | | - | |
1066 | | - | |
1067 | | - | |
1068 | 1061 | | |
1069 | 1062 | | |
1070 | 1063 | | |
| |||
1318 | 1311 | | |
1319 | 1312 | | |
1320 | 1313 | | |
1321 | | - | |
1322 | | - | |
| 1314 | + | |
| 1315 | + | |
1323 | 1316 | | |
1324 | 1317 | | |
1325 | 1318 | | |
| |||
1344 | 1337 | | |
1345 | 1338 | | |
1346 | 1339 | | |
1347 | | - | |
| 1340 | + | |
1348 | 1341 | | |
1349 | | - | |
| 1342 | + | |
| 1343 | + | |
1350 | 1344 | | |
1351 | 1345 | | |
1352 | 1346 | | |
| |||
1374 | 1368 | | |
1375 | 1369 | | |
1376 | 1370 | | |
1377 | | - | |
| 1371 | + | |
1378 | 1372 | | |
1379 | 1373 | | |
1380 | 1374 | | |
| |||
1921 | 1915 | | |
1922 | 1916 | | |
1923 | 1917 | | |
| 1918 | + | |
1924 | 1919 | | |
1925 | 1920 | | |
1926 | 1921 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
69 | 69 | | |
70 | 70 | | |
71 | 71 | | |
| 72 | + | |
72 | 73 | | |
73 | 74 | | |
74 | 75 | | |
| |||
0 commit comments