OSDN Git Service

dmaengine: mv_xor: Fix a missing check in mv_xor_channel_add
authorAditya Pakki <pakki001@umn.edu>
Mon, 24 Dec 2018 17:41:54 +0000 (11:41 -0600)
committerVinod Koul <vkoul@kernel.org>
Mon, 7 Jan 2019 04:20:29 +0000 (09:50 +0530)
commit7c97381e7a9a5ec359007c0d491a143e3d9f787c
treed53a0efb6f3693bf8d8168dcfc706f822caeb8ae
parentbfeffd155283772bbe78c6a05dec7c0128ee500c
dmaengine: mv_xor: Fix a missing check in mv_xor_channel_add

dma_async_device_register() may fail and return an error. The capabilities
checked in mv_xor_channel_add() are not complete. The fix handles the
error by freeing the resources.

Signed-off-by: Aditya Pakki <pakki001@umn.edu>
Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/dma/mv_xor.c