All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 0/3] iio: chemical: Add Senseair Sunrise CO2 sensor
@ 2021-09-03 14:48 Jacopo Mondi
  2021-09-03 14:48 ` [PATCH v4 1/3] dt-bindings: iio: chemical: Document senseair,sunrise " Jacopo Mondi
                   ` (2 more replies)
  0 siblings, 3 replies; 13+ messages in thread
From: Jacopo Mondi @ 2021-09-03 14:48 UTC (permalink / raw)
  To: Jonathan Cameron, Lars-Peter Clausen, Andy Shevchenko,
	Matt Ranostay, Magnus Damm
  Cc: Jacopo Mondi, linux-iio

The driver supports continuous reads of temperature and CO2 concentration
through two dedicated IIO channels. It also supports calibration and error
inspection through the concentration channel ext_info.

A few substantial changes in v4, mostly in the calibration attributes
definition but also in the driver code

v3->v4
 - Rebased on v5.14
 - Remove unneeded Kconfig symbol dependencies
 - Remove unused header inclusion
 - Lock access to calibration and error status
 - Fix temperature scale
 - Fix for_each_set_bit()
 - Drop a few fields from driver's main structure
 - Lock the 'wakeup' session with an additional mutex
 - Disable regmap locking as the access to the i2c bus is now externally locked
 - Rework the calibration attributes defintion: one attribute per calibration
   mode
 - Make 'error_status' attributes SHARED_BY_ALL
 - Replace regmap_read_poll_timeout() with read_poll_timeout() to use
   the driver's byte read function that performs the proper chip 'wakeup'.
   It used to work with the previous version too, a few spurious NAK apart but
   this seems cleaner and allows to relax the sleep time
 - Update ABI documentation according to the new attributes layout
 - Remove label from bindings doc

v2->v3:
- [1/3]
 - Fix syntax error reported by dt_binding_check
   The device node label in the example cannot contain '-'
 - Add 'Typically' to the gpios polarities description

- [2/3]
 - As suggested by Andy:
   - depends on OF, SYSFS; select REGMAP_I2C
   - Fix style issues:
     - span over 80 cols where appropriate
     - remove , in last entries of all arrays
     - use for_each_set_bit in sunrise_error_status_read()
     - minor style issues (brakets, empty lines, wording)

v1->v2:
- Add ABI documentation in [3/3]
- [1/3]
  - Address Rob's comments on missing maxItem and add device node label
  - Do not change the pin's polarity description as suggested by Andy due to
    conflicting suggestions
- [2/3]
  - Expand Kconfig symbol name and change driver's name as suggested by Andy
  - Use regmap instead of raw smbus calls as suggested by Andy
  - Take into account minor style comments from Andy
  - Install channel's ext_info to support calibration triggering and enumerate
    calibration modes and error status
  - Matt suggested to use sysfs attributes, but I found the per-channel
    attributes more appropriate. Hope this is good as well.


Jacopo Mondi (3):
  dt-bindings: iio: chemical: Document senseair,sunrise CO2 sensor
  iio: chemical: Add Senseair Sunrise 006-0-007 driver
  iio: ABI: docs: Document Senseair Sunrise ABI

 .../sysfs-bus-iio-chemical-sunrise-co2        |  38 ++
 .../iio/chemical/senseair,sunrise.yaml        |  55 +++
 .../devicetree/bindings/vendor-prefixes.yaml  |   2 +
 MAINTAINERS                                   |   6 +
 drivers/iio/chemical/Kconfig                  |  10 +
 drivers/iio/chemical/Makefile                 |   1 +
 drivers/iio/chemical/sunrise_co2.c            | 462 ++++++++++++++++++
 7 files changed, 574 insertions(+)
 create mode 100644 Documentation/ABI/testing/sysfs-bus-iio-chemical-sunrise-co2
 create mode 100644 Documentation/devicetree/bindings/iio/chemical/senseair,sunrise.yaml
 create mode 100644 drivers/iio/chemical/sunrise_co2.c

--
2.32.0


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

end of thread, other threads:[~2021-09-09  8:42 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-09-03 14:48 [PATCH v4 0/3] iio: chemical: Add Senseair Sunrise CO2 sensor Jacopo Mondi
2021-09-03 14:48 ` [PATCH v4 1/3] dt-bindings: iio: chemical: Document senseair,sunrise " Jacopo Mondi
2021-09-03 14:48 ` [PATCH v4 2/3] iio: chemical: Add Senseair Sunrise 006-0-007 driver Jacopo Mondi
2021-09-03 15:36   ` Andy Shevchenko
2021-09-03 16:43     ` Jacopo Mondi
2021-09-03 20:21       ` Andy Shevchenko
2021-09-05 10:37         ` Jonathan Cameron
2021-09-05 21:10   ` Matt Ranostay
2021-09-08 12:48     ` Jacopo Mondi
2021-09-08 16:56       ` Jonathan Cameron
2021-09-09  8:43         ` Jacopo Mondi
2021-09-03 14:48 ` [PATCH v4 3/3] iio: ABI: docs: Document Senseair Sunrise ABI Jacopo Mondi
2021-09-05 10:52   ` Jonathan Cameron

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.