Linux IIO development
 help / color / mirror / Atom feed
From: David Lechner <dlechner@baylibre.com>
To: "Jonathan Cameron" <jic23@kernel.org>, "Nuno Sá" <noname.nuno@gmail.com>
Cc: "Michael Hennerich" <Michael.Hennerich@analog.com>,
	"Nuno Sá" <nuno.sa@analog.com>,
	"Andy Shevchenko" <andy@kernel.org>,
	"Guillaume Ranquet" <granquet@baylibre.com>,
	"Jonathan Cameron" <Jonathan.Cameron@huawei.com>,
	linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] iio: adc: ad7313: fix calibration channel
Date: Thu, 10 Jul 2025 17:03:34 -0500	[thread overview]
Message-ID: <8c599d2e-a5bb-46e9-9f6f-781a6933fe1b@baylibre.com> (raw)
In-Reply-To: <20250709165819.1015259e@jic23-huawei>

On 7/9/25 10:58 AM, Jonathan Cameron wrote:
> On Wed, 09 Jul 2025 10:33:32 +0100
> Nuno Sá <noname.nuno@gmail.com> wrote:
> 
>> On Tue, 2025-07-08 at 20:38 -0500, David Lechner wrote:
>>> Fix the channel index values passed to ad_sd_calibrate() in
>>> ad7173_calibrate_all().
>>>
>>> ad7173_calibrate_all() expects these values to be that of the CHANNELx
>>> register assigned to the channel, not the datasheet INPUTx number of the
>>> channel. The incorrect values were causing register writes to fail for
>>> some channels because they set the WEN bit that must always be 0 for
>>> register access and set the R/W bit to read instead of write. For other
>>> channels, the channel number was just wrong because the CHANNELx
>>> registers are generally assigned in reverse order and so almost never
>>> match the INPUTx numbers.
>>>
>>> Fixes: 031bdc8aee01 ("iio: adc: ad7173: add calibration support")
>>> Signed-off-by: David Lechner <dlechner@baylibre.com>
>>> ---  
>>
>> Reviewed-by: Nuno Sá <nuno.sa@analog.com>
>>
> Applied to the fixes-togreg branch of iio.git.
> 
Just noticed a typo in the subject. Should be ad7173, not ad7313.

      reply	other threads:[~2025-07-10 22:03 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-09  1:38 [PATCH] iio: adc: ad7313: fix calibration channel David Lechner
2025-07-09  9:33 ` Nuno Sá
2025-07-09 15:58   ` Jonathan Cameron
2025-07-10 22:03     ` David Lechner [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=8c599d2e-a5bb-46e9-9f6f-781a6933fe1b@baylibre.com \
    --to=dlechner@baylibre.com \
    --cc=Jonathan.Cameron@huawei.com \
    --cc=Michael.Hennerich@analog.com \
    --cc=andy@kernel.org \
    --cc=granquet@baylibre.com \
    --cc=jic23@kernel.org \
    --cc=linux-iio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=noname.nuno@gmail.com \
    --cc=nuno.sa@analog.com \
    /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