1*a373024eSAngelo Dureghello /* 2*a373024eSAngelo Dureghello * Board-specific init. 3*a373024eSAngelo Dureghello * 4*a373024eSAngelo Dureghello * (C) Copyright 2017 Angelo Dureghello <angelo@sysam.it> 5*a373024eSAngelo Dureghello * 6*a373024eSAngelo Dureghello * SPDX-License-Identifier: GPL-2.0+ 7*a373024eSAngelo Dureghello */ 8*a373024eSAngelo Dureghello 9*a373024eSAngelo Dureghello #include <common.h> 10*a373024eSAngelo Dureghello #include <spi.h> 11*a373024eSAngelo Dureghello #include <asm/io.h> 12*a373024eSAngelo Dureghello #include <asm/immap.h> 13*a373024eSAngelo Dureghello #include <mmc.h> 14*a373024eSAngelo Dureghello #include <fsl_esdhc.h> 15*a373024eSAngelo Dureghello 16*a373024eSAngelo Dureghello DECLARE_GLOBAL_DATA_PTR; 17*a373024eSAngelo Dureghello 18*a373024eSAngelo Dureghello int checkboard(void) 19*a373024eSAngelo Dureghello { 20*a373024eSAngelo Dureghello /* 21*a373024eSAngelo Dureghello * need to to: 22*a373024eSAngelo Dureghello * Check serial flash size. if 2mb evb, else 8mb demo 23*a373024eSAngelo Dureghello */ 24*a373024eSAngelo Dureghello puts("Board: "); 25*a373024eSAngelo Dureghello puts("Sysam stmark2\n"); 26*a373024eSAngelo Dureghello return 0; 27*a373024eSAngelo Dureghello } 28*a373024eSAngelo Dureghello 29*a373024eSAngelo Dureghello int dram_init(void) 30*a373024eSAngelo Dureghello { 31*a373024eSAngelo Dureghello u32 dramsize; 32*a373024eSAngelo Dureghello 33*a373024eSAngelo Dureghello /* 34*a373024eSAngelo Dureghello * Serial Boot: The dram is already initialized in start.S 35*a373024eSAngelo Dureghello * only require to return DRAM size 36*a373024eSAngelo Dureghello */ 37*a373024eSAngelo Dureghello dramsize = CONFIG_SYS_SDRAM_SIZE * 0x100000; 38*a373024eSAngelo Dureghello 39*a373024eSAngelo Dureghello gd->ram_size = dramsize; 40*a373024eSAngelo Dureghello 41*a373024eSAngelo Dureghello return 0; 42*a373024eSAngelo Dureghello } 43*a373024eSAngelo Dureghello 44*a373024eSAngelo Dureghello int testdram(void) 45*a373024eSAngelo Dureghello { 46*a373024eSAngelo Dureghello return 0; 47*a373024eSAngelo Dureghello } 48