fdt_support: make FDT_FIXUP_PARTITIONS depend on CMD_MTDPARTS
authorMasahiro Yamada <yamada.masahiro@socionext.com>
Fri, 20 Jul 2018 02:04:09 +0000 (11:04 +0900)
committerSimon Glass <sjg@chromium.org>
Thu, 26 Jul 2018 20:20:27 +0000 (14:20 -0600)
fdt_fixup_mtdparts() calls mtdparts_init() and device_find(),
which are defined in cmd/mtdparts.c

The combination of FDT_FIXUP_PARTITIONS=y and CMD_MTDPARTS=n
emits the following link error:

  common/fdt_support.c:903: undefined reference to `mtdparts_init'
  common/fdt_support.c:914: undefined reference to `device_find'

Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
lib/Kconfig

index a77bf1c688affc9f72ebd10ed0df1c2d4f9672dc..622f3c26c331134ff7c805e68353d3416e6b7003 100644 (file)
@@ -334,7 +334,7 @@ config SPL_OF_LIBFDT
 config FDT_FIXUP_PARTITIONS
        bool "overwrite MTD partitions in DTS through defined in 'mtdparts'"
        depends on OF_LIBFDT
-       default n
+       depends on CMD_MTDPARTS
        help
          Allow overwriting defined partitions in the device tree blob
          using partition info defined in the 'mtdparts' environment