All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 1/9] regulator: lp872x: Mark OF related data as maybe unused
@ 2023-03-10 21:45 ` Krzysztof Kozlowski
  0 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can be compile tested with !CONFIG_OF making certain data
unused:

  drivers/regulator/lp872x.c:931:34: error: ‘lp872x_dt_ids’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/lp872x.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/lp872x.c b/drivers/regulator/lp872x.c
index c576894c3d52..c3a6e77db4d0 100644
--- a/drivers/regulator/lp872x.c
+++ b/drivers/regulator/lp872x.c
@@ -928,7 +928,7 @@ static int lp872x_probe(struct i2c_client *cl)
 	return lp872x_regulator_register(lp);
 }
 
-static const struct of_device_id lp872x_dt_ids[] = {
+static const struct of_device_id lp872x_dt_ids[] __maybe_unused = {
 	{ .compatible = "ti,lp8720", },
 	{ .compatible = "ti,lp8725", },
 	{ }
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 1/9] regulator: lp872x: Mark OF related data as maybe unused
@ 2023-03-10 21:45 ` Krzysztof Kozlowski
  0 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can be compile tested with !CONFIG_OF making certain data
unused:

  drivers/regulator/lp872x.c:931:34: error: ‘lp872x_dt_ids’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/lp872x.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/lp872x.c b/drivers/regulator/lp872x.c
index c576894c3d52..c3a6e77db4d0 100644
--- a/drivers/regulator/lp872x.c
+++ b/drivers/regulator/lp872x.c
@@ -928,7 +928,7 @@ static int lp872x_probe(struct i2c_client *cl)
 	return lp872x_regulator_register(lp);
 }
 
-static const struct of_device_id lp872x_dt_ids[] = {
+static const struct of_device_id lp872x_dt_ids[] __maybe_unused = {
 	{ .compatible = "ti,lp8720", },
 	{ .compatible = "ti,lp8725", },
 	{ }
-- 
2.34.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 2/9] regulator: max20086: Mark OF related data as maybe unused
  2023-03-10 21:45 ` Krzysztof Kozlowski
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can be compile tested with !CONFIG_OF making certain data
unused:

  drivers/regulator/max20086-regulator.c:289:34: error: ‘max20086_dt_ids’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/max20086-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/max20086-regulator.c b/drivers/regulator/max20086-regulator.c
index b8bf76c170fe..c98a72f43935 100644
--- a/drivers/regulator/max20086-regulator.c
+++ b/drivers/regulator/max20086-regulator.c
@@ -286,7 +286,7 @@ static const struct i2c_device_id max20086_i2c_id[] = {
 
 MODULE_DEVICE_TABLE(i2c, max20086_i2c_id);
 
-static const struct of_device_id max20086_dt_ids[] = {
+static const struct of_device_id max20086_dt_ids[] __maybe_unused = {
 	{
 		.compatible = "maxim,max20086",
 		.data = &(const struct max20086_chip_info) {
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 2/9] regulator: max20086: Mark OF related data as maybe unused
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can be compile tested with !CONFIG_OF making certain data
unused:

  drivers/regulator/max20086-regulator.c:289:34: error: ‘max20086_dt_ids’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/max20086-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/max20086-regulator.c b/drivers/regulator/max20086-regulator.c
index b8bf76c170fe..c98a72f43935 100644
--- a/drivers/regulator/max20086-regulator.c
+++ b/drivers/regulator/max20086-regulator.c
@@ -286,7 +286,7 @@ static const struct i2c_device_id max20086_i2c_id[] = {
 
 MODULE_DEVICE_TABLE(i2c, max20086_i2c_id);
 
-static const struct of_device_id max20086_dt_ids[] = {
+static const struct of_device_id max20086_dt_ids[] __maybe_unused = {
 	{
 		.compatible = "maxim,max20086",
 		.data = &(const struct max20086_chip_info) {
-- 
2.34.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 3/9] regulator: mp8859: Mark OF related data as maybe unused
  2023-03-10 21:45 ` Krzysztof Kozlowski
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can be compile tested with !CONFIG_OF making certain data
unused:

  drivers/regulator/mp8859.c:132:34: error: ‘mp8859_dt_id’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/mp8859.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/mp8859.c b/drivers/regulator/mp8859.c
index f2300714d5a9..f893dadf2abb 100644
--- a/drivers/regulator/mp8859.c
+++ b/drivers/regulator/mp8859.c
@@ -129,7 +129,7 @@ static int mp8859_i2c_probe(struct i2c_client *i2c)
 	return 0;
 }
 
-static const struct of_device_id mp8859_dt_id[] = {
+static const struct of_device_id mp8859_dt_id[] __maybe_unused = {
 	{.compatible =  "mps,mp8859"},
 	{},
 };
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 3/9] regulator: mp8859: Mark OF related data as maybe unused
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can be compile tested with !CONFIG_OF making certain data
unused:

  drivers/regulator/mp8859.c:132:34: error: ‘mp8859_dt_id’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/mp8859.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/mp8859.c b/drivers/regulator/mp8859.c
index f2300714d5a9..f893dadf2abb 100644
--- a/drivers/regulator/mp8859.c
+++ b/drivers/regulator/mp8859.c
@@ -129,7 +129,7 @@ static int mp8859_i2c_probe(struct i2c_client *i2c)
 	return 0;
 }
 
