All of lore.kernel.org
 help / color / mirror / Atom feed
From: Krzysztof Kozlowski <krzk@kernel.org>
To: linux-kernel@vger.kernel.org, Lee Jones <lee.jones@linaro.org>
Cc: Krzysztof Kozlowski <krzk@kernel.org>, Chen-Yu Tsai <wens@csie.org>
Subject: [PATCH 15/16] mfd: axp20x: skip of_device_id table when !CONFIG_OF
Date: Fri, 20 Nov 2020 17:21:32 +0100	[thread overview]
Message-ID: <20201120162133.472938-15-krzk@kernel.org> (raw)
In-Reply-To: <20201120162133.472938-1-krzk@kernel.org>

The driver can match either via ACPI or OF.  Its of_device_id table is
referenced via of_match_ptr() so it will be unused for !CONFIG_OF
builds:

  drivers/mfd/axp20x-i2c.c:60:34: warning: ‘axp20x_i2c_of_match’ defined but not used [-Wunused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
---
 drivers/mfd/axp20x-i2c.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/mfd/axp20x-i2c.c b/drivers/mfd/axp20x-i2c.c
index 068e9c083f13..2cfde81f5fbf 100644
--- a/drivers/mfd/axp20x-i2c.c
+++ b/drivers/mfd/axp20x-i2c.c
@@ -57,6 +57,7 @@ static int axp20x_i2c_remove(struct i2c_client *i2c)
 	return axp20x_device_remove(axp20x);
 }
 
+#ifdef CONFIG_OF
 static const struct of_device_id axp20x_i2c_of_match[] = {
 	{ .compatible = "x-powers,axp152", .data = (void *)AXP152_ID },
 	{ .compatible = "x-powers,axp202", .data = (void *)AXP202_ID },
@@ -68,6 +69,7 @@ static const struct of_device_id axp20x_i2c_of_match[] = {
 	{ },
 };
 MODULE_DEVICE_TABLE(of, axp20x_i2c_of_match);
+#endif
 
 static const struct i2c_device_id axp20x_i2c_id[] = {
 	{ "axp152", 0 },
-- 
2.25.1


  parent reply	other threads:[~2020-11-20 16:22 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-20 16:21 [PATCH 01/16] mfd: bcm590xx: drop of_match_ptr from of_device_id table Krzysztof Kozlowski
2020-11-20 16:21 ` [PATCH 02/16] mfd: da9055: " Krzysztof Kozlowski
2020-11-20 16:21 ` [PATCH 03/16] mfd: da9062: " Krzysztof Kozlowski
2020-11-20 16:21 ` [PATCH 04/16] mfd: da9063: " Krzysztof Kozlowski
2020-11-20 16:21 ` [PATCH 05/16] mfd: da9150: " Krzysztof Kozlowski
2020-11-20 16:21 ` [PATCH 06/16] mfd: ene-kb3930: " Krzysztof Kozlowski
2020-11-20 16:21 ` [PATCH 07/16] mfd: fsl-imx25: " Krzysztof Kozlowski
2020-11-20 16:21   ` Krzysztof Kozlowski
2020-11-20 16:21 ` [PATCH 08/16] mfd: max77650: " Krzysztof Kozlowski
2020-11-20 16:21 ` [PATCH 09/16] mfd: max77686: " Krzysztof Kozlowski
2020-11-23  5:12   ` Chanwoo Choi
2020-11-20 16:21 ` [PATCH 10/16] mfd: mt6397: " Krzysztof Kozlowski
2020-11-20 16:21   ` Krzysztof Kozlowski
2020-11-20 16:21   ` Krzysztof Kozlowski
2020-11-20 16:21 ` [PATCH 11/16] mfd: rt5033: " Krzysztof Kozlowski
2020-11-20 16:21 ` [PATCH 12/16] mfd: stmfx: " Krzysztof Kozlowski
2020-11-20 16:21   ` Krzysztof Kozlowski
2020-11-20 16:21 ` [PATCH 13/16] mfd: sun4i: " Krzysztof Kozlowski
2020-11-20 16:21   ` Krzysztof Kozlowski
2020-11-20 16:21 ` [PATCH 14/16] mfd: wm8994: " Krzysztof Kozlowski
2020-11-20 17:02   ` Charles Keepax
2020-11-20 16:21 ` Krzysztof Kozlowski [this message]
2020-11-20 16:41   ` [PATCH 15/16] mfd: axp20x: skip of_device_id table when !CONFIG_OF Chen-Yu Tsai
2020-11-20 16:21 ` [PATCH 16/16] mfd: twl6030: mark of_device_id table as maybe unused Krzysztof Kozlowski
2020-11-27  8:06 ` [PATCH 01/16] mfd: bcm590xx: drop of_match_ptr from of_device_id table Lee Jones
2020-11-27  8:17   ` Krzysztof Kozlowski
2020-11-27  9:17     ` Lee Jones
2020-11-27 11:37       ` Miguel Ojeda
2020-11-27 13:20         ` Lee Jones

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=20201120162133.472938-15-krzk@kernel.org \
    --to=krzk@kernel.org \
    --cc=lee.jones@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=wens@csie.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.