Re: [PATCH v2 03/14] dt-bindings: iio: accel: bosch,bma220 change irq type

Petre Rodan
2025-09-11T09:53:27Z

[-- Attachment #1: Type: text/plain, Size: 1384 bytes --]

Hi Krzysztof,

On Thu, Sep 11, 2025 at 09:33:25AM +0200, Krzysztof Kozlowski wrote:
> On Wed, Sep 10, 2025 at 10:57:08AM +0300, Petre Rodan wrote:
> > Set the interrupt type to rising edge instead of high level.
> >
> > Quoting from the datasheet:
> >
> > "If at least one of the configured conditions applies, an interrupt
> > (logic ???1???) is issued through the INT pin of the sensor."
>
> I don't see how this explains/suggests raising edge.

well, I want my driver to react directly at the transition from lo to hi
(aka rising edge) of the INT signal.

why?
1. by default the latch register is disabled, thus the master (my driver) is not
expected to ack or clear any interrupt flag. the sensor controls when the INT line
deasserts. for instance during a tap interrupt the bottom half handles the rising
edge condition after 250-300us and the irq gets deasserted by the sensor 150-300ms
later without any other interaction from the driver.

which means that the time interval the trigger is asserted for can not be
controlled by the master (without tweaking the latch register).

2. there is no scenario in which an irq trigger that has been asserted before probe()
needs to be handled.

3. there is zero reason to handle one event multiple times.

these would be my reasons for gravitating toward edge triggering.

best regards,
peter

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]