Re: [PATCH 12/12] iio: accel: kionix-kx022a: Fix IPOL macro name
Mehdi Djait <[email protected]>
| Newsgroups | org.kernel.vger.linux-iio,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <anxdf0ee_-CpDU1S@mdjait-mobl> |
Hi Matti, Thank you for the patch! On Mon, Aug 10, 2026 at 10:55:25AM +0300, Matti Vaittinen wrote: > From: Matti Vaittinen <[email protected]> > > The "interrupt polarity high" -macro for KX022A variant is defined as: -macro ? defined as what ? > However, the KX022A_MASK_IPOL1 is not defined anywhere, so actually > using the KX022A_IPOL_HIGH would produce a compile error. > > Fix the define by using correct mask. Reviewed-by: Mehdi Djait <[email protected]> > > Signed-off-by: Matti Vaittinen <[email protected]> > Fixes: 7c1d1677b322 ("iio: accel: Support Kionix/ROHM KX022A accelerometer") > > --- > It appears the KX022A_IPOL_HIGH is unused as the IRQ is currently, > unconditionally set level low in kx022a_prepare_irq_pin(). The KX022A > hardware would support other configurations though. So, another > potential fix would be removing the define altogether. I decided to > leave the define there, as having it will allow users who need different > configuration to simply change the KX022A_IPOL_LOW to KX022A_IPOL_HIGH, > which is kind of a "easy to try" thing. > > I don't have a strong preference here though. This is up to Jonathan. Removing this also makes sense (and if you decide to do then probably do it for KX132 also) -- Kind Regards Mehdi Djait