mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-23 20:24:12 +08:00
1ffc6f359f
The commit in the Fixes: tag has changed the logic of the code and now it
is likely that the probe will return an early success (0), even if not
completely executed.
This should lead to a crash or similar issue later on when the code
accesses to some never allocated resources.
Change the '!err' into a 'err' when checking if
'dma_set_mask_and_coherent()' has failed or not.
While at it, simplify the code and remove the "can't success code" related
to 32 DMA mask.
As stated in [1], 'dma_set_mask_and_coherent(DMA_BIT_MASK(64))' can't fail
if 'dev->dma_mask' is non-NULL. And if it is NULL, it would fail for the
same reason when tried with DMA_BIT_MASK(32).
[1]: https://lkml.org/lkml/2021/6/7/398
Fixes:
|
||
---|---|---|
.. | ||
dw-edma-core.c | ||
dw-edma-core.h | ||
dw-edma-pcie.c | ||
dw-edma-v0-core.c | ||
dw-edma-v0-core.h | ||
dw-edma-v0-debugfs.c | ||
dw-edma-v0-debugfs.h | ||
dw-edma-v0-regs.h | ||
Kconfig | ||
Makefile |