public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v6 0/3] iio: magnetometer: bmc150_magn: cleanup and formatting
@ 2026-02-10 23:39 Neel Bullywon
  2026-02-10 23:39 ` [PATCH v6 1/3] iio: magnetometer: bmc150_magn: use automated cleanup for mutex Neel Bullywon
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Neel Bullywon @ 2026-02-10 23:39 UTC (permalink / raw)
  To: jic23; +Cc: dlechner, nuno.sa, andy, linux-iio, linux-kernel, Neel Bullywon

This series cleans up the bmc150_magn driver in three patches:

1/3: Replace manual mutex lock/unlock with guard()/scoped_guard()
2/3: Replace msleep(5) with fsleep(5 * USEC_PER_MSEC)
3/3: Minor formatting cleanup for initializer lists and indentation

Changes in v6:
- Split fsleep change into its own patch (Andy).
- Use scoped_guard() instead of { guard() } for the IIO_CHAN_INFO_RAW
  case block in read_raw (Andy).
- Use 5 * USEC_PER_MSEC instead of 5000 for fsleep (Andy).
- Restyle bmc150_magn_samp_freq_table to group four entries per line
  with index comments (Andy).
- Remove trailing comma from scan_masks terminator (Andy).

Changes in v5:
- Split into two patches: functional and formatting (Jonathan).
- Use fsleep() instead of usleep_range() (Jonathan).
- Use scoped_guard() for short single-statement scopes (Jonathan).
- Add {} scope for guard() in case blocks (Jonathan).
- Leave trigger_handler unchanged (Jonathan).
- Drop all unnecessary reformatting (Jonathan).

Changes in v4:
- Extend guard() usage to all mutex_lock() instances in the driver.
- Replace msleep(5) with usleep_range(5000, 6000).

Changes in v3:
- Add Reviewed-by tags.

Changes in v2:
- Use guard() for mutex protection in bmc150_magn_data_rdy_trigger_set_state.

Neel Bullywon (3):
  iio: magnetometer: bmc150_magn: use automated cleanup for mutex
  iio: magnetometer: bmc150_magn: replace msleep with fsleep
  iio: magnetometer: bmc150_magn: minor formatting cleanup

 drivers/iio/magnetometer/bmc150_magn.c | 157 ++++++++++---------------
 1 file changed, 64 insertions(+), 93 deletions(-)


base-commit: e7aa57247700733e52a8e2e4dee6a52c2a76de02
-- 
2.44.0


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

end of thread, other threads:[~2026-02-14 18:00 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-02-10 23:39 [PATCH v6 0/3] iio: magnetometer: bmc150_magn: cleanup and formatting Neel Bullywon
2026-02-10 23:39 ` [PATCH v6 1/3] iio: magnetometer: bmc150_magn: use automated cleanup for mutex Neel Bullywon
2026-02-11  8:39   ` Andy Shevchenko
2026-02-13 23:31   ` kernel test robot
2026-02-14 16:34     ` Jonathan Cameron
2026-02-14 16:28   ` David Lechner
2026-02-10 23:39 ` [PATCH v6 2/3] iio: magnetometer: bmc150_magn: replace msleep with fsleep Neel Bullywon
2026-02-11  8:40   ` Andy Shevchenko
2026-02-10 23:39 ` [PATCH v6 3/3] iio: magnetometer: bmc150_magn: minor formatting cleanup Neel Bullywon
2026-02-11  8:41   ` Andy Shevchenko
2026-02-14 16:31   ` David Lechner
2026-02-14 18:00     ` Andy Shevchenko

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