Skip to contentSkip to conversation

rtc: fsl-ftm: remove incorrect ACPI_PTR annotation

PATCH In review Arnd Bergmann 3 participants 4 messages Feb 25, 2025 Real time clock (RTC)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 rtc: fsl-ftm: remove incorrect ACPI_PTR annotation

From: Arnd Bergmann <[email protected]>

Building with W=1 shows a warning about ftm_imx_acpi_ids being unused when CONFIG_ACPI is disabled:

drivers/rtc/rtc-fsl-ftm-alarm.c:312:36: error: unused variable 'ftm_imx_acpi_ids' [-Werror,-Wunused-const-variable]

---
 drivers/rtc/rtc-fsl-ftm-alarm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/rtc/rtc-fsl-ftm-alarm.c +1 -1
index a72c4ad0cec6..12da7d36e520 100644
@@ -320,7 +320,7 @@ static struct platform_driver ftm_rtc_driver = {
 	.driver		= {
 		.name	= "ftm-alarm",
 		.of_match_table = ftm_rtc_match,
-		.acpi_match_table = ACPI_PTR(ftm_imx_acpi_ids),
+		.acpi_match_table = ftm_imx_acpi_ids,
 	},
 };
 
Signature · 1 line
2.39.5
#1 lore raw
Quoted 8 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

Building with W=1 shows a warning about ftm_imx_acpi_ids being unused when CONFIG_ACPI is disabled:

drivers/rtc/rtc-fsl-ftm-alarm.c:312:36: error: unused variable 'ftm_imx_acpi_ids' [-Werror,-Wunused-const-variable]

I already sent a fix for this few days ago:

https://lore.kernel.org/all/[email protected]/

Best regards,
Krzysztof

#2 lore raw
Quoted 6 lines · Krzysztof Kozlowski
Quoted 5 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

Building with W=1 shows a warning about ftm_imx_acpi_ids being unused when CONFIG_ACPI is disabled:

Quoted 8 lines
Quoted 3 lines

drivers/rtc/rtc-fsl-ftm-alarm.c:312:36: error: unused variable 'ftm_imx_acpi_ids' [-Werror,-Wunused-const-variable]

I already sent a fix for this few days ago:

https://lore.kernel.org/all/[email protected]/

But wouldn't Arnd's one be better?

Signature · 3 lines
Alexandre Belloni, co-owner and COO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
#3 lore raw
Quoted 9 lines · Alexandre Belloni
Quoted 8 lines · Krzysztof Kozlowski
Quoted 7 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

Building with W=1 shows a warning about ftm_imx_acpi_ids being unused when CONFIG_ACPI is disabled:

drivers/rtc/rtc-fsl-ftm-alarm.c:312:36: error: unused variable 'ftm_imx_acpi_ids' [-Werror,-Wunused-const-variable]

Quoted 8 lines
Quoted 6 lines
Quoted 1 line

I already sent a fix for this few days ago:

https://lore.kernel.org/all/[email protected]/

But wouldn't Arnd's one be better?

ACPI table can be here entirely dropped and driver will match via PRP0001, so I think ACPI_PTR makes sense.

But if you have arguments for keeping both, sure... There was no response to my trivial patch and multiple people will be wasting same time on the same issue. So just apply whichever of these, before third person wastes more time on that warning.

Best regards,
Krzysztof