From: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
To: ChiYuan Huang <u0084500@gmail.com>
Cc: Liam Girdwood <lgirdwood@gmail.com>,
Mark Brown <broonie@kernel.org>, Rob Herring <robh+dt@kernel.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@linaro.org>,
ChiYuan Huang <cy_huang@richtek.com>,
linux-kernel@vger.kernel.org, devicetree@vger.kernel.org
Subject: Re: [PATCH v3 2/2] regulator: richtek,rt4801: parse GPIOs per regulator
Date: Mon, 25 Apr 2022 10:01:24 +0200 [thread overview]
Message-ID: <fe4b42c9-f747-145a-5fce-9be6fc3e19af@linaro.org> (raw)
In-Reply-To: <20220425075812.GA29439@cyhuang-hp-elitebook-840-g3.rt>
On 25/04/2022 09:58, ChiYuan Huang wrote:
>>
>> - priv->enable_gpios = devm_gpiod_get_array_optional(&i2c->dev, "enable", GPIOD_OUT_HIGH);
>> - if (IS_ERR(priv->enable_gpios)) {
>> - dev_err(&i2c->dev, "Failed to get gpios\n");
>> - return PTR_ERR(priv->enable_gpios);
>> + for (i = 0; i < DSV_OUT_MAX; i++) {
>> + priv->enable_gpios[i] = devm_gpiod_get_index_optional(&i2c->dev,
>> + "enable",
>> + i,
>> + GPIOD_OUT_HIGH);
>> + if (IS_ERR(priv->enable_gpios[i])) {
>> + dev_err(&i2c->dev, "Failed to get gpios\n");
>> + return PTR_ERR(priv->enable_gpios[i]);
>> + }
>> }
> You can directly removed all about 'enable-gpios' in probe phase.
> Just keep of_parse_cb to get per regulator 'enable' gpio.
We cannot, it would break the ABI and make the change backwards
incompatible.
Best regards,
Krzysztof
next prev parent reply other threads:[~2022-04-25 8:01 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-25 7:24 [PATCH v3 0/2] " Krzysztof Kozlowski
2022-04-25 7:24 ` [PATCH v3 1/2] regulator: dt-bindings: richtek,rt4801: use existing ena_gpiod feature Krzysztof Kozlowski
2022-04-25 7:24 ` [PATCH v3 2/2] regulator: richtek,rt4801: parse GPIOs per regulator Krzysztof Kozlowski
2022-04-25 7:58 ` ChiYuan Huang
2022-04-25 8:01 ` Krzysztof Kozlowski [this message]
2022-04-25 8:08 ` ChiYuan Huang
2022-04-25 8:50 ` ChiYuan Huang
2022-04-25 15:01 ` [PATCH v3 0/2] " Mark Brown
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=fe4b42c9-f747-145a-5fce-9be6fc3e19af@linaro.org \
--to=krzysztof.kozlowski@linaro.org \
--cc=broonie@kernel.org \
--cc=cy_huang@richtek.com \
--cc=devicetree@vger.kernel.org \
--cc=krzysztof.kozlowski+dt@linaro.org \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=robh+dt@kernel.org \
--cc=u0084500@gmail.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
all inboxes | Powered by JetHome®