-static const struct of_device_id mp8859_dt_id[] = {
+static const struct of_device_id mp8859_dt_id[] __maybe_unused = {
 	{.compatible =  "mps,mp8859"},
 	{},
 };
-- 
2.34.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 4/9] regulator: mt6397-regulator: Mark OF related data as maybe unused
  2023-03-10 21:45 ` Krzysztof Kozlowski
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can be compile tested with !CONFIG_OF making certain data
unused:

  drivers/regulator/mt6397-regulator.c:400:34: error: ‘mt6397_of_match’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/mt6397-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/mt6397-regulator.c b/drivers/regulator/mt6397-regulator.c
index b9bf7ade1f8a..526acc8fbe80 100644
--- a/drivers/regulator/mt6397-regulator.c
+++ b/drivers/regulator/mt6397-regulator.c
@@ -397,7 +397,7 @@ static const struct platform_device_id mt6397_platform_ids[] = {
 };
 MODULE_DEVICE_TABLE(platform, mt6397_platform_ids);
 
-static const struct of_device_id mt6397_of_match[] = {
+static const struct of_device_id mt6397_of_match[] __maybe_unused = {
 	{ .compatible = "mediatek,mt6397-regulator", },
 	{ /* sentinel */ },
 };
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 4/9] regulator: mt6397-regulator: Mark OF related data as maybe unused
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can be compile tested with !CONFIG_OF making certain data
unused:

  drivers/regulator/mt6397-regulator.c:400:34: error: ‘mt6397_of_match’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/mt6397-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/mt6397-regulator.c b/drivers/regulator/mt6397-regulator.c
index b9bf7ade1f8a..526acc8fbe80 100644
--- a/drivers/regulator/mt6397-regulator.c
+++ b/drivers/regulator/mt6397-regulator.c
@@ -397,7 +397,7 @@ static const struct platform_device_id mt6397_platform_ids[] = {
 };
 MODULE_DEVICE_TABLE(platform, mt6397_platform_ids);
 
-static const struct of_device_id mt6397_of_match[] = {
+static const struct of_device_id mt6397_of_match[] __maybe_unused = {
 	{ .compatible = "mediatek,mt6397-regulator", },
 	{ /* sentinel */ },
 };
-- 
2.34.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 5/9] regulator: qcom_rpm: Drop of_match_ptr for ID table
  2023-03-10 21:45 ` Krzysztof Kozlowski
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver is specific to ARCH_QCOM which depends on OF thus the driver
is OF-only.  Its of_device_id table is built unconditionally, thus
of_match_ptr() for ID table does not make sense.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/qcom_rpm-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/qcom_rpm-regulator.c b/drivers/regulator/qcom_rpm-regulator.c
index 3c41b71a1f52..602526669648 100644
--- a/drivers/regulator/qcom_rpm-regulator.c
+++ b/drivers/regulator/qcom_rpm-regulator.c
@@ -991,7 +991,7 @@ static struct platform_driver rpm_reg_driver = {
 	.probe          = rpm_reg_probe,
 	.driver  = {
 		.name  = "qcom_rpm_reg",
-		.of_match_table = of_match_ptr(rpm_of_match),
+		.of_match_table = rpm_of_match,
 	},
 };
 
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 5/9] regulator: qcom_rpm: Drop of_match_ptr for ID table
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver is specific to ARCH_QCOM which depends on OF thus the driver
is OF-only.  Its of_device_id table is built unconditionally, thus
of_match_ptr() for ID table does not make sense.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/qcom_rpm-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/qcom_rpm-regulator.c b/drivers/regulator/qcom_rpm-regulator.c
index 3c41b71a1f52..602526669648 100644
--- a/drivers/regulator/qcom_rpm-regulator.c
+++ b/drivers/regulator/qcom_rpm-regulator.c
@@ -991,7 +991,7 @@ static struct platform_driver rpm_reg_driver = {
 	.probe          = rpm_reg_probe,
 	.driver  = {
 		.name  = "qcom_rpm_reg",
-		.of_match_table = of_match_ptr(rpm_of_match),
+		.of_match_table = rpm_of_match,
 	},
 };
 
