iio: st_pressure: st_accel: Fix initialization of platform_data
Status from this message: Applied to the fixes-togreg branch of iio.git.
Get series with b4
b4 am [email protected]Versions newest first
Patches in v1 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | iio: accel: Revert "iio: accel: st_accel: remove redundant pointer pdata"drivers/ | +5 | 0 replies | |
| 2/2 | iio: st_pressure: st_accel: pass correct platform data to initdrivers/ drivers/ | +2 | 2 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH 0/2] iio: st_pressure: st_accel: Fix initialization of platform_data
Commit 7383d44b added a pointer pdata which gets initialized with the default platform_data when non was defined. But it did not pass this pointer to the st_sensors_init_sensor call but still used the maybe uninitialized platform_data from dev.
This breaks initialization when no platform_data is given and the optional st,drdy-int-pin devicetree option is not set.
As pdata was not used at all after this a subsequent commit removed the setting of pdata. As it is needed to fix this the first patch reverts that commit.
Michael Nosthoff (2):
iio: accel: Revert "iio: accel: st_accel: remove redundant pointer
pdata"
iio: st_pressure: st_accel: pass correct platform data to init
drivers/iio/accel/st_accel_core.c | 7 ++++++- drivers/iio/pressure/st_pressure_core.c | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-)
Signature · 1 line
2.7.4