diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-06-22 09:57:28 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2016-06-22 09:57:28 -0700 |
commit | df013212a1b6557f071609983cab0612f71fd99b (patch) | |
tree | f5242679acfb34dcfa8db616bf273ce3213ba051 /drivers/iio | |
parent | 33688abb2802ff3a230bd2441f765477b94cc89e (diff) | |
parent | f4070a19142d5ee06f0da0cef56a0e78995f172c (diff) | |
download | linux-stable-df013212a1b6557f071609983cab0612f71fd99b.tar.gz linux-stable-df013212a1b6557f071609983cab0612f71fd99b.tar.bz2 linux-stable-df013212a1b6557f071609983cab0612f71fd99b.zip |
Merge tag 'iio-fixes-for-4.7b' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-linus
Jonathan writes:
Second set of IIO fixes for the 4.7 cycle.
This includes one tracked regression (Arnd's patch for the ad7606).
The other two have I think always been broken.
* inv_mpu6050
- Fix a use after free in the ACPI code.
* ad5933
- The code for setting the cycles had a bug that meant it was simply wrong.
* ad7606_spi
- Fix a regression that got introduced in a buggy cleanup of a sparse
warning.
Diffstat (limited to 'drivers/iio')
-rw-r--r-- | drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c b/drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c index f62b8bd9ad7e..dd6fc6d21f9d 100644 --- a/drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c +++ b/drivers/iio/imu/inv_mpu6050/inv_mpu_acpi.c @@ -56,6 +56,7 @@ static int asus_acpi_get_sensor_info(struct acpi_device *adev, int i; acpi_status status; union acpi_object *cpm; + int ret; status = acpi_evaluate_object(adev->handle, "CNF0", NULL, &buffer); if (ACPI_FAILURE(status)) @@ -82,10 +83,10 @@ static int asus_acpi_get_sensor_info(struct acpi_device *adev, } } } - + ret = cpm->package.count; kfree(buffer.pointer); - return cpm->package.count; + return ret; } static int acpi_i2c_check_resource(struct acpi_resource *ares, void *data) |