-- 
2.34.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 6/9] regulator: pbias: Drop of_match_ptr for ID table
  2023-03-10 21:45 ` Krzysztof Kozlowski
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can match only via the DT table so the table should be always
used and the of_match_ptr does not have any sense (this also allows ACPI
matching via PRP0001, even though it is not relevant here).

  drivers/regulator/pbias-regulator.c:137:34: error: ‘pbias_of_match’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/pbias-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/pbias-regulator.c b/drivers/regulator/pbias-regulator.c
index 4eccf12f39de..4ce06072f3b5 100644
--- a/drivers/regulator/pbias-regulator.c
+++ b/drivers/regulator/pbias-regulator.c
@@ -231,7 +231,7 @@ static struct platform_driver pbias_regulator_driver = {
 	.probe		= pbias_regulator_probe,
 	.driver		= {
 		.name		= "pbias-regulator",
-		.of_match_table = of_match_ptr(pbias_of_match),
+		.of_match_table = pbias_of_match,
 	},
 };
 
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 6/9] regulator: pbias: Drop of_match_ptr for ID table
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can match only via the DT table so the table should be always
used and the of_match_ptr does not have any sense (this also allows ACPI
matching via PRP0001, even though it is not relevant here).

  drivers/regulator/pbias-regulator.c:137:34: error: ‘pbias_of_match’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/pbias-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/pbias-regulator.c b/drivers/regulator/pbias-regulator.c
index 4eccf12f39de..4ce06072f3b5 100644
--- a/drivers/regulator/pbias-regulator.c
+++ b/drivers/regulator/pbias-regulator.c
@@ -231,7 +231,7 @@ static struct platform_driver pbias_regulator_driver = {
 	.probe		= pbias_regulator_probe,
 	.driver		= {
 		.name		= "pbias-regulator",
-		.of_match_table = of_match_ptr(pbias_of_match),
+		.of_match_table = pbias_of_match,
 	},
 };
 
-- 
2.34.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 7/9] regulator: rpi-panel-attiny: Drop of_match_ptr for ID table
  2023-03-10 21:45 ` Krzysztof Kozlowski
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can match only via the DT table so the table should be always
used and the of_match_ptr does not have any sense (this also allows ACPI
matching via PRP0001, even though it is not relevant here).

  drivers/regulator/rpi-panel-attiny-regulator.c:390:34: error: ‘attiny_dt_ids’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/rpi-panel-attiny-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/rpi-panel-attiny-regulator.c b/drivers/regulator/rpi-panel-attiny-regulator.c
index 34514976475e..3953fc1f389f 100644
--- a/drivers/regulator/rpi-panel-attiny-regulator.c
+++ b/drivers/regulator/rpi-panel-attiny-regulator.c
@@ -396,7 +396,7 @@ MODULE_DEVICE_TABLE(of, attiny_dt_ids);
 static struct i2c_driver attiny_regulator_driver = {
 	.driver = {
 		.name = "rpi_touchscreen_attiny",
-		.of_match_table = of_match_ptr(attiny_dt_ids),
+		.of_match_table = attiny_dt_ids,
 	},
 	.probe_new = attiny_i2c_probe,
 	.remove	= attiny_i2c_remove,
-- 
2.34.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 7/9] regulator: rpi-panel-attiny: Drop of_match_ptr for ID table
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can match only via the DT table so the table should be always
used and the of_match_ptr does not have any sense (this also allows ACPI
matching via PRP0001, even though it is not relevant here).

  drivers/regulator/rpi-panel-attiny-regulator.c:390:34: error: ‘attiny_dt_ids’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/rpi-panel-attiny-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/rpi-panel-attiny-regulator.c b/drivers/regulator/rpi-panel-attiny-regulator.c
index 34514976475e..3953fc1f389f 100644
--- a/drivers/regulator/rpi-panel-attiny-regulator.c
+++ b/drivers/regulator/rpi-panel-attiny-regulator.c
@@ -396,7 +396,7 @@ MODULE_DEVICE_TABLE(of, attiny_dt_ids);
 static struct i2c_driver attiny_regulator_driver = {
 	.driver = {
 		.name = "rpi_touchscreen_attiny",
-		.of_match_table = of_match_ptr(attiny_dt_ids),
+		.of_match_table = attiny_dt_ids,
 	},
 	.probe_new = attiny_i2c_probe,
 	.remove	= attiny_i2c_remove,
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 8/9] regulator: twl: Drop of_match_ptr for ID table
  2023-03-10 21:45 ` Krzysztof Kozlowski
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can match only via the DT table so the table should be always
used and the of_match_ptr does not have any sense (this also allows ACPI
matching via PRP0001, even though it is not relevant here).

  drivers/regulator/twl-regulator.c:553:34: error: ‘twl_of_match’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/twl-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/twl-regulator.c b/drivers/regulator/twl-regulator.c
index e2a20d512152..fe80a5e20bd0 100644
--- a/drivers/regulator/twl-regulator.c
+++ b/drivers/regulator/twl-regulator.c
@@ -656,7 +656,7 @@ static struct platform_driver twlreg_driver = {
 	 */
 	.driver  = {
 		.name  = "twl4030_reg",
-		.of_match_table = of_match_ptr(twl_of_match),
+		.of_match_table = twl_of_match,
 	},
 };
 
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 8/9] regulator: twl: Drop of_match_ptr for ID table
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can match only via the DT table so the table should be always
used and the of_match_ptr does not have any sense (this also allows ACPI
matching via PRP0001, even though it is not relevant here).

  drivers/regulator/twl-regulator.c:553:34: error: ‘twl_of_match’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/twl-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/twl-regulator.c b/drivers/regulator/twl-regulator.c
index e2a20d512152..fe80a5e20bd0 100644
--- a/drivers/regulator/twl-regulator.c
+++ b/drivers/regulator/twl-regulator.c
@@ -656,7 +656,7 @@ static struct platform_driver twlreg_driver = {
 	 */
 	.driver  = {
 		.name  = "twl4030_reg",
-		.of_match_table = of_match_ptr(twl_of_match),
+		.of_match_table = twl_of_match,
 	},
 };
 
-- 
2.34.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 9/9] regulator: twl6030: Drop of_match_ptr for ID table
  2023-03-10 21:45 ` Krzysztof Kozlowski
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can match only via the DT table so the table should be always
used and the of_match_ptr does not have any sense (this also allows ACPI
matching via PRP0001, even though it is not relevant here).

  drivers/regulator/twl6030-regulator.c:646:34: error: ‘twl_of_match’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/twl6030-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/twl6030-regulator.c b/drivers/regulator/twl6030-regulator.c
