From: Jonathan Cameron <jic23@kernel.org>
To: Fabio Estevam <festevam@gmail.com>
Cc: mazziesaccount@gmail.com, linux-iio@vger.kernel.org,
Fabio Estevam <festevam@denx.de>,
stable@vger.kernel.org
Subject: Re: [PATCH 2/2] iio: adc: max1363: Reorder max11607_mode_list[]
Date: Tue, 29 Apr 2025 18:35:52 +0100 [thread overview]
Message-ID: <20250429183552.6a87e4cb@jic23-huawei> (raw)
In-Reply-To: <20250429150213.2953747-2-festevam@gmail.com>
On Tue, 29 Apr 2025 12:02:13 -0300
Fabio Estevam <festevam@gmail.com> wrote:
> From: Fabio Estevam <festevam@denx.de>
>
> The IIO core emits warnings when a scan mask is a subset of a previous one
> in the available_scan_masks array.
>
> In the current max11607_mode_list[], the s0to3 mode (channels 0–3,
> mask 0xF) precedes the s2to3 mode (channels 2–3, mask 0xC). Since 0xC is a
> subset of 0xF, the following warning is triggered:
>
> max1363 1-0064: Mask 7 (0xc) is a subset of mask 6 (0xf) and will be ignored
>
> Reordering the max11607_mode_list[] to place s0to3 after s2to3 ensures that
> more specific scan modes are listed before broader ones, preventing such
> warnings.
>
> This change improves clarity and avoids unnecessary warnings during device
> initialization.
>
> Cc: stable@vger.kernel.org
> Fixes: 2718f15403fb ("iio: sanity check available_scan_masks array")
> Signed-off-by: Fabio Estevam <festevam@denx.de>
There are others in there that are out of order...
max1238_mode_list[] for example looks to be as s6to7 should be before s0to7
(there are more issues with that one).
Would you mind taking a quick look at all those others as I'd like
one fix for all of them if possible?
Thanks,
Jonathan
> ---
> drivers/iio/adc/max1363.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/iio/adc/max1363.c b/drivers/iio/adc/max1363.c
> index d0c6e94f7204..e8eeb00bef7b 100644
> --- a/drivers/iio/adc/max1363.c
> +++ b/drivers/iio/adc/max1363.c
> @@ -577,8 +577,8 @@ static const struct iio_chan_spec max1238_channels[] = MAX1363_12X_CHANS(12);
>
> static const enum max1363_modes max11607_mode_list[] = {
> _s0, _s1, _s2, _s3,
> - s0to1, s0to2, s0to3,
> - s2to3,
> + s0to1, s0to2, s2to3,
> + s0to3,
> d0m1, d2m3, d1m0, d3m2,
> d0m1to2m3, d1m0to3m2,
> };
next prev parent reply other threads:[~2025-04-29 17:35 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-29 15:02 [PATCH 1/2] iio: Fix scan mask subset check logic Fabio Estevam
2025-04-29 15:02 ` [PATCH 2/2] iio: adc: max1363: Reorder max11607_mode_list[] Fabio Estevam
2025-04-29 17:35 ` Jonathan Cameron [this message]
2025-04-29 18:37 ` Fabio Estevam
2025-04-29 17:33 ` [PATCH 1/2] iio: Fix scan mask subset check logic Jonathan Cameron
2025-04-29 18:33 ` Fabio Estevam
2025-04-29 19:05 ` Fabio Estevam
2025-04-30 13:11 ` Jonathan Cameron
2025-04-30 13:26 ` Fabio Estevam
2025-04-30 17:25 ` Jonathan Cameron
2025-04-30 19:37 ` Fabio Estevam
2025-05-03 12:02 ` Fabio Estevam
2025-05-04 17:06 ` Jonathan Cameron
2025-05-04 17:04 ` Jonathan Cameron
2025-05-05 14:24 ` Fabio Estevam
2025-05-05 15:16 ` Jonathan Cameron
2025-05-08 13:29 ` Fabio Estevam
2025-05-08 19:05 ` Jonathan Cameron
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=20250429183552.6a87e4cb@jic23-huawei \
--to=jic23@kernel.org \
--cc=festevam@denx.de \
--cc=festevam@gmail.com \
--cc=linux-iio@vger.kernel.org \
--cc=mazziesaccount@gmail.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