From: Krzysztof Kozlowski <krzk@kernel.org>
To: Mark Brown <broonie@kernel.org>
Cc: ChiYuan Huang <u0084500@gmail.com>,
Rob Herring <robh+dt@kernel.org>,
Liam Girdwood <lgirdwood@gmail.com>,
cy_huang <cy_huang@richtek.com>,
gene_chen@richtek.com, lkml <linux-kernel@vger.kernel.org>,
"open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS"
<devicetree@vger.kernel.org>
Subject: Re: [PATCH 2/2] regulator: rt5759: Add support for Richtek RT5759 DCDC converter
Date: Fri, 25 Mar 2022 17:08:42 +0100 [thread overview]
Message-ID: <d2f220ae-c62c-a7f7-23cc-c33956c2eeaf@kernel.org> (raw)
In-Reply-To: <Yj3oXuijuZY1gG9X@sirena.org.uk>
On 25/03/2022 17:05, Mark Brown wrote:
> On Fri, Mar 25, 2022 at 04:55:25PM +0100, Krzysztof Kozlowski wrote:
>
>> You mention board, some of_device_get_match_data() so you talk about
>> runtime. maybe_unused is not about runtime. It is about build time.
>
>> The code you sent cannot have this structure unused. If you think
>> otherwise, please provide argument, but not about runtime (again). You
>> can for example build it without OF and see...
>
> If you use of_match_ptr() in the struct device (which is good practice,
> didn't check if this driver does it) then that causes the ID table to be
> unreferenced as of_match_ptr() compiles to NULL when !OF.
Yep, then the case is obvious, but the driver does not use it.
+static struct i2c_driver rt5759_driver = {
+ .driver = {
+ .name = "rt5759",
+ .of_match_table = rt5759_device_table,
Therefore the of_device_id cannot be unused, so __maybe_unused is not
correct. This can be fixed in two different ways, which we did not
discuss yet...
Best regards,
Krzysztof
next prev parent reply other threads:[~2022-03-25 16:08 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-25 1:06 [PATCH 0/2] Add Richtek RT5759 buck converter support cy_huang
2022-03-25 1:06 ` [PATCH 1/2] dt-bindings: regulator: Add binding for Richtek RT5759 DCDC converter cy_huang
2022-03-25 12:14 ` Krzysztof Kozlowski
2022-03-25 13:44 ` ChiYuan Huang
2022-03-25 14:46 ` Krzysztof Kozlowski
2022-03-25 14:53 ` ChiYuan Huang
2022-03-25 1:06 ` [PATCH 2/2] regulator: rt5759: Add support " cy_huang
2022-03-25 12:17 ` Krzysztof Kozlowski
2022-03-25 14:10 ` ChiYuan Huang
2022-03-25 14:47 ` Krzysztof Kozlowski
2022-03-25 14:59 ` ChiYuan Huang
2022-03-25 15:37 ` Krzysztof Kozlowski
2022-03-25 15:50 ` ChiYuan Huang
2022-03-25 15:55 ` Krzysztof Kozlowski
2022-03-25 16:05 ` Mark Brown
2022-03-25 16:08 ` Krzysztof Kozlowski [this message]
2022-03-26 0:58 ` ChiYuan Huang
2022-03-26 1:07 ` Mark Brown
2022-03-26 7:55 ` ChiYuan Huang
2022-03-26 8:13 ` Krzysztof Kozlowski
2022-03-26 8:24 ` ChiYuan Huang
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=d2f220ae-c62c-a7f7-23cc-c33956c2eeaf@kernel.org \
--to=krzk@kernel.org \
--cc=broonie@kernel.org \
--cc=cy_huang@richtek.com \
--cc=devicetree@vger.kernel.org \
--cc=gene_chen@richtek.com \
--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;
as well as URLs for NNTP newsgroup(s).