summaryrefslogtreecommitdiff
path: root/drivers/iio/gyro/st_gyro_buffer.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/iio/gyro/st_gyro_buffer.c')
-rw-r--r--drivers/iio/gyro/st_gyro_buffer.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/iio/gyro/st_gyro_buffer.c b/drivers/iio/gyro/st_gyro_buffer.c
index 6e362f735e92..21360681d4dd 100644
--- a/drivers/iio/gyro/st_gyro_buffer.c
+++ b/drivers/iio/gyro/st_gyro_buffer.c
@@ -39,7 +39,8 @@ static int st_gyro_buffer_postenable(struct iio_dev *indio_dev)
int err;
struct st_sensor_data *gdata = iio_priv(indio_dev);
- gdata->buffer_data = kmalloc(indio_dev->scan_bytes, GFP_KERNEL);
+ gdata->buffer_data = kmalloc(indio_dev->scan_bytes,
+ GFP_DMA | GFP_KERNEL);
if (gdata->buffer_data == NULL) {
err = -ENOMEM;
goto allocate_memory_error;