Linux IIO development
 help / color / mirror / Atom feed
* [PATCH 00/11] iio: use devm_regulator_get_enable_read_voltage round 6
@ 2024-11-20 21:33 David Lechner
  2024-11-20 21:33 ` [PATCH 01/11] iio: dac: ad5624r: fix struct name in doc comment David Lechner
                   ` (10 more replies)
  0 siblings, 11 replies; 19+ messages in thread
From: David Lechner @ 2024-11-20 21:33 UTC (permalink / raw)
  To: Jonathan Cameron
  Cc: Michael Hennerich, Liam Girdwood, Mark Brown, Antoniu Miclaus,
	Nuno Sá, linux-iio, linux-kernel, David Lechner

This series includes the last of the low-hanging fruit for converting
to devm_regulator_get_enable_read_voltage().

By low-hanging fruit, I mean that these are the drivers that read the
voltage of a regulator in the probe function. If you grep for this, you
will still find a few that do this, but in those cases, they usually
have power management where we need a handle to the regulator to power
things down and back up in suspend/resume. So we can't take advantage of
this helper function in those cases.

There is another class of drivers that could potentially make use of
this helper function that I haven't addressed. There are many drivers
that call regulator_get_voltage() in the IIO_CHAN_INFO_SCALE case of
the read_raw() callback. In most of these cases we could move the call
to regulator_get_voltage() to the probe function and store the value in
the private data structure instead. For those, we would need to be a bit
careful though to make sure the the intention wasn't to handle a change
in voltage during operation.

As a bonus, this series also includes a few other minor cleanups to fix
some copy/paste typos and remove some driver remove() callbacks.

---
David Lechner (11):
      iio: dac: ad5624r: fix struct name in doc comment
      iio: dac: ad5686: fix struct name in doc comment
      iio: dac: ad5686: use devm_regulator_get_enable_read_voltage()
      iio: dac: ad5686: drop driver remove function
      iio: dac: ad7293: use devm_regulator_get_enable_read_voltage()
      iio: dac: ad8801: use devm_regulator_get_enable_read_voltage()
      iio: dac ad8801: drop driver remove function
      iio: dac: ltc2632: use devm_regulator_get_enable_read_voltage()
      iio: dac ltc2632: drop driver remove function
      iio: dac: ltc2688: use devm_regulator_get_enable_read_voltage()
      iio: dac: max5821: use devm_regulator_get_enable_read_voltage()

 drivers/iio/dac/ad5624r.h    |  2 +-
 drivers/iio/dac/ad5686-spi.c |  6 ----
 drivers/iio/dac/ad5686.c     | 62 ++++++++-------------------------
 drivers/iio/dac/ad5686.h     |  6 +---
 drivers/iio/dac/ad5696-i2c.c |  6 ----
 drivers/iio/dac/ad7293.c     | 66 ++++++------------------------------
 drivers/iio/dac/ad8801.c     | 81 +++++++-------------------------------------
 drivers/iio/dac/ltc2632.c    | 69 +++++++++++--------------------------
 drivers/iio/dac/ltc2688.c    | 44 ++++++------------------
 drivers/iio/dac/max5821.c    | 36 +++-----------------
 10 files changed, 74 insertions(+), 304 deletions(-)
---
base-commit: 414c97c966b69e4a6ea7b32970fa166b2f9b9ef0
change-id: 20241120-iio-regulator-cleanup-round-6-78b05be06718

Best regards,
-- 
David Lechner <dlechner@baylibre.com>


^ permalink raw reply	[flat|nested] 19+ messages in thread

end of thread, other threads:[~2024-11-23 15:55 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-20 21:33 [PATCH 00/11] iio: use devm_regulator_get_enable_read_voltage round 6 David Lechner
2024-11-20 21:33 ` [PATCH 01/11] iio: dac: ad5624r: fix struct name in doc comment David Lechner
2024-11-20 21:33 ` [PATCH 02/11] iio: dac: ad5686: " David Lechner
2024-11-20 21:33 ` [PATCH 03/11] iio: dac: ad5686: use devm_regulator_get_enable_read_voltage() David Lechner
2024-11-20 21:33 ` [PATCH 04/11] iio: dac: ad5686: drop driver remove function David Lechner
2024-11-23 15:45   ` Jonathan Cameron
2024-11-20 21:33 ` [PATCH 05/11] iio: dac: ad7293: use devm_regulator_get_enable_read_voltage() David Lechner
2024-11-23 15:50   ` Jonathan Cameron
2024-11-20 21:33 ` [PATCH 06/11] iio: dac: ad8801: " David Lechner
2024-11-23 15:51   ` Jonathan Cameron
2024-11-20 21:33 ` [PATCH 07/11] iio: dac ad8801: drop driver remove function David Lechner
2024-11-23 15:52   ` Jonathan Cameron
2024-11-20 21:33 ` [PATCH 08/11] iio: dac: ltc2632: use devm_regulator_get_enable_read_voltage() David Lechner
2024-11-23 15:53   ` Jonathan Cameron
2024-11-20 21:33 ` [PATCH 09/11] iio: dac ltc2632: drop driver remove function David Lechner
2024-11-23 15:54   ` Jonathan Cameron
2024-11-20 21:33 ` [PATCH 10/11] iio: dac: ltc2688: use devm_regulator_get_enable_read_voltage() David Lechner
2024-11-23 15:55   ` Jonathan Cameron
2024-11-20 21:33 ` [PATCH 11/11] iio: dac: max5821: " David Lechner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox