Commit 54aaa3b
usb: dwc3: gadget: Move vbus draw to workqueue context
Currently dwc3_gadget_vbus_draw() can be called from atomic
context, which in turn invokes power-supply-core APIs. And
some these PMIC APIs have operations that may sleep, leading
to kernel panic.
Fix this by moving the vbus_draw into a workqueue context.
Fixes: 99288de ("usb: dwc3: add an alternate path in vbus_draw callback")
Cc: stable <stable@kernel.org>
Tested-by: Samuel Wu <wusamuel@google.com>
Acked-by: Thinh Nguyen <Thinh.Nguyen@synopsys.com>
Signed-off-by: Prashanth K <prashanth.k@oss.qualcomm.com>
Link: https://patch.msgid.link/20260204054155.3063825-1-prashanth.k@oss.qualcomm.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>1 parent 6dbc394 commit 54aaa3b
3 files changed
Lines changed: 25 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2155 | 2155 | | |
2156 | 2156 | | |
2157 | 2157 | | |
| 2158 | + | |
| 2159 | + | |
| 2160 | + | |
| 2161 | + | |
| 2162 | + | |
| 2163 | + | |
| 2164 | + | |
| 2165 | + | |
| 2166 | + | |
| 2167 | + | |
| 2168 | + | |
| 2169 | + | |
| 2170 | + | |
| 2171 | + | |
2158 | 2172 | | |
2159 | 2173 | | |
2160 | 2174 | | |
| |||
2169 | 2183 | | |
2170 | 2184 | | |
2171 | 2185 | | |
| 2186 | + | |
2172 | 2187 | | |
2173 | 2188 | | |
2174 | 2189 | | |
| |||
2395 | 2410 | | |
2396 | 2411 | | |
2397 | 2412 | | |
2398 | | - | |
| 2413 | + | |
| 2414 | + | |
2399 | 2415 | | |
| 2416 | + | |
2400 | 2417 | | |
2401 | 2418 | | |
2402 | 2419 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1058 | 1058 | | |
1059 | 1059 | | |
1060 | 1060 | | |
| 1061 | + | |
| 1062 | + | |
1061 | 1063 | | |
1062 | 1064 | | |
1063 | 1065 | | |
| |||
1244 | 1246 | | |
1245 | 1247 | | |
1246 | 1248 | | |
| 1249 | + | |
| 1250 | + | |
1247 | 1251 | | |
1248 | 1252 | | |
1249 | 1253 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3124 | 3124 | | |
3125 | 3125 | | |
3126 | 3126 | | |
3127 | | - | |
3128 | | - | |
3129 | 3127 | | |
3130 | 3128 | | |
3131 | 3129 | | |
3132 | 3130 | | |
3133 | 3131 | | |
3134 | 3132 | | |
3135 | 3133 | | |
3136 | | - | |
3137 | | - | |
| 3134 | + | |
| 3135 | + | |
3138 | 3136 | | |
3139 | | - | |
| 3137 | + | |
3140 | 3138 | | |
3141 | 3139 | | |
3142 | 3140 | | |
| |||
0 commit comments