]> git.proxmox.com Git - mirror_ubuntu-artful-kernel.git/commit
staging: iio: ad7192: Fix - use the dedicated reset function avoiding dma from stack.
authorStefan Popa <stefan.popa@analog.com>
Thu, 14 Sep 2017 13:50:28 +0000 (16:50 +0300)
committerSeth Forshee <seth.forshee@canonical.com>
Thu, 19 Oct 2017 14:48:51 +0000 (09:48 -0500)
commit6f635af023812b9ac68d1541876600faedc52e81
tree5265591c6f88d15243b113b4337287f2fcb48068
parent16b86058a28d9ca01b43e6ac9f47b620dc05e99e
staging: iio: ad7192: Fix - use the dedicated reset function avoiding dma from stack.

BugLink: http://bugs.launchpad.net/bugs/1723145
commit f790923f146140a261ad211e5baf75d169f16fb2 upstream.

Depends on: 691c4b95d1 ("iio: ad_sigma_delta: Implement a dedicated reset function")

SPI host drivers can use DMA to transfer data, so the buffer should be properly allocated.
Keeping it on the stack could cause an undefined behavior.

The dedicated reset function solves this issue.

Signed-off-by: Stefan Popa <stefan.popa@analog.com>
Acked-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Seth Forshee <seth.forshee@canonical.com>
drivers/staging/iio/adc/ad7192.c