Skip to contentSkip to conversation

memory: pl353-smc: fix compile test on !ARM_AMBA

PATCH In review Krzysztof Kozlowski 3 participants 3 messages Oct 29, 2020 – Oct 30, 2020 Memory controller drivers

lore
Share & tools
lore

Krzysztof Kozlowski

author maintainer
#0 lore raw

PATCH 1/1 memory: pl353-smc: fix compile test on !ARM_AMBA

The pl353-smc driver uses module_amba_driver so it has a build dependency on CONFIG_ARM_AMBA:

    /usr/bin/arm-linux-gnueabi-ld: drivers/memory/pl353-smc.o: in function `pl353_smc_driver_init':
    pl353-smc.c:(.init.text+0x10): undefined reference to `amba_driver_register'

However it still can be compile tested on platforms other than ARM, which in practice is limited to those selecting ARM_AMBA (so only ARM64).

Fixes ea0c0ad6b6eb ("memory: Enable compile testing for most of the drivers")
---
 drivers/memory/Kconfig | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/memory/Kconfig +2 -2
index 00e013b14703..eebd2ddcd860 100644
@@ -191,8 +191,8 @@ config DA8XX_DDRCTL
 config PL353_SMC
 	tristate "ARM PL35X Static Memory Controller(SMC) driver"
 	default y if ARM
-	depends on ARM
-	depends on ARM_AMBA || COMPILE_TEST
+	depends on ARM || COMPILE_TEST
+	depends on ARM_AMBA
 	help
 	  This driver is for the ARM PL351/PL353 Static Memory
 	  Controller(SMC) module.
Signature · 1 line
2.25.1
#1 lore raw

+ authors/reviewers of commit fee10bd22678 ("memory: pl353: Add driver for arm pl353 static memory controller")

Quoted 36 lines · Krzysztof Kozlowski

The pl353-smc driver uses module_amba_driver so it has a build dependency on CONFIG_ARM_AMBA:

    /usr/bin/arm-linux-gnueabi-ld: drivers/memory/pl353-smc.o: in function `pl353_smc_driver_init':
    pl353-smc.c:(.init.text+0x10): undefined reference to `amba_driver_register'

However it still can be compile tested on platforms other than ARM, which in practice is limited to those selecting ARM_AMBA (so only ARM64).

Fixes ea0c0ad6b6eb ("memory: Enable compile testing for most of the drivers")
---
 drivers/memory/Kconfig | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/memory/Kconfig +2 -3
index 00e013b14703..eebd2ddcd860 100644
@@ -191,8 +191,8 @@ config DA8XX_DDRCTL
 config PL353_SMC
        tristate "ARM PL35X Static Memory Controller(SMC) driver"
        default y if ARM
-       depends on ARM
-       depends on ARM_AMBA || COMPILE_TEST
+       depends on ARM || COMPILE_TEST
+       depends on ARM_AMBA
        help
          This driver is for the ARM PL351/PL353 Static Memory
          Controller(SMC) module.
--

2.25.1

Signature · 2 lines
Thanks,
~Nick Desaulniers
Acked-by
#2 lore raw
Quoted 14 lines · Nick Desaulniers

+ authors/reviewers of commit fee10bd22678 ("memory: pl353: Add driver for arm pl353 static memory controller")

Quoted 10 lines · Krzysztof Kozlowski

The pl353-smc driver uses module_amba_driver so it has a build dependency on CONFIG_ARM_AMBA:

    /usr/bin/arm-linux-gnueabi-ld: drivers/memory/pl353-smc.o: in function `pl353_smc_driver_init':
    pl353-smc.c:(.init.text+0x10): undefined reference to `amba_driver_register'

However it still can be compile tested on platforms other than ARM, which in practice is limited to those selecting ARM_AMBA (so only ARM64).

Indeed.

Thanks,
Michal