aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--arch/arm/dts/exynos4210-pinctrl-uboot.dtsi4
-rw-r--r--arch/arm/dts/exynos4210-universal_c210.dts2
-rw-r--r--arch/arm/dts/exynos4x12-pinctrl-uboot.dtsi4
-rw-r--r--arch/arm/dts/exynos5.dtsi2
-rw-r--r--arch/arm/dts/exynos5250-pinctrl-uboot.dtsi4
-rw-r--r--arch/arm/dts/exynos5250-spring.dts2
-rw-r--r--arch/arm/dts/exynos54xx-pinctrl-uboot.dtsi8
-rw-r--r--board/samsung/common/bootscripts/autoboot.cmd6
-rw-r--r--board/samsung/smdk5420/MAINTAINERS1
-rw-r--r--configs/odroid-xu3_defconfig3
-rw-r--r--drivers/mmc/exynos_dw_mmc.c37
-rw-r--r--include/configs/exynos5-common.h1
-rw-r--r--include/configs/odroid.h36
-rw-r--r--include/configs/snow.h3
14 files changed, 51 insertions, 62 deletions
diff --git a/arch/arm/dts/exynos4210-pinctrl-uboot.dtsi b/arch/arm/dts/exynos4210-pinctrl-uboot.dtsi
index ba0fd4d2cd5..aeeecd6283b 100644
--- a/arch/arm/dts/exynos4210-pinctrl-uboot.dtsi
+++ b/arch/arm/dts/exynos4210-pinctrl-uboot.dtsi
@@ -7,8 +7,6 @@
/{
pinctrl_0: pinctrl@11400000 {
- #address-cells = <1>;
- #size-cells = <1>;
compatible = "samsung,exynos4210-pinctrl";
};
@@ -21,8 +19,6 @@
};
pinctrl_2: pinctrl@03860000 {
- #address-cells = <1>;
- #size-cells = <1>;
};
};
diff --git a/arch/arm/dts/exynos4210-universal_c210.dts b/arch/arm/dts/exynos4210-universal_c210.dts
index 59ea5a633e4..610a8ad2e71 100644
--- a/arch/arm/dts/exynos4210-universal_c210.dts
+++ b/arch/arm/dts/exynos4210-universal_c210.dts
@@ -25,8 +25,6 @@
gpio-mosi = <&gpy3 3 0>;
gpio-miso = <&gpy3 0 0>;
spi-delay-us = <1>;
- #address-cells = <1>;
- #size-cells = <0>;
cs@0 {
};
};
diff --git a/arch/arm/dts/exynos4x12-pinctrl-uboot.dtsi b/arch/arm/dts/exynos4x12-pinctrl-uboot.dtsi
index 7409e76a599..955e14ef8f5 100644
--- a/arch/arm/dts/exynos4x12-pinctrl-uboot.dtsi
+++ b/arch/arm/dts/exynos4x12-pinctrl-uboot.dtsi
@@ -32,13 +32,9 @@
};
pinctrl_2: pinctrl@03860000 {
- #address-cells = <1>;
- #size-cells = <1>;
};
pinctrl_3: pinctrl@106E0000 {
- #address-cells = <1>;
- #size-cells = <1>;
};
};
diff --git a/arch/arm/dts/exynos5.dtsi b/arch/arm/dts/exynos5.dtsi
index 6102978aa41..cdc965d90da 100644
--- a/arch/arm/dts/exynos5.dtsi
+++ b/arch/arm/dts/exynos5.dtsi
@@ -147,8 +147,6 @@
dp: dp@145b0000 {
compatible = "samsung,exynos5-dp";
reg = <0x145b0000 0x1000>;
- #address-cells = <1>;
- #size-cells = <1>;
};
xhci0: xhci@12000000 {
diff --git a/arch/arm/dts/exynos5250-pinctrl-uboot.dtsi b/arch/arm/dts/exynos5250-pinctrl-uboot.dtsi
index f19ce47b412..b4148053199 100644
--- a/arch/arm/dts/exynos5250-pinctrl-uboot.dtsi
+++ b/arch/arm/dts/exynos5250-pinctrl-uboot.dtsi
@@ -18,8 +18,6 @@
};
pinctrl_1: pinctrl@13400000 {
- #address-cells = <1>;
- #size-cells = <1>;
};
pinctrl_2: pinctrl@10d10000 {
@@ -34,8 +32,6 @@
};
pinctrl_3: pinctrl@03860000 {
- #address-cells = <1>;
- #size-cells = <1>;
};
};
diff --git a/arch/arm/dts/exynos5250-spring.dts b/arch/arm/dts/exynos5250-spring.dts
index b73b572e623..7633d36874f 100644
--- a/arch/arm/dts/exynos5250-spring.dts
+++ b/arch/arm/dts/exynos5250-spring.dts
@@ -31,7 +31,7 @@
spi2 = "/spi@12d40000";
spi3 = "/spi@131a0000";
spi4 = "/spi@131b0000";
- mmc0 = "/mmc@12000000";
+ mmc0 = "/mmc@12200000";
serial0 = "/serial@12C30000";
console = "/serial@12C30000";
i2s = "/sound@3830000";
diff --git a/arch/arm/dts/exynos54xx-pinctrl-uboot.dtsi b/arch/arm/dts/exynos54xx-pinctrl-uboot.dtsi
index 72653876392..4fcbe71fe5a 100644
--- a/arch/arm/dts/exynos54xx-pinctrl-uboot.dtsi
+++ b/arch/arm/dts/exynos54xx-pinctrl-uboot.dtsi
@@ -12,8 +12,6 @@
* numbers are not needed in U-Boot for exynos.
*/
pinctrl@14010000 {
- #address-cells = <1>;
- #size-cells = <1>;
};
pinctrl@13400000 {
#address-cells = <1>;
@@ -26,16 +24,10 @@
};
};
pinctrl@13410000 {
- #address-cells = <1>;
- #size-cells = <1>;
};
pinctrl@14000000 {
- #address-cells = <1>;
- #size-cells = <1>;
};
pinctrl@03860000 {
- #address-cells = <1>;
- #size-cells = <1>;
};
};
diff --git a/board/samsung/common/bootscripts/autoboot.cmd b/board/samsung/common/bootscripts/autoboot.cmd
index 1faed8ba0c1..11c724c4e09 100644
--- a/board/samsung/common/bootscripts/autoboot.cmd
+++ b/board/samsung/common/bootscripts/autoboot.cmd
@@ -74,15 +74,15 @@ setenv boot_img "
#### Routine: autoboot - choose proper boot path
setenv autoboot "
-if test -e mmc 0:${mmcbootpart} Image.itb; then
+if test -e mmc ${mmcbootdev}:${mmcbootpart} Image.itb; then
echo Found kernel image: Image.itb;
run setboot_fit;
run boot_img;
-elif test -e mmc 0:${mmcbootpart} zImage; then
+elif test -e mmc ${mmcbootdev}:${mmcbootpart} zImage; then
echo Found kernel image: zImage;
run setboot_zimg;
run boot_img;
-elif test -e mmc 0:${mmcbootpart} uImage; then
+elif test -e mmc ${mmcbootdev}:${mmcbootpart} uImage; then
echo Found kernel image: uImage;
run setboot_uimg;
run boot_img;
diff --git a/board/samsung/smdk5420/MAINTAINERS b/board/samsung/smdk5420/MAINTAINERS
index 590a1140b07..31c00360f28 100644
--- a/board/samsung/smdk5420/MAINTAINERS
+++ b/board/samsung/smdk5420/MAINTAINERS
@@ -11,6 +11,7 @@ F: configs/peach-pi_defconfig
ODROID-XU3 BOARD
M: Jaehoon Chung <jh80.chung@samsung.com>
+M: Lukasz Majewski <lukma@denx.de>
S: Maintained
F: board/samsung/smdk5420/
F: include/configs/odroid_xu3.h
diff --git a/configs/odroid-xu3_defconfig b/configs/odroid-xu3_defconfig
index 5943c19cf9b..632542d9842 100644
--- a/configs/odroid-xu3_defconfig
+++ b/configs/odroid-xu3_defconfig
@@ -29,9 +29,8 @@ CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
CONFIG_ADC=y
CONFIG_ADC_EXYNOS=y
CONFIG_DFU_MMC=y
+CONFIG_DM_MMC=y
CONFIG_MMC_DW=y
-CONFIG_MMC_SDHCI=y
-CONFIG_MMC_SDHCI_S5P=y
CONFIG_NETDEVICES=y
CONFIG_SMC911X=y
CONFIG_SMC911X_BASE=0x5000000
diff --git a/drivers/mmc/exynos_dw_mmc.c b/drivers/mmc/exynos_dw_mmc.c
index 865fdf4dbba..435ccac5942 100644
--- a/drivers/mmc/exynos_dw_mmc.c
+++ b/drivers/mmc/exynos_dw_mmc.c
@@ -46,8 +46,12 @@ struct dwmci_exynos_priv_data {
*/
static void exynos_dwmci_clksel(struct dwmci_host *host)
{
+#ifdef CONFIG_DM_MMC
+ struct dwmci_exynos_priv_data *priv =
+ container_of(host, struct dwmci_exynos_priv_data, host);
+#else
struct dwmci_exynos_priv_data *priv = host->priv;
-
+#endif
dwmci_writel(host, DWMCI_CLKSEL, priv->sdr_timing);
}
@@ -146,17 +150,11 @@ static int do_dwmci_init(struct dwmci_host *host)
}
static int exynos_dwmci_get_config(const void *blob, int node,
- struct dwmci_host *host)
+ struct dwmci_host *host,
+ struct dwmci_exynos_priv_data *priv)
{
int err = 0;
u32 base, timing[3];
- struct dwmci_exynos_priv_data *priv;
-
- priv = malloc(sizeof(struct dwmci_exynos_priv_data));
- if (!priv) {
- pr_err("dwmci_exynos_priv_data malloc fail!\n");
- return -ENOMEM;
- }
/* Extract device id for each mmc channel */
host->dev_id = pinmux_decode_periph_id(blob, node);
@@ -167,7 +165,6 @@ static int exynos_dwmci_get_config(const void *blob, int node,
if (host->dev_index > 4) {
printf("DWMMC%d: Can't get the dev index\n", host->dev_index);
- free(priv);
return -EINVAL;
}
@@ -178,7 +175,6 @@ static int exynos_dwmci_get_config(const void *blob, int node,
base = fdtdec_get_addr(blob, node, "reg");
if (!base) {
printf("DWMMC%d: Can't get base address\n", host->dev_index);
- free(priv);
return -EINVAL;
}
host->ioaddr = (void *)base;
@@ -188,7 +184,6 @@ static int exynos_dwmci_get_config(const void *blob, int node,
if (err) {
printf("DWMMC%d: Can't get sdr-timings for devider\n",
host->dev_index);
- free(priv);
return -EINVAL;
}
@@ -208,14 +203,13 @@ static int exynos_dwmci_get_config(const void *blob, int node,
host->bus_hz = fdtdec_get_int(blob, node, "bus_hz", 0);
host->div = fdtdec_get_int(blob, node, "div", 0);
- host->priv = priv;
-
return 0;
}
static int exynos_dwmci_process_node(const void *blob,
int node_list[], int count)
{
+ struct dwmci_exynos_priv_data *priv;
struct dwmci_host *host;
int i, node, err;
@@ -224,11 +218,20 @@ static int exynos_dwmci_process_node(const void *blob,
if (node <= 0)
continue;
host = &dwmci_host[i];
- err = exynos_dwmci_get_config(blob, node, host);
+
+ priv = malloc(sizeof(struct dwmci_exynos_priv_data));
+ if (!priv) {
+ pr_err("dwmci_exynos_priv_data malloc fail!\n");
+ return -ENOMEM;
+ }
+
+ err = exynos_dwmci_get_config(blob, node, host, priv);
if (err) {
printf("%s: failed to decode dev %d\n", __func__, i);
+ free(priv);
return err;
}
+ host->priv = priv;
do_dwmci_init(host);
}
@@ -266,7 +269,8 @@ static int exynos_dwmmc_probe(struct udevice *dev)
struct dwmci_host *host = &priv->host;
int err;
- err = exynos_dwmci_get_config(gd->fdt_blob, dev_of_offset(dev), host);
+ err = exynos_dwmci_get_config(gd->fdt_blob, dev_of_offset(dev), host,
+ priv);
if (err)
return err;
err = do_dwmci_init(host);
@@ -291,6 +295,7 @@ static int exynos_dwmmc_bind(struct udevice *dev)
static const struct udevice_id exynos_dwmmc_ids[] = {
{ .compatible = "samsung,exynos4412-dw-mshc" },
+ { .compatible = "samsung,exynos-dwmmc" },
{ }
};
diff --git a/include/configs/exynos5-common.h b/include/configs/exynos5-common.h
index a7621fc701b..cd2a9046afe 100644
--- a/include/configs/exynos5-common.h
+++ b/include/configs/exynos5-common.h
@@ -138,6 +138,7 @@
#define BOOT_TARGET_DEVICES(func) \
func(MMC, mmc, 1) \
func(MMC, mmc, 0) \
+ func(MMC, mmc, 2) \
func(PXE, pxe, na) \
func(DHCP, dhcp, na)
diff --git a/include/configs/odroid.h b/include/configs/odroid.h
index 92811cfc548..67a790ef02f 100644
--- a/include/configs/odroid.h
+++ b/include/configs/odroid.h
@@ -41,7 +41,7 @@
/* Console configuration */
-#define CONFIG_BOOTCOMMAND "run autoboot"
+#define CONFIG_BOOTCOMMAND "run distro_bootcmd ; run autoboot"
#define CONFIG_DEFAULT_CONSOLE "ttySAC1,115200n8"
#define CONFIG_SYS_INIT_SP_ADDR (CONFIG_SYS_LOAD_ADDR \
@@ -50,7 +50,7 @@
#define CONFIG_SYS_MONITOR_BASE 0x00000000
#define CONFIG_SYS_MMC_ENV_DEV CONFIG_MMC_DEFAULT_DEV
-#define CONFIG_ENV_SIZE 4096
+#define CONFIG_ENV_SIZE SZ_16K
#define CONFIG_ENV_OFFSET (SZ_1K * 1280) /* 1.25 MiB offset */
#define CONFIG_ENV_OVERWRITE
@@ -83,6 +83,12 @@
"bl2 raw 0x1f 0x1d;" \
"tzsw raw 0x83f 0x138\0"
+#define BOOT_TARGET_DEVICES(func) \
+ func(MMC, mmc, 1) \
+ func(MMC, mmc, 0)
+
+#include <config_distro_bootcmd.h>
+
/*
* Bootable media layout:
* dev: SD eMMC(part boot)
@@ -100,21 +106,21 @@
#define CONFIG_EXTRA_ENV_SETTINGS \
"loadbootscript=load mmc ${mmcbootdev}:${mmcbootpart} ${scriptaddr} " \
"boot.scr\0" \
- "loadkernel=load mmc ${mmcbootdev}:${mmcbootpart} ${kerneladdr} " \
+ "loadkernel=load mmc ${mmcbootdev}:${mmcbootpart} ${kernel_addr_r} " \
"${kernelname}\0" \
- "loadinitrd=load mmc ${mmcbootdev}:${mmcbootpart} ${initrdaddr} " \
+ "loadinitrd=load mmc ${mmcbootdev}:${mmcbootpart} ${ramdisk_addr_r} " \
"${initrdname}\0" \
- "loaddtb=load mmc ${mmcbootdev}:${mmcbootpart} ${fdtaddr} " \
+ "loaddtb=load mmc ${mmcbootdev}:${mmcbootpart} ${fdt_addr_r} " \
"${fdtfile}\0" \
"check_ramdisk=" \
"if run loadinitrd; then " \
- "setenv initrd_addr ${initrdaddr};" \
+ "setenv initrd_addr ${ramdisk_addr_r};" \
"else " \
"setenv initrd_addr -;" \
"fi;\0" \
"check_dtb=" \
"if run loaddtb; then " \
- "setenv fdt_addr ${fdtaddr};" \
+ "setenv fdt_addr ${fdt_addr_r};" \
"else " \
"setenv fdt_addr;" \
"fi;\0" \
@@ -125,27 +131,24 @@
"run loadbootscript;" \
"source ${scriptaddr}\0" \
"boot_fit=" \
- "setenv kerneladdr 0x42000000;" \
"setenv kernelname Image.itb;" \
"run loadkernel;" \
"run kernel_args;" \
- "bootm ${kerneladdr}#${boardname}\0" \
+ "bootm ${kernel_addr_r}#${boardname}\0" \
"boot_uimg=" \
- "setenv kerneladdr 0x40007FC0;" \
"setenv kernelname uImage;" \
"run check_dtb;" \
"run check_ramdisk;" \
"run loadkernel;" \
"run kernel_args;" \
- "bootm ${kerneladdr} ${initrd_addr} ${fdt_addr};\0" \
+ "bootm ${kernel_addr_r} ${initrd_addr} ${fdt_addr};\0" \
"boot_zimg=" \
- "setenv kerneladdr 0x40007FC0;" \
"setenv kernelname zImage;" \
"run check_dtb;" \
"run check_ramdisk;" \
"run loadkernel;" \
"run kernel_args;" \
- "bootz ${kerneladdr} ${initrd_addr} ${fdt_addr};\0" \
+ "bootz ${kernel_addr_r} ${initrd_addr} ${fdt_addr};\0" \
"autoboot=" \
"if test -e mmc 0 boot.scr; then; " \
"run boot_script; " \
@@ -161,15 +164,16 @@
"mmcbootpart=1\0" \
"mmcrootdev=0\0" \
"mmcrootpart=2\0" \
- "bootdelay=0\0" \
"dfu_alt_system="CONFIG_DFU_ALT \
"dfu_alt_info=Please reset the board\0" \
"consoleon=set console console=ttySAC1,115200n8; save; reset\0" \
"consoleoff=set console console=ram; save; reset\0" \
"initrdname=uInitrd\0" \
- "initrdaddr=42000000\0" \
+ "ramdisk_addr_r=0x42000000\0" \
"scriptaddr=0x42000000\0" \
- "fdtaddr=40800000\0"
+ "fdt_addr_r=0x40800000\0" \
+ "kernel_addr_r=0x41000000\0" \
+ BOOTENV
/* GPT */
diff --git a/include/configs/snow.h b/include/configs/snow.h
index 3b0db32ece5..c546a5a6d07 100644
--- a/include/configs/snow.h
+++ b/include/configs/snow.h
@@ -8,6 +8,9 @@
#ifndef __CONFIG_SNOW_H
#define __CONFIG_SNOW_H
+#define EXYNOS_FDTFILE_SETTING \
+ "fdtfile=exynos5250-snow.dtb\0"
+
#include <configs/exynos5250-common.h>
#include <configs/exynos5-dt-common.h>
#include <configs/exynos5-common.h>