From: Jonathan Cameron <jic23@kernel.org>
To: David Lechner <dlechner@baylibre.com>
Cc: "Matti Vaittinen" <mazziesaccount@gmail.com>,
"Matti Vaittinen" <matti.vaittinen@fi.rohmeurope.com>,
"Nuno Sá" <nuno.sa@analog.com>,
"Andy Shevchenko" <andy@kernel.org>,
"Rob Herring" <robh@kernel.org>,
"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
"Conor Dooley" <conor+dt@kernel.org>,
"David Heidelberg" <david@ixit.cz>,
linux-iio@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org,
"Sukrut Bellary" <sbellary@baylibre.com>,
"Lothar Rubusch" <l.rubusch@gmail.com>
Subject: Re: [PATCH 2/3] iio: adc: adc128s052: Simplify matching chip_data
Date: Sat, 16 Aug 2025 13:32:11 +0100 [thread overview]
Message-ID: <20250816133211.39a9a0ac@jic23-huawei> (raw)
In-Reply-To: <20250816132823.0d987b20@jic23-huawei>
On Sat, 16 Aug 2025 13:28:23 +0100
Jonathan Cameron <jic23@kernel.org> wrote:
> On Thu, 14 Aug 2025 09:53:21 -0500
> David Lechner <dlechner@baylibre.com> wrote:
>
> > On 8/14/25 3:35 AM, Matti Vaittinen wrote:
> > > The adc128s052 driver supports a few different ICs. IC specific
> > > configuration data is stored in an array. IC data, residing in a
> > > specific point of the array, is pointed from the SPI device match data.
> > >
> > > There is no need to have the chip config data structures in an array
> > > and splitting them out of an array has at least following benefits:
> > >
> > > - Chip-specific structures can be named after the chips they support.
> > > This makes referring them a tad cleaner, compared to using a generic
> > > array name with a numerical index.
> > >
> > > - Avoid all potential 'out of bounds' errors which can result if the
> > > array is changed.
> > >
> > > Split the chip configuration data array to individual structures.
> > >
> > > Signed-off-by: Matti Vaittinen <mazziesaccount@gmail.com>
> > >
> > > ---
> > Reviewed-by: David Lechner <dlechner@baylibre.com>
> >
> Any racing series get to rebase on top of this.
>
> Applied this patch as it is good in it's own right.
Dropped again given rename discussion on patch 3.
>
> Thanks,
>
> Jonathan
>
next prev parent reply other threads:[~2025-08-16 12:32 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-08-14 8:34 [PATCH 0/3] Support ROHM BD7910[0,1,2,3] Matti Vaittinen
2025-08-14 8:35 ` [PATCH 1/3] dt-bindings: iio: adc: Add BD7910[0,1,2,3] Matti Vaittinen
2025-08-14 9:57 ` Matti Vaittinen
2025-08-14 14:51 ` David Lechner
2025-08-15 5:00 ` Matti Vaittinen
2025-08-14 8:35 ` [PATCH 2/3] iio: adc: adc128s052: Simplify matching chip_data Matti Vaittinen
2025-08-14 14:53 ` David Lechner
2025-08-16 12:28 ` Jonathan Cameron
2025-08-16 12:32 ` Jonathan Cameron [this message]
2025-08-14 8:35 ` [PATCH 3/3] iio: adc: adc128s052: Support ROHM BD7910[0,1,2,3] Matti Vaittinen
2025-08-14 15:01 ` David Lechner
2025-08-15 5:23 ` Matti Vaittinen
2025-08-15 14:16 ` David Lechner
2025-08-15 14:17 ` David Lechner
2025-08-16 12:31 ` 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=20250816133211.39a9a0ac@jic23-huawei \
--to=jic23@kernel.org \
--cc=andy@kernel.org \
--cc=conor+dt@kernel.org \
--cc=david@ixit.cz \
--cc=devicetree@vger.kernel.org \
--cc=dlechner@baylibre.com \
--cc=krzk+dt@kernel.org \
--cc=l.rubusch@gmail.com \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=matti.vaittinen@fi.rohmeurope.com \
--cc=mazziesaccount@gmail.com \
--cc=nuno.sa@analog.com \
--cc=robh@kernel.org \
--cc=sbellary@baylibre.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