Add SMDK5250 board support
Subsystems (3)
v8 cover Add SMDK5250 board support
This patchset add support for Samsung's SMDK5250 board based on EXYNOS5250 based SoC. It also adds support for MMC SPL booting.
The porting is done by Samsung engineers at HQ in System LSI Team. I am contributing in upstreaming the code for the board.
Based upon discussions following patches are dropped in this version:
Exynos: Add CONFIG_EXYNOS4 Macro to EXYNOS4 based boards
Exynos: Clock.c: Replace exynos4 prefix with exynos
SMDK5250: enable device tree support is squashed with
EXYNOS: Add SMDK5250 board support
Chander Kashyap (4):
Exynos: Clock.c: Use CONFIG_SYS_CLK_FREQ macro
ARM: EXYNOS: Add support for Exynos5 based SoCs
EXYNOS: Add SMDK5250 board support
EXYNOS: SMDK5250: Add MMC SPL support
MAINTAINERS | 1 + arch/arm/cpu/armv7/exynos/clock.c | 214 +++++++++++++- arch/arm/include/asm/arch-exynos/clock.h | 326 +++++++++++++++++++++ arch/arm/include/asm/arch-exynos/cpu.h | 35 +++- arch/arm/include/asm/arch-exynos/dmc.h | 146 ++++++++++ arch/arm/include/asm/arch-exynos/gpio.h | 99 ++++++- arch/arm/include/asm/arch-exynos/tzpc.h | 52 ++++ board/samsung/smdk5250/Makefile | 58 ++++ board/samsung/smdk5250/clock_init.c | 202 +++++++++++++ board/samsung/smdk5250/dmc_init.c | 462 ++++++++++++++++++++++++++++++ board/samsung/smdk5250/lowlevel_init.S | 96 ++++++ board/samsung/smdk5250/mmc_boot.c | 58 ++++ board/samsung/smdk5250/setup.h | 451 +++++++++++++++++++++++++++++ board/samsung/smdk5250/smdk5250.c | 146 ++++++++++ board/samsung/smdk5250/tzpc_init.c | 48 +++ boards.cfg | 1 + include/configs/s5pc210_universal.h | 1 + include/configs/smdk5250.h | 197 +++++++++++++ include/configs/trats.h | 1 + tools/Makefile | 6 + tools/mksmdk5250spl.c | 119 ++++++++ 21 files changed, 2702 insertions(+), 17 deletions(-) create mode 100644 arch/arm/include/asm/arch-exynos/dmc.h create mode 100644 arch/arm/include/asm/arch-exynos/tzpc.h create mode 100644 board/samsung/smdk5250/Makefile create mode 100644 board/samsung/smdk5250/clock_init.c create mode 100644 board/samsung/smdk5250/dmc_init.c create mode 100644 board/samsung/smdk5250/lowlevel_init.S create mode 100644 board/samsung/smdk5250/mmc_boot.c create mode 100644 board/samsung/smdk5250/setup.h create mode 100644 board/samsung/smdk5250/smdk5250.c create mode 100644 board/samsung/smdk5250/tzpc_init.c create mode 100644 include/configs/smdk5250.h create mode 100644 tools/mksmdk5250spl.c
Signature · 1 line
1.7.5.4
PATCH v8 1/4 Exynos: Clock.c: Use CONFIG_SYS_CLK_FREQ macro
CONFIG_SYS_CLK_FREQ_C210 macro giving notion of S5PC2XX (Exynos4) architecture. Replace CONFIG_SYS_CLK_FREQ_C210 with CONFIG_SYS_CLK_FREQ to make it generic for exynos architecture.
---
Changes for v2:
- None
Changes for v3:
- None
Changes for V4:
- Added CONFIG_SYS_CLK_FREQ to trats.h
Changes for v5:
- None
Changes for v6:
- None
Changes for v7:
- None
Changes for v8:
- None
arch/arm/cpu/armv7/exynos/clock.c | 6 +----- include/configs/s5pc210_universal.h | 1 + include/configs/trats.h | 1 + 3 files changed, 3 insertions(+), 5 deletions(-)
arch/arm/cpu/armv7/exynos/clock.c +1 -5
@@ -26,10 +26,6 @@#include <asm/arch/clock.h> #include <asm/arch/clk.h> -#ifndef CONFIG_SYS_CLK_FREQ_C210 -#define CONFIG_SYS_CLK_FREQ_C210 24000000 -#endif -/* exynos4: return pll clock frequency */ static unsigned long exynos4_get_pll_clk (int pllreg) {
@@ -76,7 +72,7 @@ static unsigned long exynos4_get_pll_clk(int pllreg)/* SDIV [2:0] */ s = r &0x7 ; - freq =CONFIG_SYS_CLK_FREQ_C210 ; + freq =CONFIG_SYS_CLK_FREQ ;if (pllreg ==EPLL ) { k = k &0xffff ;
include/configs/s5pc210_universal.h +1 -0
@@ -49,6 +49,7 @@/* input clock of PLL: Universal has 24MHz input clock at EXYNOS4210 */ #define CONFIG_SYS_CLK_FREQ_C210 24000000 +#define CONFIG_SYS_CLK_FREQ CONFIG_SYS_CLK_FREQ_C210#define CONFIG_SETUP_MEMORY_TAGS #define CONFIG_CMDLINE_TAG
include/configs/trats.h +1 -0
@@ -49,6 +49,7 @@/* input clock of PLL: TRATS has 24MHz input clock at EXYNOS4210 */ #define CONFIG_SYS_CLK_FREQ_C210 24000000 +#define CONFIG_SYS_CLK_FREQ CONFIG_SYS_CLK_FREQ_C210#define CONFIG_SETUP_MEMORY_TAGS #define CONFIG_CMDLINE_TAG
Signature · 1 line
1.7.5.4
PATCH v8 2/4 ARM: EXYNOS: Add support for Exynos5 based SoCs
In reply to Chander KashyapSamsung's ARM Cortex-A15 based SoCs are known as Exynos5 series of SoCs. This patch adds the support for Exynos5.
---
Changes for v2:
- This patch was part of "EXYNOS: Add SMDK5250 board support"
- Now it is seprated as SoC support.
Changes for v3:
- Populated complete exynos5 gpio structures
Changes for v4:
- Added dmc.h and tzpc.h header files
- Renamed EXYNOS5_PHY*_CTRL_BASE to EXYNOS5_DMC_PHY*_BASE
Changes for v5:
- None
Changes for v6:
- None
Changes for v7:
- None
Changes for v8:
- None
arch/arm/cpu/armv7/exynos/clock.c | 208 +++++++++++++++++++- arch/arm/include/asm/arch-exynos/clock.h | 326 ++++++++++++++++++++++++++++++ arch/arm/include/asm/arch-exynos/cpu.h | 35 +++- arch/arm/include/asm/arch-exynos/dmc.h | 146 +++++++++++++ arch/arm/include/asm/arch-exynos/gpio.h | 99 +++++++++- arch/arm/include/asm/arch-exynos/tzpc.h | 52 +++++ 6 files changed, 854 insertions(+), 12 deletions(-) create mode 100644 arch/arm/include/asm/arch-exynos/dmc.h create mode 100644 arch/arm/include/asm/arch-exynos/tzpc.h
arch/arm/cpu/armv7/exynos/clock.c +203 -5
@@ -92,6 +92,72 @@ static unsigned long exynos4_get_pll_clk(int pllreg)return fout; } +/* exynos5: return pll clock frequency */ +static unsigned long exynos5_get_pll_clk (int pllreg) +{ +struct exynos5_clock *clk = + (struct exynos5_clock *)samsung_get_base_clock (); +unsigned long r, m, p, s, k =0 , mask, fout; +unsigned int freq; + +switch (pllreg) { +case APLL : + r =readl (&clk->apll_con0); +break ; +case MPLL : + r =readl (&clk->mpll_con0); +break ; +case EPLL : + r =readl (&clk->epll_con0); + k =readl (&clk->epll_con1); +break ; +case VPLL : + r =readl (&clk->vpll_con0); + k =readl (&clk->vpll_con1); +break ; +default : +printf ("Unsupported PLL (%d)\n" , pllreg); +return 0 ; + } + +/* +* APLL_CON: MIDV [25:16] +* MPLL_CON: MIDV [25:16] +* EPLL_CON: MIDV [24:16] +* VPLL_CON: MIDV [24:16] +*/ +if (pllreg ==APLL || pllreg ==MPLL ) + mask =0x3ff ; +else + mask =0x1ff ; + + m = (r >>16 ) & mask; + +/* PDIV [13:8] */ + p = (r >>8 ) &0x3f ; +/* SDIV [2:0] */ + s = r &0x7 ; + + freq =CONFIG_SYS_CLK_FREQ ; + +if (pllreg ==EPLL ) { + k = k &0xffff ; +/* FOUT = (MDIV + K / 65536) * FIN / (PDIV * 2^SDIV) */ + fout = (m + k /65536 ) * (freq / (p * (1 << s))); + }else if (pllreg ==VPLL ) { + k = k &0xfff ; +/* FOUT = (MDIV + K / 1024) * FIN / (PDIV * 2^SDIV) */ + fout = (m + k /1024 ) * (freq / (p * (1 << s))); + }else { +if (s <1 ) + s =1 ; +/* FOUT = MDIV * FIN / (PDIV * 2^(SDIV - 1)) */ + fout = m * (freq / (p * (1 << (s -1 )))); + } + +return fout; +} +/* exynos4: return ARM clock frequency */ static unsigned long exynos4_get_arm_clk (void ) {
@@ -114,6 +180,28 @@ static unsigned long exynos4_get_arm_clk(void)return armclk; } +/* exynos5: return ARM clock frequency */ +static unsigned long exynos5_get_arm_clk (void ) +{ +struct exynos5_clock *clk = + (struct exynos5_clock *)samsung_get_base_clock (); +unsigned long div; +unsigned long armclk; +unsigned int arm_ratio; +unsigned int arm2_ratio; + + div =readl (&clk->div_cpu0); + +/* ARM_RATIO: [2:0], ARM2_RATIO: [30:28] */ + arm_ratio = (div >>0 ) &0x7 ; + arm2_ratio = (div >>28 ) &0x7 ; + + armclk =get_pll_clk (APLL ) / (arm_ratio +1 ); + armclk /= (arm2_ratio +1 ); + +return armclk; +} +/* exynos4: return pwm clock frequency */ static unsigned long exynos4_get_pwm_clk (void ) {
@@ -157,6 +245,27 @@ static unsigned long exynos4_get_pwm_clk(void)return pclk; } +/* exynos5: return pwm clock frequency */ +static unsigned long exynos5_get_pwm_clk (void ) +{ +struct exynos5_clock *clk = + (struct exynos5_clock *)samsung_get_base_clock (); +unsigned long pclk, sclk; +unsigned int ratio; + +/* +* CLK_DIV_PERIC3 +* PWM_RATIO [3:0] +*/ + ratio =readl (&clk->div_peric3); + ratio = ratio &0xf ; + sclk =get_pll_clk (MPLL ); + + pclk = sclk / (ratio +1 ); + +return pclk; +} +/* exynos4: return uart clock frequency */ static unsigned long exynos4_get_uart_clk (int dev_index) {
@@ -204,6 +313,53 @@ static unsigned long exynos4_get_uart_clk(int dev_index)return uclk; } +/* exynos5: return uart clock frequency */ +static unsigned long exynos5_get_uart_clk (int dev_index) +{ +struct exynos5_clock *clk = + (struct exynos5_clock *)samsung_get_base_clock (); +unsigned long uclk, sclk; +unsigned int sel; +unsigned int ratio; + +/* +* CLK_SRC_PERIC0 +* UART0_SEL [3:0] +* UART1_SEL [7:4] +* UART2_SEL [8:11] +* UART3_SEL [12:15] +* UART4_SEL [16:19] +* UART5_SEL [23:20] +*/ + sel =readl (&clk->src_peric0); + sel = (sel >> (dev_index <<2 )) &0xf ; + +if (sel ==0x6 ) + sclk =get_pll_clk (MPLL ); +else if (sel ==0x7 ) + sclk =get_pll_clk (EPLL ); +else if (sel ==0x8 ) + sclk =get_pll_clk (VPLL ); +else +return 0 ; + +/* +* CLK_DIV_PERIC0 +* UART0_RATIO [3:0] +* UART1_RATIO [7:4] +* UART2_RATIO [8:11] +* UART3_RATIO [12:15] +* UART4_RATIO [16:19] +* UART5_RATIO [23:20] +*/ + ratio =readl (&clk->div_peric0); + ratio = (ratio >> (dev_index <<2 )) &0xf ; + + uclk = sclk / (ratio +1 ); + +return uclk; +} +/* exynos4: set the mmc clock */ static void exynos4_set_mmc_clk (int dev_index,unsigned int div) {
@@ -231,27 +387,69 @@ static void exynos4_set_mmc_clk(int dev_index, unsigned int div)writel (val, addr); } +/* exynos5: set the mmc clock */ +static void exynos5_set_mmc_clk (int dev_index,unsigned int div) +{ +struct exynos5_clock *clk = + (struct exynos5_clock *)samsung_get_base_clock (); +unsigned int addr; +unsigned int val; + +/* +* CLK_DIV_FSYS1 +* MMC0_PRE_RATIO [15:8], MMC1_PRE_RATIO [31:24] +* CLK_DIV_FSYS2 +* MMC2_PRE_RATIO [15:8], MMC3_PRE_RATIO [31:24] +*/ +if (dev_index <2 ) { + addr = (unsigned int )&clk->div_fsys1; + }else { + addr = (unsigned int )&clk->div_fsys2; + dev_index -=2 ; + } + + val =readl (addr); + val &= ~(0xff << ((dev_index <<4 ) +8 )); + val |= (div &0xff ) << ((dev_index <<4 ) +8 ); +writel (val, addr); +} +unsigned long get_pll_clk (int pllreg) { -return exynos4_get_pll_clk (pllreg); +if (cpu_is_exynos5 ()) +return exynos5_get_pll_clk (pllreg); +else +return exynos4_get_pll_clk (pllreg); }unsigned long get_arm_clk (void ) { -return exynos4_get_arm_clk (); +if (cpu_is_exynos5 ()) +return exynos5_get_arm_clk (); +else +return exynos4_get_arm_clk (); }unsigned long get_pwm_clk (void ) { -return exynos4_get_pwm_clk (); +if (cpu_is_exynos5 ()) +return exynos5_get_pwm_clk (); +else +return exynos4_get_pwm_clk (); }unsigned long get_uart_clk (int dev_index) { -return exynos4_get_uart_clk (dev_index); +if (cpu_is_exynos5 ()) +return exynos5_get_uart_clk (dev_index); +else +return exynos4_get_uart_clk (dev_index); }void set_mmc_clk (int dev_index,unsigned int div) { -exynos4_set_mmc_clk (dev_index, div); +if (cpu_is_exynos5 ()) +exynos5_set_mmc_clk (dev_index, div); +else +exynos4_set_mmc_clk (dev_index, div); }
arch/arm/include/asm/arch-exynos/clock.h +326 -0
332 lines not on this page · raw message
arch/arm/include/asm/arch-exynos/cpu.h +34 -1
@@ -22,6 +22,8 @@#ifndef _EXYNOS4_CPU_H#define _EXYNOS4_CPU_H +#define DEVICE_NOT_AVAILABLE 0 +#define EXYNOS4_ADDR_BASE 0x10000000/* EXYNOS4 */
@@ -46,7 +48,34 @@#define EXYNOS4_ADC_BASE 0x13910000#define EXYNOS4_PWMTIMER_BASE 0x139D0000#define EXYNOS4_MODEM_BASE 0x13A00000 -#define EXYNOS4_USBPHY_CONTROL 0x10020704 +#define EXYNOS4_USBPHY_CONTROL 0x10020704 + +#define EXYNOS4_GPIO_PART4_BASE DEVICE_NOT_AVAILABLE + +/* EXYNOS5 */ +#define EXYNOS5_GPIO_PART4_BASE 0x03860000 +#define EXYNOS5_PRO_ID 0x10000000 +#define EXYNOS5_CLOCK_BASE 0x10010000 +#define EXYNOS5_POWER_BASE 0x10040000 +#define EXYNOS5_SWRESET 0x10040400 +#define EXYNOS5_SYSREG_BASE 0x10050000 +#define EXYNOS5_WATCHDOG_BASE 0x101D0000 +#define EXYNOS5_DMC_PHY0_BASE 0x10C00000 +#define EXYNOS5_DMC_PHY1_BASE 0x10C10000 +#define EXYNOS5_GPIO_PART3_BASE 0x10D10000 +#define EXYNOS5_DMC_CTRL_BASE 0x10DD0000 +#define EXYNOS5_GPIO_PART1_BASE 0x11400000 +#define EXYNOS5_MMC_BASE 0x12200000 +#define EXYNOS5_SROMC_BASE 0x12250000 +#define EXYNOS5_USBOTG_BASE 0x12480000 +#define EXYNOS5_USBPHY_BASE 0x12480000 +#define EXYNOS5_UART_BASE 0x12C00000 +#define EXYNOS5_PWMTIMER_BASE 0x12DD0000 +#define EXYNOS5_GPIO_PART2_BASE 0x13400000 +#define EXYNOS5_FIMD_BASE 0x14400000 + +#define EXYNOS5_ADC_BASE DEVICE_NOT_AVAILABLE +#define EXYNOS5_MODEM_BASE DEVICE_NOT_AVAILABLE#ifndef __ASSEMBLY__#include <asm/io.h>
@@ -83,12 +112,15 @@ static inline int cpu_is_##type(void) \ } IS_SAMSUNG_TYPE(exynos4, 0xc210) +IS_SAMSUNG_TYPE(exynos5, 0xc520)#define SAMSUNG_BASE (device, base) \ static inline unsigned int samsung_get_base_##device(void) \ { \ if (cpu_is_exynos4()) \ return EXYNOS4_##base; \ + else if (cpu_is_exynos5()) \ + return EXYNOS5_##base; \ else \ return 0; \ }
@@ -99,6 +131,7 @@ SAMSUNG_BASE(fimd, FIMD_BASE) SAMSUNG_BASE(gpio_part1, GPIO_PART1_BASE) SAMSUNG_BASE(gpio_part2, GPIO_PART2_BASE) SAMSUNG_BASE(gpio_part3, GPIO_PART3_BASE) +SAMSUNG_BASE(gpio_part4, GPIO_PART4_BASE) SAMSUNG_BASE(pro_id, PRO_ID) SAMSUNG_BASE(mmc, MMC_BASE)SAMSUNG_BASE (modem,MODEM_BASE )
arch/arm/include/asm/arch-exynos/dmc.h new file +146 -0
146 lines not on this page · raw message
arch/arm/include/asm/arch-exynos/gpio.h +93 -6
120 lines not on this page · raw message
arch/arm/include/asm/arch-exynos/tzpc.h new file +52 -0
52 lines not on this page · raw message
Signature · 1 line
1.7.5.4
PATCH v8 3/4 EXYNOS: Add SMDK5250 board support
In reply to Chander KashyapSMDK5250 board is based on Samsungs EXYNOS5250 SoC.
---
Changes for v2:
- This patch is bifurcated into borad support and SoC support
- Fixed typo: s/EEYNOS/EXYNOS
- Squashed patch "SMDK5250: enable device tree support" in this.
Changes for v3:
- None
Changes for v4:
- Converted assembly routines for clock, memory, uart and tzpc
- init to c functions
- Moved uart init to smdk5250.c
Changes for v5:
- Remove init of gpio1
- Fixed gpio configuration for uart
Changes for v6:
- Add gpio1 init in board_uart_init, which was removed in v5
Changes for v7:
- Converted magic numbers in dmc_init.c with macro defines
- Divided mem_ctrl_init() function in dmc_init.c in smaller modules.
- Removed init of all uarts except uart2 in smdk5250.c file.
- Removed values assigned for boolean defines.
- Removed back-slashes used for continuation in smdk5250.c
Changes for v8:
- cdrex config added in dmc_init.c
MAINTAINERS | 1 + board/samsung/smdk5250/Makefile | 51 ++++ board/samsung/smdk5250/clock_init.c | 202 ++++++++++++++ board/samsung/smdk5250/dmc_init.c | 462 ++++++++++++++++++++++++++++++++ board/samsung/smdk5250/lowlevel_init.S | 96 +++++++ board/samsung/smdk5250/setup.h | 451 +++++++++++++++++++++++++++++++ board/samsung/smdk5250/smdk5250.c | 146 ++++++++++ board/samsung/smdk5250/tzpc_init.c | 48 ++++ boards.cfg | 1 + include/configs/smdk5250.h | 190 +++++++++++++ 10 files changed, 1648 insertions(+), 0 deletions(-) create mode 100644 board/samsung/smdk5250/Makefile create mode 100644 board/samsung/smdk5250/clock_init.c create mode 100644 board/samsung/smdk5250/dmc_init.c create mode 100644 board/samsung/smdk5250/lowlevel_init.S create mode 100644 board/samsung/smdk5250/setup.h create mode 100644 board/samsung/smdk5250/smdk5250.c create mode 100644 board/samsung/smdk5250/tzpc_init.c create mode 100644 include/configs/smdk5250.h
MAINTAINERS +1 -0
@@ -713,6 +713,7 @@ Chander Kashyap <[email protected]> origen ARM ARMV7 (EXYNOS4210 SoC) SMDKV310 ARM ARMV7 (EXYNOS4210 SoC) + SMDK5250 ARM ARMV7 (EXYNOS5250 SoC) Heungjun Kim <[email protected]>
board/samsung/smdk5250/Makefile new file +51 -0
51 lines not on this page · raw message
board/samsung/smdk5250/clock_init.c new file +202 -0
202 lines not on this page · raw message
board/samsung/smdk5250/dmc_init.c new file +462 -0
462 lines not on this page · raw message
board/samsung/smdk5250/lowlevel_init.S new file +96 -0
96 lines not on this page · raw message
board/samsung/smdk5250/setup.h new file +451 -0
451 lines not on this page · raw message
board/samsung/smdk5250/smdk5250.c new file +146 -0
146 lines not on this page · raw message
board/samsung/smdk5250/tzpc_init.c new file +48 -0
48 lines not on this page · raw message
boards.cfg +1 -0
@@ -221,6 +221,7 @@ s5p_goni arm armv7 goni samsung smdkc100 arm armv7 smdkc100 samsung s5pc1xx origen arm armv7 origen samsung exynos s5pc210_universal arm armv7 universal_c210 samsung exynos +smdk5250 arm armv7 smdk5250 samsung exynos smdkv310 arm armv7 smdkv310 samsung exynos trats arm armv7 trats samsung exynos harmony arm armv7 harmony nvidia tegra2
include/configs/smdk5250.h new file +190 -0
190 lines not on this page · raw message
Signature · 1 line
1.7.5.4
PATCH v8 4/4 EXYNOS: SMDK5250: Add MMC SPL support
In reply to Chander KashyapThis patch adds support for MMC SPL booting.
---
Changes for v2:
- None
Changes for v3:
- None
Changes for v4:
- None
Changes for v5:
- None
Changes for v6:
- None
Changes for v7:
- None
Changes for v8:
- Moved $BOARD/tools/mkexynos_image.c to tools/mksmdk5250spl.c
- Incorporated Mike's review comments
board/samsung/smdk5250/Makefile | 16 ++++ board/samsung/smdk5250/mmc_boot.c | 58 ++++++++++++ board/samsung/smdk5250/tools/mkexynos_image.c | 117 +++++++++++++++++++++++++ include/configs/smdk5250.h | 7 ++ 4 files changed, 198 insertions(+), 0 deletions(-) create mode 100644 board/samsung/smdk5250/mmc_boot.c create mode 100644 tools/mksmdk5250spl.c
board/samsung/smdk5250/Makefile +7 -0
@@ -29,7 +29,14 @@ SOBJS := lowlevel_init.o COBJS := clock_init.o COBJS += dmc_init.o COBJS += tzpc_init.o + +ifndef CONFIG_SPL_BUILD COBJS += smdk5250.o +endif + +ifdef CONFIG_SPL_BUILD +COBJS += mmc_boot.o +endif SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c) OBJS := $(addprefix $(obj),$(COBJS) $(SOBJS))
board/samsung/smdk5250/mmc_boot.c new file +58 -0
58 lines not on this page · raw message
include/configs/smdk5250.h +7 -0
@@ -102,6 +102,10 @@#define CONFIG_BOOTDELAY 3#define CONFIG_ZERO_BOOTDELAY_CHECK +/* MMC SPL */ +#define CONFIG_SPL +#define COPY_BL2_FNPTR_ADDR 0x02020030 +#define CONFIG_BOOTCOMMAND "mmc read 40007000 451 2000; bootm 40007000"/* Miscellaneous configurable options */
@@ -178,6 +182,9 @@#define CONFIG_BL2_OFFSET (CONFIG_BL1_OFFSET + CONFIG_BL1_SIZE)#define CONFIG_ENV_OFFSET (CONFIG_BL2_OFFSET + CONFIG_BL2_SIZE) +/* U-boot copy size from boot Media to DRAM.*/ +#define BL2_START_OFFSET (CONFIG_BL2_OFFSET/512) +#define BL2_SIZE_BLOC_COUNT (CONFIG_BL2_SIZE/512)#define CONFIG_DOS_PARTITION #define CONFIG_IRAM_STACK 0x02050000
tools/Makefile +6 -0
@@ -68,6 +68,7 @@ BIN_FILES-$(CONFIG_CMD_LOADS) += img2srec$(SFX) BIN_FILES-$(CONFIG_XWAY_SWAP_BYTES) += xway-swap-bytes$(SFX) BIN_FILES-y += mkenvimage$(SFX) BIN_FILES-y += mkimage$(SFX) +BIN_FILES-$(CONFIG_SMDK5250) += mksmdk5250spl$(SFX) BIN_FILES-$(CONFIG_MX28) += mxsboot$(SFX) BIN_FILES-$(CONFIG_NETCONSOLE) += ncb$(SFX) BIN_FILES-$(CONFIG_SHA1_CHECK_UB_IMG) += ubsha1$(SFX)
@@ -94,6 +95,7 @@ NOPED_OBJ_FILES-y += imximage.o NOPED_OBJ_FILES-y += omapimage.o NOPED_OBJ_FILES-y += mkenvimage.o NOPED_OBJ_FILES-y += mkimage.o +OBJ_FILES-$(CONFIG_SMDK5250) += mksmdk5250spl.o OBJ_FILES-$(CONFIG_MX28) += mxsboot.o OBJ_FILES-$(CONFIG_NETCONSOLE) += ncb.o NOPED_OBJ_FILES-y += os_support.o
@@ -213,6 +215,10 @@ $(obj)mkimage$(SFX): $(obj)aisimage.o \ $(HOSTCC) $(HOSTCFLAGS) $(HOSTLDFLAGS) -o $@ $^ $(HOSTSTRIP) $@ +$(obj)mksmdk5250spl$(SFX): $(obj)mksmdk5250spl.o + $(HOSTCC) $(HOSTCFLAGS) $(HOSTLDFLAGS) -o $@ $^ + $(HOSTSTRIP) $@ + $(obj)mpc86x_clk$(SFX): $(obj)mpc86x_clk.o $(HOSTCC) $(HOSTCFLAGS) $(HOSTLDFLAGS) -o $@ $^ $(HOSTSTRIP) $@
tools/mksmdk5250spl.c new file +119 -0
119 lines not on this page · raw message
Signature · 1 line
1.7.5.4
PATCH v8 4/4 EXYNOS: SMDK5250: Add MMC SPL support
Quoted 2 lines · On Friday 03 February 2012 11:05:57 Chander Kashyap wrote:
board/samsung/smdk5250/tools/mkexynos_image.c | 117 create mode 100644 tools/mksmdk5250spl.c
something funky in your diffstat ... says you're creating tools/ but the diffstat shows board/.../tools/. but the diff below looks correct.
tools/mksmdk5250spl.c
Quoted 2 lines
tools/mksmdk5250spl.c new file +0
-0
you could still name it "mkexynos_image". up to you.
tools/mksmdk5250spl.c line 82
Quoted 4 lines
tools/mksmdk5250spl.c new file +4
-0+if (fstat (ifd, &stat)) { +close (ifd); +close (ofd); + }
looks like you should issue a warning + exit here
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20120203/6cc939af/attachment.pgp>
PATCH v8 4/4 EXYNOS: SMDK5250: Add MMC SPL support
Hi,
As there are no changes in other patches. So is it fine to only send this patch.
Quoted 19 lines · Mike Frysinger
Quoted 2 lines · On Friday 03 February 2012 11:05:57 Chander Kashyap wrote:
?board/samsung/smdk5250/tools/mkexynos_image.c | ?117 ?create mode 100644
tools/mksmdk5250spl.csomething funky in your diffstat ... says you're creating
tools/but the diffstat shows board/.../tools/. ?but the diff below looks correct.tools/mksmdk5250spl.c
Quoted 2 lines
tools/mksmdk5250spl.c new file +0
-0you could still name it "
mkexynos_image". ?up to you.Quoted 4 lines
+ ? ? if (
fstat(ifd, &stat)) {
+ ? ? ? ? ? ? close(ifd);
+ ? ? ? ? ? ? close(ofd);
+ ? ? }looks like you should issue a warning + exit here
-mike
Signature · 2 lines
with warm regards, Chander Kashyap