Commit e63a9a1
committed
ASoC: SOF: Intel: hda: reset dma_sata during suspend
When the stream is cleared during the suspend trigger,
the dma_data must be set to NULL and
snd_hdac_ext_stream_release() must be called to release
the link dev. Without this, some platforms run into
issues with triggering the host DMA during system resume.
Add the missing sequences to both hda_link_pcm_trigger() to
handle all streams that get suspended and to
hda_dsp_set_hw_params_upon_resume() to handle paused streams that
are reset during system suspend.
Also, because the dma_data is set to NULL during suspend,
add the checks to ensure link_dev is not NULL during
hw_params and hw_free to prevent NULL pointer dereferences.
BugLink: thesofproject/sof#4779
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>1 parent 78a8ed4 commit e63a9a1
2 files changed
+18
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
279 | 279 | | |
280 | 280 | | |
281 | 281 | | |
282 | | - | |
| 282 | + | |
283 | 283 | | |
284 | 284 | | |
285 | 285 | | |
| |||
306 | 306 | | |
307 | 307 | | |
308 | 308 | | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
309 | 313 | | |
310 | 314 | | |
311 | 315 | | |
| |||
347 | 351 | | |
348 | 352 | | |
349 | 353 | | |
| 354 | + | |
| 355 | + | |
350 | 356 | | |
| 357 | + | |
351 | 358 | | |
352 | 359 | | |
353 | 360 | | |
| |||
377 | 384 | | |
378 | 385 | | |
379 | 386 | | |
380 | | - | |
381 | | - | |
382 | | - | |
383 | | - | |
384 | | - | |
| 387 | + | |
| 388 | + | |
385 | 389 | | |
386 | 390 | | |
387 | 391 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
922 | 922 | | |
923 | 923 | | |
924 | 924 | | |
| 925 | + | |
| 926 | + | |
925 | 927 | | |
| 928 | + | |
926 | 929 | | |
927 | 930 | | |
928 | 931 | | |
929 | 932 | | |
930 | 933 | | |
931 | | - | |
| 934 | + | |
| 935 | + | |
| 936 | + | |
| 937 | + | |
932 | 938 | | |
933 | | - | |
934 | | - | |
| 939 | + | |
935 | 940 | | |
936 | 941 | | |
937 | 942 | | |
| |||
0 commit comments