index f3856750944f..be798f3c129e 100644
--- a/drivers/regulator/twl6030-regulator.c
+++ b/drivers/regulator/twl6030-regulator.c
@@ -765,7 +765,7 @@ static struct platform_driver twlreg_driver = {
 	 */
 	.driver  = {
 		.name  = "twl6030_reg",
-		.of_match_table = of_match_ptr(twl_of_match),
+		.of_match_table = twl_of_match,
 	},
 };
 
-- 
2.34.1


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 9/9] regulator: twl6030: Drop of_match_ptr for ID table
@ 2023-03-10 21:45   ` Krzysztof Kozlowski
  0 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-10 21:45 UTC (permalink / raw)
  To: Liam Girdwood, Mark Brown, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm
  Cc: Krzysztof Kozlowski

The driver can match only via the DT table so the table should be always
used and the of_match_ptr does not have any sense (this also allows ACPI
matching via PRP0001, even though it is not relevant here).

  drivers/regulator/twl6030-regulator.c:646:34: error: ‘twl_of_match’ defined but not used [-Werror=unused-const-variable=]

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/regulator/twl6030-regulator.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/regulator/twl6030-regulator.c b/drivers/regulator/twl6030-regulator.c
index f3856750944f..be798f3c129e 100644
--- a/drivers/regulator/twl6030-regulator.c
+++ b/drivers/regulator/twl6030-regulator.c
@@ -765,7 +765,7 @@ static struct platform_driver twlreg_driver = {
 	 */
 	.driver  = {
 		.name  = "twl6030_reg",
-		.of_match_table = of_match_ptr(twl_of_match),
+		.of_match_table = twl_of_match,
 	},
 };
 
-- 
2.34.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* Re: [PATCH 2/9] regulator: max20086: Mark OF related data as maybe unused
  2023-03-10 21:45   ` Krzysztof Kozlowski
@ 2023-03-12  9:42     ` Laurent Pinchart
  -1 siblings, 0 replies; 30+ messages in thread
From: Laurent Pinchart @ 2023-03-12  9:42 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Liam Girdwood, Mark Brown, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm

Hi Krzysztof,

Thank you for the patch.

On Fri, Mar 10, 2023 at 10:45:46PM +0100, Krzysztof Kozlowski wrote:
> The driver can be compile tested with !CONFIG_OF making certain data
> unused:
> 
>   drivers/regulator/max20086-regulator.c:289:34: error: ‘max20086_dt_ids’ defined but not used [-Werror=unused-const-variable=]
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
>  drivers/regulator/max20086-regulator.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/regulator/max20086-regulator.c b/drivers/regulator/max20086-regulator.c
> index b8bf76c170fe..c98a72f43935 100644
> --- a/drivers/regulator/max20086-regulator.c
> +++ b/drivers/regulator/max20086-regulator.c
> @@ -286,7 +286,7 @@ static const struct i2c_device_id max20086_i2c_id[] = {
>  
>  MODULE_DEVICE_TABLE(i2c, max20086_i2c_id);
>  
> -static const struct of_device_id max20086_dt_ids[] = {
> +static const struct of_device_id max20086_dt_ids[] __maybe_unused = {

The following change would also work, as the of_match_table field of
struct device_driver isn't conditioned by CONFIG_OF:

diff --git a/drivers/regulator/max20086-regulator.c b/drivers/regulator/max20086-regulator.c
index b8bf76c170fe..ad92f84b4abb 100644
--- a/drivers/regulator/max20086-regulator.c
+++ b/drivers/regulator/max20086-regulator.c
@@ -320,7 +320,7 @@ MODULE_DEVICE_TABLE(of, max20086_dt_ids);
 static struct i2c_driver max20086_regulator_driver = {
 	.driver = {
 		.name = "max20086",
-		.of_match_table = of_match_ptr(max20086_dt_ids),
+		.of_match_table = max20086_dt_ids,
 	},
 	.probe_new = max20086_i2c_probe,
 	.id_table = max20086_i2c_id,

Your patch should reduce the module size without any real drawback as
far as I can see, so that's probably best. I'm fine with either
approach, so

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

>  	{
>  		.compatible = "maxim,max20086",
>  		.data = &(const struct max20086_chip_info) {

-- 
Regards,

Laurent Pinchart

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* Re: [PATCH 2/9] regulator: max20086: Mark OF related data as maybe unused
@ 2023-03-12  9:42     ` Laurent Pinchart
  0 siblings, 0 replies; 30+ messages in thread
From: Laurent Pinchart @ 2023-03-12  9:42 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Liam Girdwood, Mark Brown, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm

Hi Krzysztof,

Thank you for the patch.

