Commit 3fd2fdb3 authored by Stephen Boyd's avatar Stephen Boyd

mmc: meson-mx-sdio: Depend on OF_ADDRESS and not just OF

Making COMMON_CLK a visible option causes the sparc allyesconfig to fail
to build like so:

   sparc64-linux-ld: drivers/mmc/host/meson-mx-sdio.o: in function `meson_mx_mmc_remove':
   meson-mx-sdio.c:(.text+0x70): undefined reference to `of_platform_device_destroy'
   sparc64-linux-ld: drivers/mmc/host/meson-mx-sdio.o: in function `meson_mx_mmc_probe':
   meson-mx-sdio.c:(.text+0x9e4): undefined reference to `of_platform_device_create'
   sparc64-linux-ld: meson-mx-sdio.c:(.text+0xdd4): undefined reference to `of_platform_device_destroy'

This is because the implementation of of_platform_device_destroy() is
inside an #ifdef CONFIG_OF_ADDRESS section of drivers/of/platform.c.
This driver already depends on OF being enabled, so let's tighten that
constrain a little more so that it depends on OF_ADDRESS instead. This
way we won't try to build this driver on platforms that don't have this
function.
Reported-by: default avatarkbuild test robot <lkp@intel.com>
Cc: Neil Armstrong <narmstrong@baylibre.com>
Cc: Ulf Hansson <ulf.hansson@linaro.org>
Signed-off-by: default avatarStephen Boyd <sboyd@kernel.org>
Link: https://lkml.kernel.org/r/20200409064416.83340-7-sboyd@kernel.orgAcked-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
Reviewed-by: default avatarArnd Bergmann <arnd@arndb.de>
parent b62bc047
......@@ -409,7 +409,7 @@ config MMC_MESON_MX_SDIO
tristate "Amlogic Meson6/Meson8/Meson8b SD/MMC Host Controller support"
depends on ARCH_MESON || COMPILE_TEST
depends on COMMON_CLK
depends on OF
depends on OF_ADDRESS
help
This selects support for the SD/MMC Host Controller on
Amlogic Meson6, Meson8 and Meson8b SoCs.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment