From 6c0743ed99bf3e13b80574629131465a10b12879 Mon Sep 17 00:00:00 2001 From: Lars-Peter Clausen Date: Mon, 14 Oct 2013 17:49:00 +0100 Subject: iio:st_pressure: Remove redundant call to iio_sw_buffer_preenable(). The equivalent of iio_sw_buffer_preenable() is now done in the IIO buffer core, so there is no need to do this from the driver anymore. Signed-off-by: Lars-Peter Clausen Cc: Denis Ciocca Signed-off-by: Jonathan Cameron --- drivers/iio/pressure/st_pressure_buffer.c | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) (limited to 'drivers/iio') diff --git a/drivers/iio/pressure/st_pressure_buffer.c b/drivers/iio/pressure/st_pressure_buffer.c index f877ef8af520..b37b1c9ac932 100644 --- a/drivers/iio/pressure/st_pressure_buffer.c +++ b/drivers/iio/pressure/st_pressure_buffer.c @@ -32,16 +32,7 @@ int st_press_trig_set_state(struct iio_trigger *trig, bool state) static int st_press_buffer_preenable(struct iio_dev *indio_dev) { - int err; - - err = st_sensors_set_enable(indio_dev, true); - if (err < 0) - goto st_press_set_enable_error; - - err = iio_sw_buffer_preenable(indio_dev); - -st_press_set_enable_error: - return err; + return st_sensors_set_enable(indio_dev, true); } static int st_press_buffer_postenable(struct iio_dev *indio_dev) -- cgit v1.2.3