]> git.sur5r.net Git - u-boot/commitdiff
ARM: omap3: beagle: Set 'mtdids' and 'mtdparts' in board file
authorDerald D. Woods <woods.technical@gmail.com>
Mon, 26 Feb 2018 23:52:57 +0000 (17:52 -0600)
committerTom Rini <trini@konsulko.com>
Wed, 14 Mar 2018 01:59:27 +0000 (21:59 -0400)
BeagleBoard 'xM' does not really have NAND. CONFIG_MTDIDS_DEFAULT and
CONFIG_MTDPARTS_DEFAULT can/should be empty for 'xM'. This commit sets
the defined values if they exist.

Signed-off-by: Derald D. Woods <woods.technical@gmail.com>
board/ti/beagle/beagle.c

index d8402f26752efa18a1f60f6538265d23ee830c39..1d552647335aa4fdd5a3a1f2ba15d258371b0425 100644 (file)
@@ -521,6 +521,14 @@ int misc_init_r(void)
        if (generate_fake_mac)
                omap_die_id_usbethaddr();
 
+#if defined(CONFIG_MTDIDS_DEFAULT) && defined(CONFIG_MTDPARTS_DEFAULT)
+       if (strlen(CONFIG_MTDIDS_DEFAULT))
+               env_set("mtdids", CONFIG_MTDIDS_DEFAULT);
+
+       if (strlen(CONFIG_MTDPARTS_DEFAULT))
+               env_set("mtdparts", CONFIG_MTDPARTS_DEFAULT);
+#endif
+
        return 0;
 }