public inbox for linux-doc@vger.kernel.org
 help / color / mirror / Atom feed
* Re: [PATCH v1 06/12] iio: accel: adxl313: prepare interrupt handling
@ 2025-05-20 19:32 Lothar Rubusch
  2025-05-20 19:49 ` Andy Shevchenko
  0 siblings, 1 reply; 5+ messages in thread
From: Lothar Rubusch @ 2025-05-20 19:32 UTC (permalink / raw)
  To: andy, jic23, dlechner, nuno.sa, corbet, lucas.p.stankus, lars,
	Michael.Hennerich
  Cc: linux-iio, linux-doc, linux-kernel, Lothar Rubusch

Hi Andy, I forgot to put my mail addresses as well. I copied your answer
now from the mailing list archive. Hence, sorry for the bad formatting
of this mail.

One question / remark down below.

> On Sun, May 18, 2025 at 11:13:15AM +0000, Lothar Rubusch wrote:
> > Evaluate the devicetree property for an optional interrupt line, and
> > configure the interrupt mapping accordingly. When no interrupt line
> > is defined in the devicetree, keep the FIFO in bypass mode as before.
>
> ...
>
> > +        ret = regmap_write(data->regmap, ADXL313_REG_INT_MAP, regval);
>
> Don't you want to use regmap_assign_bits() or something like this to have
> the above ternary be included?
>

Thank you so much. I guess this is a function I was looking for quite
a while and I
know several places where to use it.

Anyway, I saw, my hardware test setup still runs on an older kernel
w/o regmap_assign_bits().
So, I kindly liked to ask if you have any objections against leaving
regmap_write() for now? Actually I'd prefer first to see the
activity/inactivity stuff in, in case this will need some more
modifications and I need to verify them on hardware. I think, leaving
regmap_write() here would make that easier for this patch set. Please,
let me know?

I'm about to send a v2, for the follow up discussion.
Best,
L

> > +        if (ret)
> > +            return ret;
>

^ permalink raw reply	[flat|nested] 5+ messages in thread
* [PATCH v1 00/12] iio: accel: adxl313: add power-save on activity/inactivity
@ 2025-05-18 11:13 Lothar Rubusch
  2025-05-18 11:13 ` [PATCH v1 06/12] iio: accel: adxl313: prepare interrupt handling Lothar Rubusch
  0 siblings, 1 reply; 5+ messages in thread
From: Lothar Rubusch @ 2025-05-18 11:13 UTC (permalink / raw)
  To: jic23, dlechner, nuno.sa, andy, corbet, lucas.p.stankus, lars,
	Michael.Hennerich
  Cc: linux-iio, linux-doc, linux-kernel, Lothar Rubusch

The patch set covers the following topics:
- add debug register and regmap cache
- prepare iio channel scan_type and scan_index
- prepare interrupt handling
- implement fifo with watermark
- add activity/inactivity together with auto-sleep with link bit
- documentation

Similar situation and approach as for the ADXL345. AC/DC coupling might be
a pending option as it is quite the same as for ADXL345.

Since activity and inactivity here are implemented covering all axis, I
assumed x&y&z. Thus the driver uses a fake channel for activity/inactiviy.

Signed-off-by: Lothar Rubusch <l.rubusch@gmail.com>
---
Lothar Rubusch (12):
  iio: accel: adxl313: add debug register
  iio: accel: adxl313: introduce channel scan_index
  iio: accel: adxl313: configure scan type for buffer
  iio: accel: adxl313: make use of regmap cache
  iio: accel: adxl313: add function to enable measurement
  iio: accel: adxl313: prepare interrupt handling
  iio: accel: adxl313: add basic interrupt handling
  iio: accel: adxl313: add FIFO watermark
  iio: accel: adxl313: add activity sensing
  iio: accel: adxl313: add inactivity sensing
  iio: accel: adxl313: implement power-save on inactivity
  docs: iio: add ADXL313 accelerometer

 Documentation/iio/adxl313.rst    | 196 +++++++++
 Documentation/iio/index.rst      |   1 +
 drivers/iio/accel/adxl313.h      |  35 +-
 drivers/iio/accel/adxl313_core.c | 658 ++++++++++++++++++++++++++++++-
 drivers/iio/accel/adxl313_i2c.c  |   6 +
 drivers/iio/accel/adxl313_spi.c  |   6 +
 6 files changed, 893 insertions(+), 9 deletions(-)
 create mode 100644 Documentation/iio/adxl313.rst

-- 
2.39.5


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

end of thread, other threads:[~2025-05-25 11:26 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-05-20 19:32 [PATCH v1 06/12] iio: accel: adxl313: prepare interrupt handling Lothar Rubusch
2025-05-20 19:49 ` Andy Shevchenko
2025-05-25 11:26   ` Jonathan Cameron
  -- strict thread matches above, loose matches on Subject: below --
2025-05-18 11:13 [PATCH v1 00/12] iio: accel: adxl313: add power-save on activity/inactivity Lothar Rubusch
2025-05-18 11:13 ` [PATCH v1 06/12] iio: accel: adxl313: prepare interrupt handling Lothar Rubusch
2025-05-19 11:48   ` Andy Shevchenko

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