From 29d0bb57855f5c1cebbbfefb50968a7e2dbb3660 Mon Sep 17 00:00:00 2001 From: Bastien Nocera Date: Thu, 1 Dec 2016 16:28:59 +0100 Subject: [PATCH] accel: Remove work-around quirk from poll accel driver --- src/drv-iio-poll-accel.c | 20 +++----------------- 1 file changed, 3 insertions(+), 17 deletions(-) diff --git a/src/drv-iio-poll-accel.c b/src/drv-iio-poll-accel.c index 1571904..5da8e2c 100644 --- a/src/drv-iio-poll-accel.c +++ b/src/drv-iio-poll-accel.c @@ -62,23 +62,9 @@ poll_orientation (gpointer user_data) readings.accel_x, readings.accel_y, readings.accel_z, readings.scale); //FIXME report errors - if (g_strcmp0 ("i2c-SMO8500:00", g_udev_device_get_sysfs_attr (data->dev, "name")) == 0) { - /* Quirk for i2c-SMO8500:00 device, - * swap x and y */ - readings.accel_x = accel_y; - readings.accel_y = accel_x; - readings.accel_z = accel_z; - } else if (g_strcmp0 ("i2c-KIOX000A:00", g_udev_device_get_sysfs_attr (data->dev, "name")) == 0) { - /* Quirk for i2c-KIOX000A:00 device, - * take opposite y */ - readings.accel_x = accel_x; - readings.accel_y = -accel_y; - readings.accel_z = accel_z; - } else { - readings.accel_x = accel_x; - readings.accel_y = accel_y; - readings.accel_z = accel_z; - } + readings.accel_x = accel_x; + readings.accel_y = accel_y; + readings.accel_z = accel_z; drv_data->callback_func (&iio_poll_accel, (gpointer) &readings, drv_data->user_data);