]> git.sur5r.net Git - u-boot/blobdiff - board/spear/common/spr_misc.c
Merge branch 'master' of git://git.denx.de/u-boot-nds32
[u-boot] / board / spear / common / spr_misc.c
index e2918ff40560c0f18efe18d989fea454079f800d..bc92cd6f494320e9122e2aa7277294d3ab3f80e0 100644 (file)
@@ -2,29 +2,14 @@
  * (C) Copyright 2009
  * Vipin Kumar, ST Micoelectronics, vipin.kumar@st.com.
  *
- * See file CREDITS for list of people who contributed to this
- * project.
- *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
+ * SPDX-License-Identifier:    GPL-2.0+
  */
 
 #include <common.h>
 #include <command.h>
 #include <i2c.h>
 #include <net.h>
+#include <linux/mtd/st_smi.h>
 #include <asm/io.h>
 #include <asm/arch/hardware.h>
 #include <asm/arch/spr_emi.h>
@@ -54,6 +39,13 @@ void dram_init_banksize(void)
        gd->bd->bi_dram[0].size = gd->ram_size;
 }
 
+int board_early_init_f()
+{
+#if defined(CONFIG_ST_SMI)
+       smi_init();
+#endif
+       return 0;
+}
 int misc_init_r(void)
 {
 #if defined(CONFIG_CMD_NET)
@@ -68,6 +60,10 @@ int misc_init_r(void)
        setenv("stdin", "usbtty");
        setenv("stdout", "usbtty");
        setenv("stderr", "usbtty");
+
+#ifndef CONFIG_SYS_NO_DCACHE
+       dcache_enable();
+#endif
 #endif
        return 0;
 }