mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: Jean-Baptiste Maneyrol via B4 Relay
	<devnull+jean-baptiste.maneyrol.tdk.com@kernel.org>
Cc: jean-baptiste.maneyrol@tdk.com,
	"Remi Buisson" <remi.buisson@tdk.com>,
	"David Lechner" <dlechner@baylibre.com>,
	"Nuno Sá" <nuno.sa@analog.com>,
	"Andy Shevchenko" <andy@kernel.org>,
	"Jonathan Cameron" <Jonathan.Cameron@huawei.com>,
	linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org,
	stable@vger.kernel.org
Subject: Re: [PATCH v3] iio: imu: inv_icm45600: fix INT1 drive bit inverted
Date: Thu, 5 Feb 2026 19:13:21 +0000	[thread overview]
Message-ID: <20260205191321.7e5f7b49@jic23-huawei> (raw)
In-Reply-To: <20260205-inv-icm45600-fix-int1-drive-bit-v3-1-9c60c354dadb@tdk.com>

On Thu, 05 Feb 2026 17:59:14 +0100
Jean-Baptiste Maneyrol via B4 Relay <devnull+jean-baptiste.maneyrol.tdk.com@kernel.org> wrote:

> From: Jean-Baptiste Maneyrol <jean-baptiste.maneyrol@tdk.com>
> 
> Drive bit must be set for open-drain mode and be cleared for push-pull
> mode.
> 
> Referring to datasheet DS-000576_ICM-45605.pdf section 17.23
> INT1_CONFIG2.
> 
> Fixes: 06674a72cf7a ("iio: imu: inv_icm45600: add buffer support in iio devices")
> Signed-off-by: Jean-Baptiste Maneyrol <jean-baptiste.maneyrol@tdk.com>
> Reviewed-by: Andy Shevchenko <andy@kernel.org>
> Cc: stable@vger.kernel.org
Applied to the fixes-togreg branch of iio.git. Note that has a
random base at the moment, so I'll wait for release or rc1 and then
rebase on that before pushing out.

Thanks,

Jonathan

> ---
> Changes in v3:
> - Add precisions in datasheet reference
> - Add missing reviewed-by tag
> - Link to v2: https://lore.kernel.org/r/20260205-inv-icm45600-fix-int1-drive-bit-v2-1-5e72608ea154@tdk.com
> 
> Changes in v2:
> - Add datasheet precision where to find the bits
> - Link to v1: https://lore.kernel.org/r/20260205-inv-icm45600-fix-int1-drive-bit-v1-1-72a78cd07150@tdk.com
> ---
>  drivers/iio/imu/inv_icm45600/inv_icm45600.h      | 2 +-
>  drivers/iio/imu/inv_icm45600/inv_icm45600_core.c | 4 ++--
>  2 files changed, 3 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/iio/imu/inv_icm45600/inv_icm45600.h b/drivers/iio/imu/inv_icm45600/inv_icm45600.h
> index c5b5446f6c3b43150512bcc4357cee385080b634..1c796d4b2a4038203f734f80d7bf7bad138c3497 100644
> --- a/drivers/iio/imu/inv_icm45600/inv_icm45600.h
> +++ b/drivers/iio/imu/inv_icm45600/inv_icm45600.h
> @@ -205,7 +205,7 @@ struct inv_icm45600_sensor_state {
>  #define INV_ICM45600_SPI_SLEW_RATE_38NS			0
>  
>  #define INV_ICM45600_REG_INT1_CONFIG2			0x0018
> -#define INV_ICM45600_INT1_CONFIG2_PUSH_PULL		BIT(2)
> +#define INV_ICM45600_INT1_CONFIG2_OPEN_DRAIN		BIT(2)
>  #define INV_ICM45600_INT1_CONFIG2_LATCHED		BIT(1)
>  #define INV_ICM45600_INT1_CONFIG2_ACTIVE_HIGH		BIT(0)
>  #define INV_ICM45600_INT1_CONFIG2_ACTIVE_LOW		0x00
> diff --git a/drivers/iio/imu/inv_icm45600/inv_icm45600_core.c b/drivers/iio/imu/inv_icm45600/inv_icm45600_core.c
> index ab1cb7b9dba435a3280e50ab77cd16e903c7816c..b028044d609a41f6d4b747383323130ded0d2e79 100644
> --- a/drivers/iio/imu/inv_icm45600/inv_icm45600_core.c
> +++ b/drivers/iio/imu/inv_icm45600/inv_icm45600_core.c
> @@ -637,8 +637,8 @@ static int inv_icm45600_irq_init(struct inv_icm45600_state *st, int irq,
>  		break;
>  	}
>  
> -	if (!open_drain)
> -		val |= INV_ICM45600_INT1_CONFIG2_PUSH_PULL;
> +	if (open_drain)
> +		val |= INV_ICM45600_INT1_CONFIG2_OPEN_DRAIN;
>  
>  	ret = regmap_write(st->map, INV_ICM45600_REG_INT1_CONFIG2, val);
>  	if (ret)
> 
> ---
> base-commit: d820183f371d9aa8517a1cd21fe6edacf0f94b7f
> change-id: 20260205-inv-icm45600-fix-int1-drive-bit-7d12ea3e2cd2
> 
> Best regards,


      reply	other threads:[~2026-02-05 19:13 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-02-05 16:59 Jean-Baptiste Maneyrol via B4 Relay
2026-02-05 19:13 ` Jonathan Cameron [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260205191321.7e5f7b49@jic23-huawei \
    --to=jic23@kernel.org \
    --cc=Jonathan.Cameron@huawei.com \
    --cc=andy@kernel.org \
    --cc=devnull+jean-baptiste.maneyrol.tdk.com@kernel.org \
    --cc=dlechner@baylibre.com \
    --cc=jean-baptiste.maneyrol@tdk.com \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nuno.sa@analog.com \
    --cc=remi.buisson@tdk.com \
    --cc=stable@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®