Home
last modified time | relevance | path

Searched hist:"20690 cd5" (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/drivers/iio/accel/
H A Dbma400_core.c20690cd5 Wed Nov 09 19:07:26 CST 2022 Dong Chenchen <dongchenchen2@huawei.com> iio: accel: bma400: Fix memory leak in bma400_get_steps_reg()

When regmap_bulk_read() fails, it does not free steps_raw,
which will cause a memory leak issue, this patch fixes it.

Fixes: d221de60eee3 ("iio: accel: bma400: Add separate channel for step counter")
Signed-off-by: Dong Chenchen <dongchenchen2@huawei.com>
Reviewed-by: Jagath Jog J <jagathjog1996@gmail.com>
Link: https://lore.kernel.org/r/20221110010726.235601-1-dongchenchen2@huawei.com
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>