mbox series

[0/1] iio: bmi323: have the peripheral consume less power

Message ID 20240811161202.19818-1-benato.denis96@gmail.com (mailing list archive)
Headers show
Series iio: bmi323: have the peripheral consume less power | expand

Message

Denis Benato Aug. 11, 2024, 4:12 p.m. UTC
The bmi323 chip is part of handhelds PCs that are run on battery.

One of said PC is well-known for its short battery life, even in s2idle:
help mitigate that by putting the device in its lowest-consumption
state while the peripheral is unused.

Have runtime-pm suspend callback save used configuration registers
and runtime-pm resume callback restore saved registers to restore
the previous state.

Signed-off-by: Denis Benato <benato.denis96@gmail.com>

Denis Benato (1):
  iio: bmi323: peripheral in lowest power state on suspend

 drivers/iio/imu/bmi323/bmi323.h      |   1 +
 drivers/iio/imu/bmi323/bmi323_core.c | 183 ++++++++++++++++++++++++++-
 drivers/iio/imu/bmi323/bmi323_i2c.c  |   8 ++
 drivers/iio/imu/bmi323/bmi323_spi.c  |   8 ++
 4 files changed, 194 insertions(+), 6 deletions(-)