[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <49cd7b8e-d104-4136-bf7d-7eb45725c596@sirena.org.uk>
Date: Fri, 17 May 2024 15:42:31 +0100
From: Mark Brown <broonie@...nel.org>
To: Alvin Šipraga <alvin@...s.dk>
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
"Rafael J. Wysocki" <rafael@...nel.org>,
Rob Herring <robh@...nel.org>,
Krzysztof Kozlowski <krzk+dt@...nel.org>,
Conor Dooley <conor+dt@...nel.org>,
Linus Walleij <linus.walleij@...aro.org>,
Bartosz Golaszewski <brgl@...ev.pl>,
Liam Girdwood <lgirdwood@...il.com>,
Jaroslav Kysela <perex@...ex.cz>, Takashi Iwai <tiwai@...e.com>,
Michael Turquette <mturquette@...libre.com>,
Stephen Boyd <sboyd@...nel.org>, Andi Shyti <andi.shyti@...nel.org>,
Saravana Kannan <saravanak@...gle.com>,
Emil Svendsen <emas@...g-olufsen.dk>, linux-kernel@...r.kernel.org,
devicetree@...r.kernel.org, linux-gpio@...r.kernel.org,
linux-sound@...r.kernel.org, linux-clk@...r.kernel.org,
linux-i2c@...r.kernel.org,
Alvin Šipraga <alsi@...g-olufsen.dk>
Subject: Re: [PATCH 02/13] regmap: add A2B support
On Fri, May 17, 2024 at 02:58:00PM +0200, Alvin Šipraga wrote:
> +static int regmap_a2b_write(void *context, const void *data, size_t count)
> +{
> + for (i = 0; i < count - 1; i++) {
> + ret = bus->ops->write(bus, node, reg + i, d[i + 1]);
> + if (ret)
> + return ret;
> + }
Just force single_read and single_write (looks like you'll need to add
the hook for the bus there).
> +struct regmap *__devm_regmap_init_a2b_node(struct a2b_node *node,
> + const struct regmap_config *config,
> + struct lock_class_key *lock_key,
> + const char *lock_name)
> +{
> + return __devm_regmap_init(&node->dev, ®map_a2b, node, config,
> + lock_key, lock_name);
> +}
> +EXPORT_SYMBOL_GPL(__devm_regmap_init_a2b_node);
Should there be validation of val_bits?
Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)
Powered by blists - more mailing lists