From: Jonathan Cameron <jic23@kernel.org>
To: Andy Shevchenko <andriy.shevchenko@intel.com>
Cc: "Kim Seer Paller" <kimseer.paller@analog.com>,
"David Lechner" <dlechner@baylibre.com>,
"Nuno Sá" <nuno.sa@analog.com>,
"Andy Shevchenko" <andy@kernel.org>,
"Michael Hennerich" <Michael.Hennerich@analog.com>,
"Rob Herring" <robh@kernel.org>,
"Krzysztof Kozlowski" <krzk+dt@kernel.org>,
"Conor Dooley" <conor+dt@kernel.org>,
linux-iio@vger.kernel.org, linux-kernel@vger.kernel.org,
linux@analog.com, devicetree@vger.kernel.org
Subject: Re: [PATCH v3 1/4] iio: dac: ad3530r: Refactor setup to table-driven register bank approach
Date: Mon, 29 Jun 2026 19:18:34 +0100 [thread overview]
Message-ID: <20260629191834.38a2b8df@jic23-huawei> (raw)
In-Reply-To: <akJ5xoMvLWwNvpVN@ashevche-desk.local>
On Mon, 29 Jun 2026 16:57:26 +0300
Andy Shevchenko <andriy.shevchenko@intel.com> wrote:
> On Mon, Jun 29, 2026 at 04:31:04PM +0800, Kim Seer Paller wrote:
> > Replace direct register calls in ad3530r_setup() with per-chip register
> > address arrays and bank helpers (ad3530r_set_reg_bank_bits,
> > ad3530r_write_reg_banks). Convert sw_ldac_trig_reg from a static
> ad3530r_set_reg_bank_bits(),
> ad3530r_write_reg_banks().
>
> > Convert sw_ldac_trig_reg from a static
> > register address to a function pointer for per-bank LDAC trigger
> > register selection. Switch spi_device_id to named initializers.
>
> Split this patch to do one thing per a change.
>
Perhaps more relevant here is remember to update the changelog.
It doesn't do that last thing as Uwe already dealt with it.
> ...
>
> > +static int ad3530r_set_reg_bank_bits(const struct ad3530r_state *st,
> > + const unsigned int *regs,
> > + unsigned int num_regs,
> > + unsigned int mask)
> > +{
> > + int ret;
> > +
> > + for (unsigned int i = 0; i < num_regs; i++) {
> > + ret = regmap_update_bits(st->regmap, regs[i], mask, mask);
>
> _set_bits()
>
> > + if (ret)
> > + return ret;
> > + }
> > +
> > + return 0;
> > +}
>
next prev parent reply other threads:[~2026-06-29 18:18 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-29 8:31 [PATCH v3 0/4] Add support for AD3532R/AD3532 Kim Seer Paller
2026-06-29 8:31 ` [PATCH v3 1/4] iio: dac: ad3530r: Refactor setup to table-driven register bank approach Kim Seer Paller
2026-06-29 9:42 ` sashiko-bot
2026-06-29 13:57 ` Andy Shevchenko
2026-06-29 18:18 ` Jonathan Cameron [this message]
2026-06-29 8:31 ` [PATCH v3 2/4] iio: ABI: add DAC 10kohm_to_gnd powerdown mode Kim Seer Paller
2026-06-29 9:54 ` sashiko-bot
2026-06-29 8:31 ` [PATCH v3 3/4] dt-bindings: iio: dac: add support for AD3532R/AD3532 Kim Seer Paller
2026-06-29 10:03 ` sashiko-bot
2026-06-29 8:31 ` [PATCH v3 4/4] iio: dac: ad3530r: Add " Kim Seer Paller
2026-06-29 10:15 ` sashiko-bot
2026-06-29 14:34 ` Andy Shevchenko
2026-06-29 18:26 ` 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=20260629191834.38a2b8df@jic23-huawei \
--to=jic23@kernel.org \
--cc=Michael.Hennerich@analog.com \
--cc=andriy.shevchenko@intel.com \
--cc=andy@kernel.org \
--cc=conor+dt@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=dlechner@baylibre.com \
--cc=kimseer.paller@analog.com \
--cc=krzk+dt@kernel.org \
--cc=linux-iio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@analog.com \
--cc=nuno.sa@analog.com \
--cc=robh@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