summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 48712ea)
raw | patch | inline | side by side (parent: 48712ea)
author | Lars-Peter Clausen <lars@metafoo.de> | |
Fri, 4 Nov 2016 22:45:38 +0000 (22:45 +0000) | ||
committer | Jean-Jacques Hiblot <jjhiblot@ti.com> | |
Wed, 7 Dec 2016 14:46:13 +0000 (15:46 +0100) |
commit b1d6ab1aa8cdc23b89bcd578ea8d5e3c501a13d9 upstream.
Implementations of dmaengine_synchronize() are allowed to sleep, hence the
function must not be called to from atomic context. Add might_sleep() to
dmaengine_synchronize() to make it easier to detect non-compliant callers.
Suggested-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Implementations of dmaengine_synchronize() are allowed to sleep, hence the
function must not be called to from atomic context. Add might_sleep() to
dmaengine_synchronize() to make it easier to detect non-compliant callers.
Suggested-by: Andy Shevchenko <andy.shevchenko@gmail.com>
Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
include/linux/dmaengine.h | patch | blob | history |
index 6a44358af87bcf05d7c474b4e53d1120dd5975ef..95e689276ef122852b62cb400a8b41b455547e6e 100644 (file)
*/
static inline void dmaengine_synchronize(struct dma_chan *chan)
{
+ might_sleep();
+
if (chan->device->device_synchronize)
chan->device->device_synchronize(chan);
}