On Fri, Mar 10, 2023 at 10:45:46PM +0100, Krzysztof Kozlowski wrote:
> The driver can be compile tested with !CONFIG_OF making certain data
> unused:
> 
>   drivers/regulator/max20086-regulator.c:289:34: error: ‘max20086_dt_ids’ defined but not used [-Werror=unused-const-variable=]
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
>  drivers/regulator/max20086-regulator.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/regulator/max20086-regulator.c b/drivers/regulator/max20086-regulator.c
> index b8bf76c170fe..c98a72f43935 100644
> --- a/drivers/regulator/max20086-regulator.c
> +++ b/drivers/regulator/max20086-regulator.c
> @@ -286,7 +286,7 @@ static const struct i2c_device_id max20086_i2c_id[] = {
>  
>  MODULE_DEVICE_TABLE(i2c, max20086_i2c_id);
>  
> -static const struct of_device_id max20086_dt_ids[] = {
> +static const struct of_device_id max20086_dt_ids[] __maybe_unused = {

The following change would also work, as the of_match_table field of
struct device_driver isn't conditioned by CONFIG_OF:

diff --git a/drivers/regulator/max20086-regulator.c b/drivers/regulator/max20086-regulator.c
index b8bf76c170fe..ad92f84b4abb 100644
--- a/drivers/regulator/max20086-regulator.c
+++ b/drivers/regulator/max20086-regulator.c
@@ -320,7 +320,7 @@ MODULE_DEVICE_TABLE(of, max20086_dt_ids);
 static struct i2c_driver max20086_regulator_driver = {
 	.driver = {
 		.name = "max20086",
-		.of_match_table = of_match_ptr(max20086_dt_ids),
+		.of_match_table = max20086_dt_ids,
 	},
 	.probe_new = max20086_i2c_probe,
 	.id_table = max20086_i2c_id,

Your patch should reduce the module size without any real drawback as
far as I can see, so that's probably best. I'm fine with either
approach, so

Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

>  	{
>  		.compatible = "maxim,max20086",
>  		.data = &(const struct max20086_chip_info) {

-- 
Regards,

Laurent Pinchart

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply related	[flat|nested] 30+ messages in thread

* Re: [PATCH 2/9] regulator: max20086: Mark OF related data as maybe unused
  2023-03-12  9:42     ` Laurent Pinchart
@ 2023-03-12 10:03       ` Krzysztof Kozlowski
  -1 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-12 10:03 UTC (permalink / raw)
  To: Laurent Pinchart
  Cc: Liam Girdwood, Mark Brown, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm

On 12/03/2023 10:42, Laurent Pinchart wrote:
> Hi Krzysztof,
> 
> Thank you for the patch.
> 
> On Fri, Mar 10, 2023 at 10:45:46PM +0100, Krzysztof Kozlowski wrote:
>> The driver can be compile tested with !CONFIG_OF making certain data
>> unused:
>>
>>   drivers/regulator/max20086-regulator.c:289:34: error: ‘max20086_dt_ids’ defined but not used [-Werror=unused-const-variable=]
>>
>> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>> ---
>>  drivers/regulator/max20086-regulator.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/regulator/max20086-regulator.c b/drivers/regulator/max20086-regulator.c
>> index b8bf76c170fe..c98a72f43935 100644
>> --- a/drivers/regulator/max20086-regulator.c
>> +++ b/drivers/regulator/max20086-regulator.c
>> @@ -286,7 +286,7 @@ static const struct i2c_device_id max20086_i2c_id[] = {
>>  
>>  MODULE_DEVICE_TABLE(i2c, max20086_i2c_id);
>>  
>> -static const struct of_device_id max20086_dt_ids[] = {
>> +static const struct of_device_id max20086_dt_ids[] __maybe_unused = {
> 
> The following change would also work, as the of_match_table field of
> struct device_driver isn't conditioned by CONFIG_OF:
> 
> diff --git a/drivers/regulator/max20086-regulator.c b/drivers/regulator/max20086-regulator.c
> index b8bf76c170fe..ad92f84b4abb 100644
> --- a/drivers/regulator/max20086-regulator.c
> +++ b/drivers/regulator/max20086-regulator.c
> @@ -320,7 +320,7 @@ MODULE_DEVICE_TABLE(of, max20086_dt_ids);
>  static struct i2c_driver max20086_regulator_driver = {
>  	.driver = {
>  		.name = "max20086",
> -		.of_match_table = of_match_ptr(max20086_dt_ids),
> +		.of_match_table = max20086_dt_ids,
>  	},
>  	.probe_new = max20086_i2c_probe,
>  	.id_table = max20086_i2c_id,
> 
> Your patch should reduce the module size without any real drawback as
> far as I can see, so that's probably best. I'm fine with either
> approach, so

I know it would work. If you check all my patches you see both patterns
used depending on the needs:
https://lore.kernel.org/all/?q=f%3Akrzysztof+of_device_id
(~100 patches so far)

The point is that here the device can actually match via ID table, so OF
table could stay optional. I don't think PRP0001 is relevant here, thus
I proposed to keep OF table optional. Different folks have different
opinion on that, so if general consensus is that availability of OF ID
table (for PRP0001) is preferred, I can rework the patch towards it.


> 
> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

Thanks

Best regards,
Krzysztof


^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 2/9] regulator: max20086: Mark OF related data as maybe unused
@ 2023-03-12 10:03       ` Krzysztof Kozlowski
  0 siblings, 0 replies; 30+ messages in thread
From: Krzysztof Kozlowski @ 2023-03-12 10:03 UTC (permalink / raw)
  To: Laurent Pinchart
  Cc: Liam Girdwood, Mark Brown, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm

On 12/03/2023 10:42, Laurent Pinchart wrote:
> Hi Krzysztof,
> 
> Thank you for the patch.
> 
> On Fri, Mar 10, 2023 at 10:45:46PM +0100, Krzysztof Kozlowski wrote:
>> The driver can be compile tested with !CONFIG_OF making certain data
>> unused:
>>
>>   drivers/regulator/max20086-regulator.c:289:34: error: ‘max20086_dt_ids’ defined but not used [-Werror=unused-const-variable=]
>>
>> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
>> ---
>>  drivers/regulator/max20086-regulator.c | 2 +-
>>  1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/regulator/max20086-regulator.c b/drivers/regulator/max20086-regulator.c
>> index b8bf76c170fe..c98a72f43935 100644
>> --- a/drivers/regulator/max20086-regulator.c
>> +++ b/drivers/regulator/max20086-regulator.c
>> @@ -286,7 +286,7 @@ static const struct i2c_device_id max20086_i2c_id[] = {
>>  
>>  MODULE_DEVICE_TABLE(i2c, max20086_i2c_id);
>>  
>> -static const struct of_device_id max20086_dt_ids[] = {
>> +static const struct of_device_id max20086_dt_ids[] __maybe_unused = {
> 
> The following change would also work, as the of_match_table field of
> struct device_driver isn't conditioned by CONFIG_OF:
> 
> diff --git a/drivers/regulator/max20086-regulator.c b/drivers/regulator/max20086-regulator.c
> index b8bf76c170fe..ad92f84b4abb 100644
> --- a/drivers/regulator/max20086-regulator.c
> +++ b/drivers/regulator/max20086-regulator.c
> @@ -320,7 +320,7 @@ MODULE_DEVICE_TABLE(of, max20086_dt_ids);
>  static struct i2c_driver max20086_regulator_driver = {
>  	.driver = {
>  		.name = "max20086",
> -		.of_match_table = of_match_ptr(max20086_dt_ids),
> +		.of_match_table = max20086_dt_ids,
>  	},
>  	.probe_new = max20086_i2c_probe,
>  	.id_table = max20086_i2c_id,
> 
> Your patch should reduce the module size without any real drawback as
> far as I can see, so that's probably best. I'm fine with either
> approach, so

I know it would work. If you check all my patches you see both patterns
used depending on the needs:
https://lore.kernel.org/all/?q=f%3Akrzysztof+of_device_id
(~100 patches so far)

The point is that here the device can actually match via ID table, so OF
table could stay optional. I don't think PRP0001 is relevant here, thus
I proposed to keep OF table optional. Different folks have different
opinion on that, so if general consensus is that availability of OF ID
table (for PRP0001) is preferred, I can rework the patch towards it.


> 
> Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>

Thanks

Best regards,
Krzysztof


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 4/9] regulator: mt6397-regulator: Mark OF related data as maybe unused
  2023-03-10 21:45   ` Krzysztof Kozlowski
@ 2023-03-13  8:45     ` AngeloGioacchino Del Regno
  -1 siblings, 0 replies; 30+ messages in thread
From: AngeloGioacchino Del Regno @ 2023-03-13  8:45 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Liam Girdwood, Mark Brown, Laurent Pinchart,
	Matthias Brugger, Tony Lindgren, Andy Gross, Bjorn Andersson,
	Konrad Dybcio, linux-kernel, linux-arm-kernel, linux-mediatek,
	linux-omap, linux-arm-msm

Il 10/03/23 22:45, Krzysztof Kozlowski ha scritto:
> The driver can be compile tested with !CONFIG_OF making certain data
> unused:
> 
>    drivers/regulator/mt6397-regulator.c:400:34: error: ‘mt6397_of_match’ defined but not used [-Werror=unused-const-variable=]
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>



^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 4/9] regulator: mt6397-regulator: Mark OF related data as maybe unused
@ 2023-03-13  8:45     ` AngeloGioacchino Del Regno
  0 siblings, 0 replies; 30+ messages in thread
From: AngeloGioacchino Del Regno @ 2023-03-13  8:45 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Liam Girdwood, Mark Brown, Laurent Pinchart,
	Matthias Brugger, Tony Lindgren, Andy Gross, Bjorn Andersson,
	Konrad Dybcio, linux-kernel, linux-arm-kernel, linux-mediatek,
	linux-omap, linux-arm-msm

Il 10/03/23 22:45, Krzysztof Kozlowski ha scritto:
> The driver can be compile tested with !CONFIG_OF making certain data
> unused:
> 
>    drivers/regulator/mt6397-regulator.c:400:34: error: ‘mt6397_of_match’ defined but not used [-Werror=unused-const-variable=]
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>



_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 1/9] regulator: lp872x: Mark OF related data as maybe unused
  2023-03-10 21:45 ` Krzysztof Kozlowski
@ 2023-03-13 13:58   ` Mark Brown
  -1 siblings, 0 replies; 30+ messages in thread
From: Mark Brown @ 2023-03-13 13:58 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Liam Girdwood, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm

[-- Attachment #1: Type: text/plain, Size: 471 bytes --]

On Fri, Mar 10, 2023 at 10:45:45PM +0100, Krzysztof Kozlowski wrote:
> The driver can be compile tested with !CONFIG_OF making certain data
> unused:
> 
>   drivers/regulator/lp872x.c:931:34: error: ‘lp872x_dt_ids’ defined but not used [-Werror=unused-const-variable=]

Here you're using maybe unused instead of removing the of_match_ptr()
(which does seem like a better approach).  This really feels very
random, there's obviously a usability problem here.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 1/9] regulator: lp872x: Mark OF related data as maybe unused
@ 2023-03-13 13:58   ` Mark Brown
  0 siblings, 0 replies; 30+ messages in thread
From: Mark Brown @ 2023-03-13 13:58 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Liam Girdwood, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm


[-- Attachment #1.1: Type: text/plain, Size: 471 bytes --]

On Fri, Mar 10, 2023 at 10:45:45PM +0100, Krzysztof Kozlowski wrote:
> The driver can be compile tested with !CONFIG_OF making certain data
> unused:
> 
>   drivers/regulator/lp872x.c:931:34: error: ‘lp872x_dt_ids’ defined but not used [-Werror=unused-const-variable=]

Here you're using maybe unused instead of removing the of_match_ptr()
(which does seem like a better approach).  This really feels very
random, there's obviously a usability problem here.

[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

[-- Attachment #2: Type: text/plain, Size: 176 bytes --]

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: (subset) [PATCH 1/9] regulator: lp872x: Mark OF related data as maybe unused
  2023-03-10 21:45 ` Krzysztof Kozlowski
@ 2023-03-13 19:07   ` Mark Brown
  -1 siblings, 0 replies; 30+ messages in thread
From: Mark Brown @ 2023-03-13 19:07 UTC (permalink / raw)
  To: Liam Girdwood, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm, Krzysztof Kozlowski

On Fri, 10 Mar 2023 22:45:45 +0100, Krzysztof Kozlowski wrote:
> The driver can be compile tested with !CONFIG_OF making certain data
> unused:
> 
>   drivers/regulator/lp872x.c:931:34: error: ‘lp872x_dt_ids’ defined but not used [-Werror=unused-const-variable=]
> 
> 

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next

Thanks!

[1/9] regulator: lp872x: Mark OF related data as maybe unused
      commit: 70b26bb55f719e2900404459128d41c8425c8dde
[2/9] regulator: max20086: Mark OF related data as maybe unused
      commit: 4a5850865641d0b83caaad81ca0bbd722ac514fb
[3/9] regulator: mp8859: Mark OF related data as maybe unused
      commit: 334e6b85a348a79bb018003f09e1cc94accd53a2
[4/9] regulator: mt6397-regulator: Mark OF related data as maybe unused
      commit: 38cc873cb1cf27965dacbbc5957a7a8aee89679c

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark


^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: (subset) [PATCH 1/9] regulator: lp872x: Mark OF related data as maybe unused
@ 2023-03-13 19:07   ` Mark Brown
  0 siblings, 0 replies; 30+ messages in thread
From: Mark Brown @ 2023-03-13 19:07 UTC (permalink / raw)
  To: Liam Girdwood, Laurent Pinchart, Matthias Brugger,
	AngeloGioacchino Del Regno, Tony Lindgren, Andy Gross,
	Bjorn Andersson, Konrad Dybcio, linux-kernel, linux-arm-kernel,
	linux-mediatek, linux-omap, linux-arm-msm, Krzysztof Kozlowski

On Fri, 10 Mar 2023 22:45:45 +0100, Krzysztof Kozlowski wrote:
> The driver can be compile tested with !CONFIG_OF making certain data
> unused:
> 
>   drivers/regulator/lp872x.c:931:34: error: ‘lp872x_dt_ids’ defined but not used [-Werror=unused-const-variable=]
> 
> 

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/regulator.git for-next

Thanks!

[1/9] regulator: lp872x: Mark OF related data as maybe unused
      commit: 70b26bb55f719e2900404459128d41c8425c8dde
[2/9] regulator: max20086: Mark OF related data as maybe unused
      commit: 4a5850865641d0b83caaad81ca0bbd722ac514fb
[3/9] regulator: mp8859: Mark OF related data as maybe unused
      commit: 334e6b85a348a79bb018003f09e1cc94accd53a2
[4/9] regulator: mt6397-regulator: Mark OF related data as maybe unused
      commit: 38cc873cb1cf27965dacbbc5957a7a8aee89679c

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 7/9] regulator: rpi-panel-attiny: Drop of_match_ptr for ID table
  2023-03-10 21:45   ` Krzysztof Kozlowski
@ 2023-03-15  9:12     ` Neil Armstrong
  -1 siblings, 0 replies; 30+ messages in thread
From: Neil Armstrong @ 2023-03-15  9:12 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Liam Girdwood, Mark Brown, Laurent Pinchart,
	Matthias Brugger, AngeloGioacchino Del Regno, Tony Lindgren,
	Andy Gross, Bjorn Andersson, Konrad Dybcio, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-omap, linux-arm-msm

On 10/03/2023 22:45, Krzysztof Kozlowski wrote:
> The driver can match only via the DT table so the table should be always
> used and the of_match_ptr does not have any sense (this also allows ACPI
> matching via PRP0001, even though it is not relevant here).
> 
>    drivers/regulator/rpi-panel-attiny-regulator.c:390:34: error: ‘attiny_dt_ids’ defined but not used [-Werror=unused-const-variable=]
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
>   drivers/regulator/rpi-panel-attiny-regulator.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/regulator/rpi-panel-attiny-regulator.c b/drivers/regulator/rpi-panel-attiny-regulator.c
> index 34514976475e..3953fc1f389f 100644
> --- a/drivers/regulator/rpi-panel-attiny-regulator.c
> +++ b/drivers/regulator/rpi-panel-attiny-regulator.c
> @@ -396,7 +396,7 @@ MODULE_DEVICE_TABLE(of, attiny_dt_ids);
>   static struct i2c_driver attiny_regulator_driver = {
>   	.driver = {
>   		.name = "rpi_touchscreen_attiny",
> -		.of_match_table = of_match_ptr(attiny_dt_ids),
> +		.of_match_table = attiny_dt_ids,
>   	},
>   	.probe_new = attiny_i2c_probe,
>   	.remove	= attiny_i2c_remove,


Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 7/9] regulator: rpi-panel-attiny: Drop of_match_ptr for ID table
@ 2023-03-15  9:12     ` Neil Armstrong
  0 siblings, 0 replies; 30+ messages in thread
From: Neil Armstrong @ 2023-03-15  9:12 UTC (permalink / raw)
  To: Krzysztof Kozlowski, Liam Girdwood, Mark Brown, Laurent Pinchart,
	Matthias Brugger, AngeloGioacchino Del Regno, Tony Lindgren,
	Andy Gross, Bjorn Andersson, Konrad Dybcio, linux-kernel,
	linux-arm-kernel, linux-mediatek, linux-omap, linux-arm-msm

On 10/03/2023 22:45, Krzysztof Kozlowski wrote:
> The driver can match only via the DT table so the table should be always
> used and the of_match_ptr does not have any sense (this also allows ACPI
> matching via PRP0001, even though it is not relevant here).
> 
>    drivers/regulator/rpi-panel-attiny-regulator.c:390:34: error: ‘attiny_dt_ids’ defined but not used [-Werror=unused-const-variable=]
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
> ---
>   drivers/regulator/rpi-panel-attiny-regulator.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/regulator/rpi-panel-attiny-regulator.c b/drivers/regulator/rpi-panel-attiny-regulator.c
> index 34514976475e..3953fc1f389f 100644
> --- a/drivers/regulator/rpi-panel-attiny-regulator.c
> +++ b/drivers/regulator/rpi-panel-attiny-regulator.c
> @@ -396,7 +396,7 @@ MODULE_DEVICE_TABLE(of, attiny_dt_ids);
>   static struct i2c_driver attiny_regulator_driver = {
>   	.driver = {
>   		.name = "rpi_touchscreen_attiny",
> -		.of_match_table = of_match_ptr(attiny_dt_ids),
> +		.of_match_table = attiny_dt_ids,
>   	},
>   	.probe_new = attiny_i2c_probe,
>   	.remove	= attiny_i2c_remove,


Reviewed-by: Neil Armstrong <neil.armstrong@linaro.org>

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2023-03-15  9:13 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-10 21:45 [PATCH 1/9] regulator: lp872x: Mark OF related data as maybe unused Krzysztof Kozlowski
2023-03-10 21:45 ` Krzysztof Kozlowski
2023-03-10 21:45 ` [PATCH 2/9] regulator: max20086: " Krzysztof Kozlowski
2023-03-10 21:45   ` Krzysztof Kozlowski
2023-03-12  9:42   ` Laurent Pinchart
2023-03-12  9:42     ` Laurent Pinchart
2023-03-12 10:03     ` Krzysztof Kozlowski
2023-03-12 10:03       ` Krzysztof Kozlowski
2023-03-10 21:45 ` [PATCH 3/9] regulator: mp8859: " Krzysztof Kozlowski
2023-03-10 21:45   ` Krzysztof Kozlowski
2023-03-10 21:45 ` [PATCH 4/9] regulator: mt6397-regulator: " Krzysztof Kozlowski
2023-03-10 21:45   ` Krzysztof Kozlowski
2023-03-13  8:45   ` AngeloGioacchino Del Regno
2023-03-13  8:45     ` AngeloGioacchino Del Regno
2023-03-10 21:45 ` [PATCH 5/9] regulator: qcom_rpm: Drop of_match_ptr for ID table Krzysztof Kozlowski
2023-03-10 21:45   ` Krzysztof Kozlowski
2023-03-10 21:45 ` [PATCH 6/9] regulator: pbias: " Krzysztof Kozlowski
2023-03-10 21:45   ` Krzysztof Kozlowski
2023-03-10 21:45 ` [PATCH 7/9] regulator: rpi-panel-attiny: " Krzysztof Kozlowski
2023-03-10 21:45   ` Krzysztof Kozlowski
2023-03-15  9:12   ` Neil Armstrong
2023-03-15  9:12     ` Neil Armstrong
2023-03-10 21:45 ` [PATCH 8/9] regulator: twl: " Krzysztof Kozlowski
2023-03-10 21:45   ` Krzysztof Kozlowski
2023-03-10 21:45 ` [PATCH 9/9] regulator: twl6030: " Krzysztof Kozlowski
2023-03-10 21:45   ` Krzysztof Kozlowski
2023-03-13 13:58 ` [PATCH 1/9] regulator: lp872x: Mark OF related data as maybe unused Mark Brown
2023-03-13 13:58   ` Mark Brown
2023-03-13 19:07 ` (subset) " Mark Brown
2023-03-13 19:07   ` Mark Brown

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.