]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
spi: dw-mid: check that DMA was inited before exit
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Fri, 12 Sep 2014 12:11:58 +0000 (15:11 +0300)
committerJiri Slaby <jslaby@suse.cz>
Fri, 31 Oct 2014 14:11:10 +0000 (15:11 +0100)
commiteeef301b6d8d548d8577cfb14ca1c56ca323bfb7
treefaddeb43e90a9f074d8e61784e711de4ea20b18a
parent15bc7947fa4a4cf121c46f317c6f1c349b5894d8
spi: dw-mid: check that DMA was inited before exit

commit fb57862ead652454ceeb659617404c5f13bc34b5 upstream.

If the driver was compiled with DMA support, but DMA channels weren't acquired
by some reason, mid_spi_dma_exit() will crash the kernel.

Fixes: 7063c0d942a1 (spi/dw_spi: add DMA support)
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
drivers/spi/spi-dw-mid.c