]> asedeno.scripts.mit.edu Git - linux.git/commit
dmaengine: core: Revert back to pr_debug in __dma_request_channel()
authorJarkko Nikula <jarkko.nikula@linux.intel.com>
Thu, 7 Apr 2016 13:49:43 +0000 (16:49 +0300)
committerVinod Koul <vinod.koul@intel.com>
Wed, 13 Apr 2016 15:39:21 +0000 (21:09 +0530)
commit4c4d7f878589585d32b81aab6ed4a5066fae1091
tree0c93f39ba5ccaf53243aa2697383b285bf7f33a3
parentef859312c3a16b42f398e6dbb14de23bffd5dd41
dmaengine: core: Revert back to pr_debug in __dma_request_channel()

Commit ef859312c3a1 ("dmaengine: core: Use dev_ functions for debug and
error prints") wasn't quite right in __dma_request_channel() by claiming
that all pr_ prints have valid DMA channel pointer. Obviously it is not
true as __dma_request_channel() is looking for a channel and returns NULL
if it does not find it.

Prevent this potential NULL pointer dereference by reverting back to
pr_debug().

Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
drivers/dma/dmaengine.c