]> git.sur5r.net Git - u-boot/blobdiff - arch/arm/mach-uniphier/spl_board_init.c
ARM: uniphier: correct spelling of "invalid"
[u-boot] / arch / arm / mach-uniphier / spl_board_init.c
index 83851ef7d69f55069e500a9be4e02288a83d6012..0079a083e838f0ebded6be1016eea193b335b036 100644 (file)
@@ -118,25 +118,12 @@ static const struct uniphier_spl_initdata uniphier_spl_initdata[] = {
        },
 #endif
 };
-
-static const struct uniphier_spl_initdata *uniphier_get_spl_initdata(
-                                                       unsigned int soc_id)
-{
-       int i;
-
-       for (i = 0; i < ARRAY_SIZE(uniphier_spl_initdata); i++) {
-               if (uniphier_spl_initdata[i].soc_id == soc_id)
-                       return &uniphier_spl_initdata[i];
-       }
-
-       return NULL;
-}
+UNIPHIER_DEFINE_SOCDATA_FUNC(uniphier_get_spl_initdata, uniphier_spl_initdata)
 
 void spl_board_init(void)
 {
        const struct uniphier_board_data *bd;
        const struct uniphier_spl_initdata *initdata;
-       unsigned int soc_id;
        int ret;
 
 #ifdef CONFIG_DEBUG_UART
@@ -147,8 +134,7 @@ void spl_board_init(void)
        if (!bd)
                hang();
 
-       soc_id = uniphier_get_soc_id();
-       initdata = uniphier_get_spl_initdata(soc_id);
+       initdata = uniphier_get_spl_initdata();
        if (!initdata)
                hang();
 
@@ -182,4 +168,8 @@ void spl_board_init(void)
                pr_err("failed to init DRAM\n");
                hang();
        }
+
+#ifdef CONFIG_ARM64
+       dcache_disable();
+#endif
 }