mbox series

[v1,00/13] : chemical: bme680: 2nd set of clean and add

Message ID 20241010210030.33309-1-vassilisamir@gmail.com (mailing list archive)
Headers show
Series : chemical: bme680: 2nd set of clean and add | expand

Message

Vasileios Amoiridis Oct. 10, 2024, 9 p.m. UTC
This patch series is continuing the work that started on [1] by
improving some small issues of the driver in the commits 1,2,3.

Commits 4,5 are refactorizing existing code.

Commits 6,7,8 are adding DT, regulator and PM support.

Commit 9 is refactorizing one macro to attribute.

Commit 10,11,12 are refactorizing the read/compensate functions
to become generic and add triggered buffer support.

Finally, commit 13 adds support for an *output* channel of type
IIO_CURRENT in order to preheat the plate that is used to measure the
quality of the air.

This and the previous series [1] started with the idea to add support
for the new bme688 device but due to the structure of the driver I
decided that it is better to restructure and improve some things before
adding extra funcitonalities.

[1]: https://lore.kernel.org/linux-iio/20240609233826.330516-1-vassilisamir@gmail.com

Vasileios Amoiridis (13):
  iio: chemical: bme680: Fix indentation and unnecessary spaces
  iio: chemical: bme680: avoid using camel case
  iio: chemical: bme680: fix startup time
  iio: chemical: bme680: move to fsleep()
  iio: chemical: bme680: refactorize set_mode() mode
  dt-bindings: iio: add binding for BME680 driver
  iio: chemical: bme680: add regulators
  iio: chemical: bme680: add power management
  iio: chemical: bme680: Move ambient temperature to attributes
  iio: chemical: bme680: generalize read_*() functions
  iio: chemical: bme680: Add SCALE and RAW channels
  iio: chemical: bme680: Add triggered buffer support
  iio: chemical: bme680: Add support for preheat current

 .../bindings/iio/chemical/bosch,bme680.yaml   |  64 ++
 drivers/iio/chemical/Kconfig                  |   2 +
 drivers/iio/chemical/bme680.h                 |   7 +-
 drivers/iio/chemical/bme680_core.c            | 554 +++++++++++++++---
 4 files changed, 556 insertions(+), 71 deletions(-)
 create mode 100644 Documentation/devicetree/bindings/iio/chemical/bosch,bme680.yaml

Comments

Andy Shevchenko Oct. 11, 2024, 10:42 a.m. UTC | #1
On Thu, Oct 10, 2024 at 11:00:17PM +0200, vamoirid wrote:
> This patch series is continuing the work that started on [1] by
> improving some small issues of the driver in the commits 1,2,3.
> 
> Commits 4,5 are refactorizing existing code.
> 
> Commits 6,7,8 are adding DT, regulator and PM support.
> 
> Commit 9 is refactorizing one macro to attribute.
> 
> Commit 10,11,12 are refactorizing the read/compensate functions
> to become generic and add triggered buffer support.
> 
> Finally, commit 13 adds support for an *output* channel of type
> IIO_CURRENT in order to preheat the plate that is used to measure the
> quality of the air.
> 
> This and the previous series [1] started with the idea to add support
> for the new bme688 device but due to the structure of the driver I
> decided that it is better to restructure and improve some things before
> adding extra funcitonalities.

Besides the small comments here and there I think you need to rearrange the
patches layout in the series.

In general it should go in these blocks:
1) bug fixes (if any);
2) cleanups (note, whitespace-cleanup-like are the last);
3) new feature.

Note that PM runtime belongs to the last group quite close to the patches
where you more or less start using it more.
Vasileios Amoiridis Oct. 11, 2024, 6:39 p.m. UTC | #2
On Fri, Oct 11, 2024 at 01:42:04PM +0300, Andy Shevchenko wrote:
> On Thu, Oct 10, 2024 at 11:00:17PM +0200, vamoirid wrote:
> > This patch series is continuing the work that started on [1] by
> > improving some small issues of the driver in the commits 1,2,3.
> > 
> > Commits 4,5 are refactorizing existing code.
> > 
> > Commits 6,7,8 are adding DT, regulator and PM support.
> > 
> > Commit 9 is refactorizing one macro to attribute.
> > 
> > Commit 10,11,12 are refactorizing the read/compensate functions
> > to become generic and add triggered buffer support.
> > 
> > Finally, commit 13 adds support for an *output* channel of type
> > IIO_CURRENT in order to preheat the plate that is used to measure the
> > quality of the air.
> > 
> > This and the previous series [1] started with the idea to add support
> > for the new bme688 device but due to the structure of the driver I
> > decided that it is better to restructure and improve some things before
> > adding extra funcitonalities.
> 
> Besides the small comments here and there I think you need to rearrange the
> patches layout in the series.
> 
> In general it should go in these blocks:
> 1) bug fixes (if any);
> 2) cleanups (note, whitespace-cleanup-like are the last);
> 3) new feature.
> 
> Note that PM runtime belongs to the last group quite close to the patches
> where you more or less start using it more.
> 
> -- 
> With Best Regards,
> Andy Shevchenko
> 
>

Hello Andy,

Thank you very much for taking the time to review this, I appreciate it
a lot. I was not sure about the order of the patches but what you
explained here makes total sense. I will rework the order and address
the rest of the comments.

Cheers,
Vasilis