blob: c148757915a2b01dd316355ac2d67e67727911d9 [file] [log] [blame]
Tom Rini83d290c2018-05-06 17:58:06 -04001/* SPDX-License-Identifier: GPL-2.0+ */
Minkyu Kang8bc4ee92009-10-01 17:20:40 +09002/*
3 * (C) Copyright 2009 Samsung Electronics
4 * Minkyu Kang <mk7.kang@samsung.com>
5 * HeungJun Kim <riverful.kim@samsung.com>
6 * Inki Dae <inki.dae@samsung.com>
7 *
8 * Configuation settings for the SAMSUNG SMDKC100 board.
Minkyu Kang8bc4ee92009-10-01 17:20:40 +09009 */
10
11#ifndef __CONFIG_H
12#define __CONFIG_H
13
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090014#include <asm/arch/cpu.h> /* get chip and board defs */
15
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090016/* input clock of PLL: SMDKC100 has 12MHz input clock */
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090017
18/* DRAM Base */
Tom Riniaa6e94d2022-11-16 13:10:37 -050019#define CFG_SYS_SDRAM_BASE 0x30000000
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090020
Minkyu Kang08bcbc42013-08-06 20:57:03 +090021/* Text Base */
Minkyu Kang08bcbc42013-08-06 20:57:03 +090022
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090023/*
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090024 * select serial console configuration
25 */
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090026
Tom Rini428eb2e2022-03-30 18:07:16 -040027#define COMMON_BOOT "console=ttySAC0,115200n8" \
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090028 " mem=128M " \
Tom Rini43ede0b2017-10-22 17:55:07 -040029 " " CONFIG_MTDPARTS_DEFAULT
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090030
Tom Rini0613c362022-12-04 10:03:50 -050031#define CFG_EXTRA_ENV_SETTINGS \
Tom Rini428eb2e2022-03-30 18:07:16 -040032 "updateb=" \
33 "onenand erase 0x0 0x40000;" \
34 "onenand write 0x32008000 0x0 0x40000\0" \
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090035 "updatek=" \
36 "onenand erase 0x60000 0x300000;" \
37 "onenand write 0x31008000 0x60000 0x300000\0" \
38 "updateu=" \
39 "onenand erase block 147-4095;" \
40 "onenand write 0x32000000 0x1260000 0x8C0000\0" \
41 "bootk=" \
42 "onenand read 0x30007FC0 0x60000 0x300000;" \
43 "bootm 0x30007FC0\0" \
44 "flashboot=" \
45 "set bootargs root=/dev/mtdblock${bootblock} " \
46 "rootfstype=${rootfstype} " \
Tom Rini428eb2e2022-03-30 18:07:16 -040047 "ubi.mtd=${ubiblock} ${opts} " COMMON_BOOT ";" \
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090048 "run bootk\0" \
49 "ubifsboot=" \
50 "set bootargs root=ubi0!rootfs rootfstype=ubifs " \
Tom Rini428eb2e2022-03-30 18:07:16 -040051 " ubi.mtd=${ubiblock} ${opts} " COMMON_BOOT "; " \
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090052 "run bootk\0" \
53 "boottrace=setenv opts initcall_debug; run bootcmd\0" \
54 "android=" \
55 "set bootargs root=ubi0!ramdisk ubi.mtd=${ubiblock} " \
Tom Rini428eb2e2022-03-30 18:07:16 -040056 "rootfstype=ubifs init=/init.sh " COMMON_BOOT "; " \
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090057 "run bootk\0" \
58 "nfsboot=" \
59 "set bootargs root=/dev/nfs ubi.mtd=${ubiblock} " \
60 "nfsroot=${nfsroot},nolock " \
61 "ip=${ipaddr}:${serverip}:${gatewayip}:" \
Tom Rini428eb2e2022-03-30 18:07:16 -040062 "${netmask}:nowplus:usb0:off " COMMON_BOOT "; " \
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090063 "run bootk\0" \
64 "ramboot=" \
Tom Rini428eb2e2022-03-30 18:07:16 -040065 "set bootargs root=/dev/ram0 rw rootfstype=ext2" \
66 " console=ttySAC0,115200n8 mem=128M" \
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090067 " initrd=0x33000000,8M ramdisk=8192\0" \
68 "rootfstype=cramfs\0" \
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090069 "meminfo=mem=128M\0" \
70 "nfsroot=/nfsroot/arm\0" \
71 "bootblock=5\0" \
72 "ubiblock=4\0" \
73 "ubi=enabled"
74
75/*
76 * Miscellaneous configurable options
77 */
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090078
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090079/* SMDKC100 has 1 banks of DRAM, we use only one in U-Boot */
Tom Riniaa6e94d2022-11-16 13:10:37 -050080#define PHYS_SDRAM_1 CFG_SYS_SDRAM_BASE /* SDRAM Bank #1 */
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090081#define PHYS_SDRAM_1_SIZE (128 << 20) /* 0x8000000, 128 MB Bank #1 */
82
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090083/*-----------------------------------------------------------------------
84 * FLASH and environment organization
85 */
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090086
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090087/*-----------------------------------------------------------------------
88 * Boot configuration
89 */
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090090
Tom Rini65cc0e22022-11-16 13:10:41 -050091#define CFG_SYS_ONENAND_BASE 0xE7100000
Minkyu Kang8bc4ee92009-10-01 17:20:40 +090092
Naveen Krishna CH2528dc52010-03-05 17:16:05 +090093/*
94 * Ethernet Contoller driver
95 */
96#ifdef CONFIG_CMD_NET
Tom Rini3673a472022-12-04 10:03:46 -050097#define CFG_ENV_SROM_BANK 3 /* Select SROM Bank-3 for Ethernet*/
Naveen Krishna CH2528dc52010-03-05 17:16:05 +090098#endif /* CONFIG_CMD_NET */
99
Minkyu Kang8bc4ee92009-10-01 17:20:40 +0900100#endif /* __CONFIG_H */