[PATCH 1/9] ASoC: qcom: lpass-sc7280: Drop of_match_ptr for ID table
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 --- sound/soc/qcom/lpass-sc7280.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/qcom/lpass-sc7280.c b/sound/soc/qcom/lpass-sc7280.c index d43f480cbae3..956b974e322e 100644 --- a/sound/soc/qcom/lpass-sc7280.c +++ b/sound/soc/qcom/lpass-sc7280.c @@ -443,7 +443,7 @@ MODULE_DEVICE_TABLE(of, sc7280_lpass_cpu_device_id); static struct platform_driver sc7280_lpass_cpu_platform_driver = { .driver = { .name = "sc7280-lpass-cpu", - .of_match_table = of_match_ptr(sc7280_lpass_cpu_device_id), + .of_match_table = sc7280_lpass_cpu_device_id, .pm = &sc7280_lpass_pm_ops, }, .probe = asoc_qcom_lpass_cpu_platform_probe,
The Qualcomm SoC power-on driver is specific to ARCH_QCOM which depends on OF thus the driver is OF-only. It's 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/power/reset/qcom-pon.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/power/reset/qcom-pon.c b/drivers/power/reset/qcom-pon.c index 16bc01738be9..ebdcfb28c4a0 100644 --- a/drivers/power/reset/qcom-pon.c +++ b/drivers/power/reset/qcom-pon.c @@ -91,7 +91,7 @@ static struct platform_driver pm8916_pon_driver = { .probe = pm8916_pon_probe, .driver = { .name = "pm8916-pon", - .of_match_table = of_match_ptr(pm8916_pon_id_table), + .of_match_table = pm8916_pon_id_table, }, }; module_platform_driver(pm8916_pon_driver);
On 10/03/2023 22:43, Krzysztof Kozlowski wrote:
The Qualcomm SoC power-on driver is specific to ARCH_QCOM which depends on OF thus the driver is OF-only. It's 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/power/reset/qcom-pon.c | 2 +-
This one is a duplicate - I already sent it separate. Please ignore.
Best regards, Krzysztof
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).
sound/soc/atmel/sam9x5_wm8731.c:189:34: error: ‘sam9x5_wm8731_of_match’ defined but not used [-Werror=unused-const-variable=]
Signed-off-by: Krzysztof Kozlowski krzysztof.kozlowski@linaro.org --- sound/soc/atmel/sam9x5_wm8731.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/atmel/sam9x5_wm8731.c b/sound/soc/atmel/sam9x5_wm8731.c index 99310e40e7a6..2bc622e86376 100644 --- a/sound/soc/atmel/sam9x5_wm8731.c +++ b/sound/soc/atmel/sam9x5_wm8731.c @@ -195,7 +195,7 @@ MODULE_DEVICE_TABLE(of, sam9x5_wm8731_of_match); static struct platform_driver sam9x5_wm8731_driver = { .driver = { .name = DRV_NAME, - .of_match_table = of_match_ptr(sam9x5_wm8731_of_match), + .of_match_table = sam9x5_wm8731_of_match, }, .probe = sam9x5_wm8731_driver_probe, .remove = sam9x5_wm8731_driver_remove,
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).
sound/soc/samsung/aries_wm8994.c:523:34: error: ‘samsung_wm8994_of_match’ defined but not used [-Werror=unused-const-variable=]
Signed-off-by: Krzysztof Kozlowski krzysztof.kozlowski@linaro.org --- sound/soc/samsung/aries_wm8994.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/samsung/aries_wm8994.c b/sound/soc/samsung/aries_wm8994.c index 0fbbf3b02c09..9122482a0e5c 100644 --- a/sound/soc/samsung/aries_wm8994.c +++ b/sound/soc/samsung/aries_wm8994.c @@ -684,7 +684,7 @@ static int aries_audio_probe(struct platform_device *pdev) static struct platform_driver aries_audio_driver = { .driver = { .name = "aries-audio-wm8994", - .of_match_table = of_match_ptr(samsung_wm8994_of_match), + .of_match_table = samsung_wm8994_of_match, .pm = &snd_soc_pm_ops, }, .probe = aries_audio_probe,
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).
sound/soc/codecs/rt5514-spi.c:497:34: error: ‘rt5514_of_match’ defined but not used [-Werror=unused-const-variable=]
Signed-off-by: Krzysztof Kozlowski krzysztof.kozlowski@linaro.org --- sound/soc/codecs/rt5514-spi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/codecs/rt5514-spi.c b/sound/soc/codecs/rt5514-spi.c index 362663abcb89..22c0afa01459 100644 --- a/sound/soc/codecs/rt5514-spi.c +++ b/sound/soc/codecs/rt5514-spi.c @@ -504,7 +504,7 @@ static struct spi_driver rt5514_spi_driver = { .driver = { .name = "rt5514", .pm = &rt5514_pm_ops, - .of_match_table = of_match_ptr(rt5514_of_match), + .of_match_table = rt5514_of_match, }, .probe = rt5514_spi_probe, };
The driver can be compile tested with !CONFIG_OF making certain data unused:
sound/soc/codecs/adau1977-spi.c:58:34: error: ‘adau1977_spi_of_match’ defined but not used [-Werror=unused-const-variable=]
Signed-off-by: Krzysztof Kozlowski krzysztof.kozlowski@linaro.org --- sound/soc/codecs/adau1977-spi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/codecs/adau1977-spi.c b/sound/soc/codecs/adau1977-spi.c index 8370bec27a9c..207c5c95f35a 100644 --- a/sound/soc/codecs/adau1977-spi.c +++ b/sound/soc/codecs/adau1977-spi.c @@ -55,7 +55,7 @@ static const struct spi_device_id adau1977_spi_ids[] = { }; MODULE_DEVICE_TABLE(spi, adau1977_spi_ids);
-static const struct of_device_id adau1977_spi_of_match[] = { +static const struct of_device_id adau1977_spi_of_match[] __maybe_unused = { { .compatible = "adi,adau1977" }, { .compatible = "adi,adau1978" }, { .compatible = "adi,adau1979" },
The driver can be compile tested with !CONFIG_OF making certain data unused:
sound/soc/codecs/pcm179x-spi.c:32:34: error: ‘pcm179x_of_match’ defined but not used [-Werror=unused-const-variable=]
Signed-off-by: Krzysztof Kozlowski krzysztof.kozlowski@linaro.org --- sound/soc/codecs/pcm179x-spi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/codecs/pcm179x-spi.c b/sound/soc/codecs/pcm179x-spi.c index ebf63ea90a1c..192fee90c971 100644 --- a/sound/soc/codecs/pcm179x-spi.c +++ b/sound/soc/codecs/pcm179x-spi.c @@ -29,7 +29,7 @@ static int pcm179x_spi_probe(struct spi_device *spi) return pcm179x_common_init(&spi->dev, regmap); }
-static const struct of_device_id pcm179x_of_match[] = { +static const struct of_device_id pcm179x_of_match[] __maybe_unused = { { .compatible = "ti,pcm1792a", }, { } };
The driver can be compile tested with !CONFIG_OF making certain data unused:
sound/soc/codecs/rt1019.c:549:34: error: ‘rt1019_of_match’ defined but not used [-Werror=unused-const-variable=]
Signed-off-by: Krzysztof Kozlowski krzysztof.kozlowski@linaro.org --- sound/soc/codecs/rt1019.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/codecs/rt1019.c b/sound/soc/codecs/rt1019.c index 49f527c61a7a..dff2596c81eb 100644 --- a/sound/soc/codecs/rt1019.c +++ b/sound/soc/codecs/rt1019.c @@ -546,7 +546,7 @@ static const struct i2c_device_id rt1019_i2c_id[] = { }; MODULE_DEVICE_TABLE(i2c, rt1019_i2c_id);
-static const struct of_device_id rt1019_of_match[] = { +static const struct of_device_id rt1019_of_match[] __maybe_unused = { { .compatible = "realtek,rt1019", }, {}, };
The driver can be compile tested with !CONFIG_OF making certain data unused:
sound/soc/codecs/src4xxx-i2c.c:27:34: error: ‘src4xxx_of_match’ defined but not used [-Werror=unused-const-variable=]
Signed-off-by: Krzysztof Kozlowski krzysztof.kozlowski@linaro.org --- sound/soc/codecs/src4xxx-i2c.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/codecs/src4xxx-i2c.c b/sound/soc/codecs/src4xxx-i2c.c index 27026030704a..a40fd20df984 100644 --- a/sound/soc/codecs/src4xxx-i2c.c +++ b/sound/soc/codecs/src4xxx-i2c.c @@ -24,7 +24,7 @@ static const struct i2c_device_id src4xxx_i2c_ids[] = { }; MODULE_DEVICE_TABLE(i2c, src4xxx_i2c_ids);
-static const struct of_device_id src4xxx_of_match[] = { +static const struct of_device_id src4xxx_of_match[] __maybe_unused = { { .compatible = "ti,src4392", }, { } };
The driver can be compile tested with !CONFIG_OF making certain data unused:
sound/soc/codecs/zl38060.c:611:34: error: ‘zl38_dt_ids’ defined but not used [-Werror=unused-const-variable=]
Signed-off-by: Krzysztof Kozlowski krzysztof.kozlowski@linaro.org --- sound/soc/codecs/zl38060.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/codecs/zl38060.c b/sound/soc/codecs/zl38060.c index c3d0a2a7c36f..28c92d90299e 100644 --- a/sound/soc/codecs/zl38060.c +++ b/sound/soc/codecs/zl38060.c @@ -608,7 +608,7 @@ static int zl38_spi_probe(struct spi_device *spi) &zl38_dai, 1); }
-static const struct of_device_id zl38_dt_ids[] = { +static const struct of_device_id zl38_dt_ids[] __maybe_unused = { { .compatible = "mscc,zl38060", }, { /* sentinel */ } };
On Fri, 10 Mar 2023 22:43:24 +0100, Krzysztof Kozlowski wrote:
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.
Applied to
https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next
Thanks!
[5/9] ASoC: codecs: adau1977-spi: Mark OF related data as maybe unused commit: a9048d64fb9605eb68c9912724e4a1346db8ba1a [6/9] ASoC: codecs: pcm179x-spi: Mark OF related data as maybe unused commit: 413beba1a336e6068119f31a4441c51a7aeb1b55 [7/9] ASoC: codecs: rt1019: Mark OF related data as maybe unused commit: 0e8599a35823f05e90513918ff1201f8d210e315 [8/9] ASoC: codecs: src4xxx-i2c: Mark OF related data as maybe unused commit: 075a430db402eed0907b80493f1432d47a5120a7 [9/9] ASoC: codecs: zl38060: Mark OF related data as maybe unused commit: da1f22825b4fec7e25431fa5238252452f3dce46
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
participants (2)
-
Krzysztof Kozlowski
-
Mark Brown