[U-Boot] [PATCH v5 0/3] ARMV7: Exynos4: Add support for TRATS board

2012-01-16 Thread HeungJun, Kim
This patch series support for Samsung TRATS board, and add the headers of
watchdog and power, and current version is 4.

I missed logs of v2 on this thread, so I'm going to add this:
http://lists.denx.de/pipermail/u-boot/2012-January/114857.html

Also, this patch is tested on Samsung TRATS board.

Thank you.

Best Regards,
 Heungjun Kim

HeungJun, Kim (3):
  ARMV7: Exynos4: Add watchdog.h for Exynos4
  ARMV7: Exynos4: Add supoort power for Exynos4
  ARMV7: Exynos4: Add support for TRATS board

 MAINTAINERS |4 +
 arch/arm/include/asm/arch-exynos/cpu.h  |1 +
 arch/arm/include/asm/arch-exynos/power.h|  230 ++
 arch/arm/include/asm/arch-exynos/watchdog.h |   53 +++
 board/samsung/trats/Makefile|   43 ++
 board/samsung/trats/setup.h |  637 +++
 board/samsung/trats/trats.c |  379 
 boards.cfg  |1 +
 include/configs/trats.h |  216 +
 9 files changed, 1564 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-exynos/power.h
 create mode 100644 arch/arm/include/asm/arch-exynos/watchdog.h
 create mode 100644 board/samsung/trats/Makefile
 create mode 100644 board/samsung/trats/setup.h
 create mode 100644 board/samsung/trats/trats.c
 create mode 100644 include/configs/trats.h

-- 
1.7.4.1

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH v5 2/3] ARMV7: Exynos4: Add supoort power for Exynos4

2012-01-16 Thread HeungJun, Kim
This patch adds power.h and SAMSUNG_BASE() macro for using Exynos4 power.

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
Changes for v3:
   - Created

Changes for v4:
   - Not changed

Changes for v5:
   - Not changed

 arch/arm/include/asm/arch-exynos/cpu.h   |1 +
 arch/arm/include/asm/arch-exynos/power.h |  230 ++
 2 files changed, 231 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-exynos/power.h

diff --git a/arch/arm/include/asm/arch-exynos/cpu.h 
b/arch/arm/include/asm/arch-exynos/cpu.h
index 6d97b99..3496616 100644
--- a/arch/arm/include/asm/arch-exynos/cpu.h
+++ b/arch/arm/include/asm/arch-exynos/cpu.h
@@ -109,6 +109,7 @@ SAMSUNG_BASE(uart, UART_BASE)
 SAMSUNG_BASE(usb_phy, USBPHY_BASE)
 SAMSUNG_BASE(usb_otg, USBOTG_BASE)
 SAMSUNG_BASE(watchdog, WATCHDOG_BASE)
+SAMSUNG_BASE(power, POWER_BASE)
 #endif
 
 #endif /* _EXYNOS4_CPU_H */
diff --git a/arch/arm/include/asm/arch-exynos/power.h 
b/arch/arm/include/asm/arch-exynos/power.h
new file mode 100644
index 000..fb442f7
--- /dev/null
+++ b/arch/arm/include/asm/arch-exynos/power.h
@@ -0,0 +1,230 @@
+/*
+ * Copyright (C) 2011 Samsung Electronics
+ * Heungjun Kim riverful@samsung.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
+ */
+
+#ifndef __ASM_ARM_ARCH_POWER_H_
+#define __ASM_ARM_ARCH_POWER_H_
+
+#ifndef __ASSEMBLY__
+struct exynos4_power {
+   unsigned intom_stat;
+   unsigned char   res1[0x8];
+   unsigned intrtc_clko_sel;
+   unsigned intgnss_rtc_out_ctrl;
+   unsigned char   res2[0x1ec];
+   unsigned intsystem_power_down_ctrl;
+   unsigned char   res3[0x1];
+   unsigned intsystem_power_down_option;
+   unsigned char   res4[0x1f4];
+   unsigned intswreset;
+   unsigned intrst_stat;
+   unsigned char   res5[0x1f8];
+   unsigned intwakeup_stat;
+   unsigned inteint_wakeup_mask;
+   unsigned intwakeup_mask;
+   unsigned char   res6[0xf4];
+   unsigned inthdmi_phy_control;
+   unsigned intusbdevice_phy_control;
+   unsigned intusbhost_phy_control;
+   unsigned intdac_phy_control;
+   unsigned intmipi_phy0_control;
+   unsigned intmipi_phy1_control;
+   unsigned intadc_phy_control;
+   unsigned intpcie_phy_control;
+   unsigned intsata_phy_control;
+   unsigned char   res7[0xdc];
+   unsigned intinform0;
+   unsigned intinform1;
+   unsigned intinform2;
+   unsigned intinform3;
+   unsigned intinform4;
+   unsigned intinform5;
+   unsigned intinform6;
+   unsigned intinform7;
+   unsigned char   res8[0x1e0];
+   unsigned intpmu_debug;
+   unsigned char   res9[0x5fc];
+   unsigned intarm_core0_sys_pwr_reg;
+   unsigned char   res10[0xc];
+   unsigned intarm_core1_sys_pwr_reg;
+   unsigned char   res11[0x6c];
+   unsigned intarm_common_sys_pwr_reg;
+   unsigned char   res12[0x3c];
+   unsigned intarm_cpu_l2_0_sys_pwr_reg;
+   unsigned intarm_cpu_l2_1_sys_pwr_reg;
+   unsigned char   res13[0x38];
+   unsigned intcmu_aclkstop_sys_pwr_reg;
+   unsigned intcmu_sclkstop_sys_pwr_reg;
+   unsigned char   res14[0x4];
+   unsigned intcmu_reset_sys_pwr_reg;
+   unsigned char   res15[0x10];
+   unsigned intapll_sysclk_sys_pwr_reg;
+   unsigned intmpll_sysclk_sys_pwr_reg;
+   unsigned intvpll_sysclk_sys_pwr_reg;
+   unsigned intepll_sysclk_sys_pwr_reg;
+   unsigned char   res16[0x8];
+   unsigned intcmu_clkstop_gps_alive_sys_pwr_reg;
+   unsigned intcmu_reset_gps_alive_sys_pwr_reg;
+   unsigned intcmu_clkstop_cam_sys_pwr_reg;
+   unsigned intcmu_clkstop_tv_sys_pwr_reg;
+   unsigned intcmu_clkstop_mfc_sys_pwr_reg;
+   unsigned intcmu_clkstop_g3d_sys_pwr_reg;
+   unsigned intcmu_clkstop_lcd0_sys_pwr_reg;
+   unsigned intcmu_clkstop_lcd1_sys_pwr_reg;
+   unsigned intcmu_clkstop_maudio_sys_pwr_reg;
+   unsigned int

[U-Boot] [PATCH v5 1/3] ARMV7: Exynos4: Add watchdog.h for Exynos4

2012-01-16 Thread HeungJun, Kim
This patch add watchdog.h for Exynos4

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
Changes for v3:
   - Created

Changes for v4:
   - Not changed

Changes for v4:
   - Not changed

 arch/arm/include/asm/arch-exynos/watchdog.h |   53 +++
 1 files changed, 53 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-exynos/watchdog.h

diff --git a/arch/arm/include/asm/arch-exynos/watchdog.h 
b/arch/arm/include/asm/arch-exynos/watchdog.h
new file mode 100644
index 000..3015875
--- /dev/null
+++ b/arch/arm/include/asm/arch-exynos/watchdog.h
@@ -0,0 +1,53 @@
+/*
+ * Copyright (C) 2011 Samsung Electronics
+ * Heungjun Kim riverful@samsung.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
+ */
+
+#ifndef __ASM_ARM_ARCH_WATCHDOG_H_
+#define __ASM_ARM_ARCH_WATCHDOG_H_
+
+#define WTCON_RESET_OFFSET 0
+#define WTCON_INTEN_OFFSET 2
+#define WTCON_CLKSEL_OFFSET3
+#define WTCON_EN_OFFSET5
+#define WTCON_PRE_OFFSET   8
+
+#define WTCON_CLK_16   0x0
+#define WTCON_CLK_32   0x1
+#define WTCON_CLK_64   0x2
+#define WTCON_CLK_128  0x3
+
+#define WTCON_CLK(x)   ((x  0x3)  WTCON_CLKSEL_OFFSET)
+#define WTCON_PRESCALER(x) ((x)  WTCON_PRE_OFFSET)
+#define WTCON_EN   (0x1  WTCON_EN_OFFSET)
+#define WTCON_RESET(0x1  WTCON_RESET_OFFSET)
+#define WTCON_INT  (0x1  WTCON_INTEN_OFFSET)
+
+#ifndef __ASSEMBLY__
+struct exynos4_watchdog {
+   unsigned int wtcon;
+   unsigned int wtdat;
+   unsigned int wtcnt;
+   unsigned int wtclrint;
+};
+#endif /* __ASSEMBLY__ */
+
+#endif
-- 
1.7.4.1

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH v4 0/4] ARMV7: Exynos4: Add support for TRATS board

2012-01-15 Thread HeungJun, Kim
This patch series support for Samsung TRATS board, and add the headers of
watchdog and power, and current version is 4.

I missed logs of v2 on this thread, so I'm going to add this:
http://lists.denx.de/pipermail/u-boot/2012-January/114857.html

Also, this patch is tested on Samsung TRATS board.

Thank you.

Best Regards,
Heungjun Kim

HeungJun, Kim (4):
  ARMV7: Exynos4: Add watchdog.h for Exynos4
  ARMV7: Exynos4: Add supoort power for Exynos4
  ARMV7: Exynos4: Fix toolchain optimization problem for using volatile
  ARMV7: Exynos4: Add support for TRATS board

 MAINTAINERS |4 +
 arch/arm/include/asm/arch-exynos/cpu.h  |1 +
 arch/arm/include/asm/arch-exynos/gpio.h |   22 +-
 arch/arm/include/asm/arch-exynos/power.h|  230 ++
 arch/arm/include/asm/arch-exynos/watchdog.h |   53 +++
 board/samsung/trats/Makefile|   43 ++
 board/samsung/trats/setup.h |  637 +++
 board/samsung/trats/trats.c |  379 
 boards.cfg  |1 +
 drivers/gpio/s5p_gpio.c |   42 +-
 include/configs/trats.h |  214 +
 11 files changed, 1600 insertions(+), 26 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-exynos/power.h
 create mode 100644 arch/arm/include/asm/arch-exynos/watchdog.h
 create mode 100644 board/samsung/trats/Makefile
 create mode 100644 board/samsung/trats/setup.h
 create mode 100644 board/samsung/trats/trats.c
 create mode 100644 include/configs/trats.h

-- 
1.7.4.1

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH v4 2/4] ARMV7: Exynos4: Add supoort power for Exynos4

2012-01-15 Thread HeungJun, Kim
This patch adds power.h and SAMSUNG_BASE() macro for using Exynos4 power.

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
Changes for v3:
   - Created

Changes for v4:
   - Not changed

 arch/arm/include/asm/arch-exynos/cpu.h   |1 +
 arch/arm/include/asm/arch-exynos/power.h |  230 ++
 2 files changed, 231 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-exynos/power.h

diff --git a/arch/arm/include/asm/arch-exynos/cpu.h 
b/arch/arm/include/asm/arch-exynos/cpu.h
index 6d97b99..3496616 100644
--- a/arch/arm/include/asm/arch-exynos/cpu.h
+++ b/arch/arm/include/asm/arch-exynos/cpu.h
@@ -109,6 +109,7 @@ SAMSUNG_BASE(uart, UART_BASE)
 SAMSUNG_BASE(usb_phy, USBPHY_BASE)
 SAMSUNG_BASE(usb_otg, USBOTG_BASE)
 SAMSUNG_BASE(watchdog, WATCHDOG_BASE)
+SAMSUNG_BASE(power, POWER_BASE)
 #endif
 
 #endif /* _EXYNOS4_CPU_H */
diff --git a/arch/arm/include/asm/arch-exynos/power.h 
b/arch/arm/include/asm/arch-exynos/power.h
new file mode 100644
index 000..fb442f7
--- /dev/null
+++ b/arch/arm/include/asm/arch-exynos/power.h
@@ -0,0 +1,230 @@
+/*
+ * Copyright (C) 2011 Samsung Electronics
+ * Heungjun Kim riverful@samsung.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
+ */
+
+#ifndef __ASM_ARM_ARCH_POWER_H_
+#define __ASM_ARM_ARCH_POWER_H_
+
+#ifndef __ASSEMBLY__
+struct exynos4_power {
+   unsigned intom_stat;
+   unsigned char   res1[0x8];
+   unsigned intrtc_clko_sel;
+   unsigned intgnss_rtc_out_ctrl;
+   unsigned char   res2[0x1ec];
+   unsigned intsystem_power_down_ctrl;
+   unsigned char   res3[0x1];
+   unsigned intsystem_power_down_option;
+   unsigned char   res4[0x1f4];
+   unsigned intswreset;
+   unsigned intrst_stat;
+   unsigned char   res5[0x1f8];
+   unsigned intwakeup_stat;
+   unsigned inteint_wakeup_mask;
+   unsigned intwakeup_mask;
+   unsigned char   res6[0xf4];
+   unsigned inthdmi_phy_control;
+   unsigned intusbdevice_phy_control;
+   unsigned intusbhost_phy_control;
+   unsigned intdac_phy_control;
+   unsigned intmipi_phy0_control;
+   unsigned intmipi_phy1_control;
+   unsigned intadc_phy_control;
+   unsigned intpcie_phy_control;
+   unsigned intsata_phy_control;
+   unsigned char   res7[0xdc];
+   unsigned intinform0;
+   unsigned intinform1;
+   unsigned intinform2;
+   unsigned intinform3;
+   unsigned intinform4;
+   unsigned intinform5;
+   unsigned intinform6;
+   unsigned intinform7;
+   unsigned char   res8[0x1e0];
+   unsigned intpmu_debug;
+   unsigned char   res9[0x5fc];
+   unsigned intarm_core0_sys_pwr_reg;
+   unsigned char   res10[0xc];
+   unsigned intarm_core1_sys_pwr_reg;
+   unsigned char   res11[0x6c];
+   unsigned intarm_common_sys_pwr_reg;
+   unsigned char   res12[0x3c];
+   unsigned intarm_cpu_l2_0_sys_pwr_reg;
+   unsigned intarm_cpu_l2_1_sys_pwr_reg;
+   unsigned char   res13[0x38];
+   unsigned intcmu_aclkstop_sys_pwr_reg;
+   unsigned intcmu_sclkstop_sys_pwr_reg;
+   unsigned char   res14[0x4];
+   unsigned intcmu_reset_sys_pwr_reg;
+   unsigned char   res15[0x10];
+   unsigned intapll_sysclk_sys_pwr_reg;
+   unsigned intmpll_sysclk_sys_pwr_reg;
+   unsigned intvpll_sysclk_sys_pwr_reg;
+   unsigned intepll_sysclk_sys_pwr_reg;
+   unsigned char   res16[0x8];
+   unsigned intcmu_clkstop_gps_alive_sys_pwr_reg;
+   unsigned intcmu_reset_gps_alive_sys_pwr_reg;
+   unsigned intcmu_clkstop_cam_sys_pwr_reg;
+   unsigned intcmu_clkstop_tv_sys_pwr_reg;
+   unsigned intcmu_clkstop_mfc_sys_pwr_reg;
+   unsigned intcmu_clkstop_g3d_sys_pwr_reg;
+   unsigned intcmu_clkstop_lcd0_sys_pwr_reg;
+   unsigned intcmu_clkstop_lcd1_sys_pwr_reg;
+   unsigned intcmu_clkstop_maudio_sys_pwr_reg;
+   unsigned intcmu_clkstop_gps_sys_pwr_reg;
+   unsigned

[U-Boot] [PATCH v4 1/4] ARMV7: Exynos4: Add watchdog.h for Exynos4

2012-01-15 Thread HeungJun, Kim
This patch add watchdog.h for Exynos4

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
Changes for v3:
   - Created

Changes for v4:
   - Not changed

 arch/arm/include/asm/arch-exynos/watchdog.h |   53 +++
 1 files changed, 53 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-exynos/watchdog.h

diff --git a/arch/arm/include/asm/arch-exynos/watchdog.h 
b/arch/arm/include/asm/arch-exynos/watchdog.h
new file mode 100644
index 000..3015875
--- /dev/null
+++ b/arch/arm/include/asm/arch-exynos/watchdog.h
@@ -0,0 +1,53 @@
+/*
+ * Copyright (C) 2011 Samsung Electronics
+ * Heungjun Kim riverful@samsung.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
+ */
+
+#ifndef __ASM_ARM_ARCH_WATCHDOG_H_
+#define __ASM_ARM_ARCH_WATCHDOG_H_
+
+#define WTCON_RESET_OFFSET 0
+#define WTCON_INTEN_OFFSET 2
+#define WTCON_CLKSEL_OFFSET3
+#define WTCON_EN_OFFSET5
+#define WTCON_PRE_OFFSET   8
+
+#define WTCON_CLK_16   0x0
+#define WTCON_CLK_32   0x1
+#define WTCON_CLK_64   0x2
+#define WTCON_CLK_128  0x3
+
+#define WTCON_CLK(x)   ((x  0x3)  WTCON_CLKSEL_OFFSET)
+#define WTCON_PRESCALER(x) ((x)  WTCON_PRE_OFFSET)
+#define WTCON_EN   (0x1  WTCON_EN_OFFSET)
+#define WTCON_RESET(0x1  WTCON_RESET_OFFSET)
+#define WTCON_INT  (0x1  WTCON_INTEN_OFFSET)
+
+#ifndef __ASSEMBLY__
+struct exynos4_watchdog {
+   unsigned int wtcon;
+   unsigned int wtdat;
+   unsigned int wtcnt;
+   unsigned int wtclrint;
+};
+#endif /* __ASSEMBLY__ */
+
+#endif
-- 
1.7.4.1

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH v4 4/4] ARMV7: Exynos4: Add support for TRATS board

2012-01-15 Thread HeungJun, Kim
This patch adds support for Samsung TRATS board

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
Changes for v2:
   - sort the list of the name in MAINTAINERS
   - modify to GPLv2+
   - change assem code in lowlevel_init.S to C code in lowlevel_util.c
   - do not defile values for variables if the variable is feature
   - remove miscellaneouses

Changes for v3:
   - implement lowlevel_init.S by C
   - remove lowlevel_init.S, the functions is inserted into trats.c
   - add watchdog.h for Exynos4
   - add power.h amd modify cpu.h for Exynos4

Changes for RESEND since v3
   - Add prefix board_ for board functions
   - Rename setup.h from trats_setup.h
   - Remove *_OFFSET in setup.h
   - Remove GPIO and UART definitions in setup.h

Changes for v4:
   - add selection UART direction for TRATS board

 MAINTAINERS  |4 +
 board/samsung/trats/Makefile |   43 +++
 board/samsung/trats/setup.h  |  637 ++
 board/samsung/trats/trats.c  |  379 +
 boards.cfg   |1 +
 include/configs/trats.h  |  214 ++
 6 files changed, 1278 insertions(+), 0 deletions(-)
 create mode 100644 board/samsung/trats/Makefile
 create mode 100644 board/samsung/trats/setup.h
 create mode 100644 board/samsung/trats/trats.c
 create mode 100644 include/configs/trats.h

diff --git a/MAINTAINERS b/MAINTAINERS
index 4bf12b5..60314a6 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -706,6 +706,10 @@ Chander Kashyap k.chan...@samsung.com
origen  ARM ARMV7 (EXYNOS4210 SoC)
SMDKV310ARM ARMV7 (EXYNOS4210 SoC)
 
+Heungjun Kim riverful@samsung.com
+
+   trats   ARM ARMV7 (EXYNOS4210 SoC)
+
 Torsten Koschorrek koschor...@synertronixx.de
scb9328 ARM920T (i.MXL)
 
diff --git a/board/samsung/trats/Makefile b/board/samsung/trats/Makefile
new file mode 100644
index 000..d21883f
--- /dev/null
+++ b/board/samsung/trats/Makefile
@@ -0,0 +1,43 @@
+#
+# Copyright (C) 2011 Samsung Electronics
+# Heungjun Kim riverful@samsung.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
+#
+
+include $(TOPDIR)/config.mk
+
+LIB= $(obj)lib$(BOARD).o
+
+COBJS-y+= trats.o
+
+SRCS:= $(COBJS-y:.o=.c)
+OBJS   := $(addprefix $(obj),$(COBJS-y))
+
+$(LIB):$(obj).depend $(OBJS)
+   $(call cmd_link_o_target, $(OBJS))
+
+#
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+#
diff --git a/board/samsung/trats/setup.h b/board/samsung/trats/setup.h
new file mode 100644
index 000..a479b5c
--- /dev/null
+++ b/board/samsung/trats/setup.h
@@ -0,0 +1,637 @@
+/*
+ * Machine Specific Values for TRATS board based on EXYNOS4210
+ *
+ * Copyright (C) 2011 Samsung Electronics
+ * Heungjun Kim riverful@samsung.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
+ */
+
+#ifndef _TRATS_SETUP_H
+#define _TRATS_SETUP_H
+
+#include config.h
+#include version.h
+#include asm/arch/cpu.h
+
+/* CLK_SRC_CPU: APLL(1), MPLL(1), CORE(0), HPM(0) */
+#define MUX_HPM_SEL_MOUTAPLL   0x0
+#define MUX_HPM_SEL_SCLKMPLL   0x1
+#define MUX_CORE_SEL_MOUTAPLL  0x0
+#define MUX_CORE_SEL_SCLKMPLL  0x1
+#define MUX_MPLL_SEL_FILPLL

[U-Boot] [PATCH v4 3/4] ARMV7: Exynos4: Fix toolchain optimization problem for using volatile

2012-01-15 Thread HeungJun, Kim
Because of wrong disassembled codes from C by the optimization of toolchain,
it occurs a problem that wrong register is read if the functions were called
in the asm code.

This patch uses keyword volatile for fixing it for sure. And, it is inserted
only when the function is extern in the driver/gpio/s5p_gpio.c

It was founded while testing TRATS board  completed tests on the TRATS board.

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
Changes for v4:
   - Created

 arch/arm/include/asm/arch-exynos/gpio.h |   22 ++--
 drivers/gpio/s5p_gpio.c |   42 +-
 2 files changed, 38 insertions(+), 26 deletions(-)

diff --git a/arch/arm/include/asm/arch-exynos/gpio.h 
b/arch/arm/include/asm/arch-exynos/gpio.h
index 9863a12..2fb2a0b 100644
--- a/arch/arm/include/asm/arch-exynos/gpio.h
+++ b/arch/arm/include/asm/arch-exynos/gpio.h
@@ -80,14 +80,20 @@ struct exynos4_gpio_part3 {
 };
 
 /* functions */
-void s5p_gpio_cfg_pin(struct s5p_gpio_bank *bank, int gpio, int cfg);
-void s5p_gpio_direction_output(struct s5p_gpio_bank *bank, int gpio, int en);
-void s5p_gpio_direction_input(struct s5p_gpio_bank *bank, int gpio);
-void s5p_gpio_set_value(struct s5p_gpio_bank *bank, int gpio, int en);
-unsigned int s5p_gpio_get_value(struct s5p_gpio_bank *bank, int gpio);
-void s5p_gpio_set_pull(struct s5p_gpio_bank *bank, int gpio, int mode);
-void s5p_gpio_set_drv(struct s5p_gpio_bank *bank, int gpio, int mode);
-void s5p_gpio_set_rate(struct s5p_gpio_bank *bank, int gpio, int mode);
+void s5p_gpio_cfg_pin(struct s5p_gpio_bank *bank,
+   volatile int gpio, volatile int cfg);
+void s5p_gpio_direction_output(struct s5p_gpio_bank *bank,
+   volatile int gpio, volatile int en);
+void s5p_gpio_direction_input(struct s5p_gpio_bank *bank, volatile int gpio);
+void s5p_gpio_set_value(struct s5p_gpio_bank *bank,
+   volatile int gpio, volatile int en);
+unsigned int s5p_gpio_get_value(struct s5p_gpio_bank *bank, volatile int gpio);
+void s5p_gpio_set_pull(struct s5p_gpio_bank *bank,
+   volatile int gpio, volatile int mode);
+void s5p_gpio_set_drv(struct s5p_gpio_bank *bank,
+   volatile int gpio, volatile int mode);
+void s5p_gpio_set_rate(struct s5p_gpio_bank *bank,
+   volatile int gpio, volatile int mode);
 
 /* GPIO pins per bank  */
 #define GPIO_PER_BANK 8
diff --git a/drivers/gpio/s5p_gpio.c b/drivers/gpio/s5p_gpio.c
index 1edf9a2..edc3511 100644
--- a/drivers/gpio/s5p_gpio.c
+++ b/drivers/gpio/s5p_gpio.c
@@ -36,9 +36,10 @@
 #define RATE_MASK(x)   (0x1  (x + 16))
 #define RATE_SET(x)(0x1  (x + 16))
 
-void s5p_gpio_cfg_pin(struct s5p_gpio_bank *bank, int gpio, int cfg)
+void s5p_gpio_cfg_pin(struct s5p_gpio_bank *bank,
+ volatile int gpio, volatile int cfg)
 {
-   unsigned int value;
+   volatile unsigned int value;
 
value = readl(bank-con);
value = ~CON_MASK(gpio);
@@ -46,9 +47,10 @@ void s5p_gpio_cfg_pin(struct s5p_gpio_bank *bank, int gpio, 
int cfg)
writel(value, bank-con);
 }
 
-void s5p_gpio_direction_output(struct s5p_gpio_bank *bank, int gpio, int en)
+void s5p_gpio_direction_output(struct s5p_gpio_bank *bank,
+  volatile int gpio, volatile int en)
 {
-   unsigned int value;
+   volatile unsigned int value;
 
s5p_gpio_cfg_pin(bank, gpio, GPIO_OUTPUT);
 
@@ -59,14 +61,15 @@ void s5p_gpio_direction_output(struct s5p_gpio_bank *bank, 
int gpio, int en)
writel(value, bank-dat);
 }
 
-void s5p_gpio_direction_input(struct s5p_gpio_bank *bank, int gpio)
+void s5p_gpio_direction_input(struct s5p_gpio_bank *bank, volatile int gpio)
 {
s5p_gpio_cfg_pin(bank, gpio, GPIO_INPUT);
 }
 
-void s5p_gpio_set_value(struct s5p_gpio_bank *bank, int gpio, int en)
+void s5p_gpio_set_value(struct s5p_gpio_bank *bank,
+   volatile int gpio, volatile int en)
 {
-   unsigned int value;
+   volatile unsigned int value;
 
value = readl(bank-dat);
value = ~DAT_MASK(gpio);
@@ -75,17 +78,18 @@ void s5p_gpio_set_value(struct s5p_gpio_bank *bank, int 
gpio, int en)
writel(value, bank-dat);
 }
 
-unsigned int s5p_gpio_get_value(struct s5p_gpio_bank *bank, int gpio)
+unsigned int s5p_gpio_get_value(struct s5p_gpio_bank *bank, volatile int gpio)
 {
-   unsigned int value;
+   volatile unsigned int value;
 
value = readl(bank-dat);
return !!(value  DAT_MASK(gpio));
 }
 
-void s5p_gpio_set_pull(struct s5p_gpio_bank *bank, int gpio, int mode)
+void s5p_gpio_set_pull(struct s5p_gpio_bank *bank,
+  volatile int gpio, volatile int mode)
 {
-   unsigned int value;
+   volatile unsigned int value;
 
value = readl(bank-pull);
value = ~PULL_MASK(gpio);
@@ -102,9 +106,10 @@ void

[U-Boot] [PATCH v3 0/3] ARMV7: Exynos4: Add support for TRATS board

2012-01-10 Thread HeungJun, Kim
This patch series support for Samsung TRATS board, and add the headers of
watchdog and power.

I missed logs of v2 on this thread, so I'm going to add this:
http://lists.denx.de/pipermail/u-boot/2012-January/114857.html

Also, this patch is tested on Samsung TRATS board.

Thank you.

Best Regards,
 Heungjun Kim

Changes for v2:
   - sort the list of the name in MAINTAINERS
   - modify to GPLv2+
   - change assem code in lowlevel_init.S to C code in lowlevel_util.c
   - do not defile values for variables if the variable is feature
   - remove miscellaneouses

Changes for v3:
   - implement lowlevel_init.S by C
   - remove lowlevel_init.S, the functions is inserted into trats.c
   - add watchdog.h for Exynos4
   - add power.h amd modify cpu.h for Exynos4

HeungJun, Kim (3):
  ARMV7: Exynos4: Add watchdog.h for Exynos4
  ARMV7: Exynos4: Add supoort power for Exynos4
  ARMV7: Exynos4: Add support for TRATS board

 MAINTAINERS |4 +
 arch/arm/include/asm/arch-exynos/cpu.h  |1 +
 arch/arm/include/asm/arch-exynos/power.h|  230 
 arch/arm/include/asm/arch-exynos/watchdog.h |   53 ++
 board/samsung/trats/Makefile|   43 ++
 board/samsung/trats/trats.c |  349 
 board/samsung/trats/trats_setup.h   |  814 +++
 boards.cfg  |1 +
 include/configs/trats.h |  216 +++
 9 files changed, 1711 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-exynos/power.h
 create mode 100644 arch/arm/include/asm/arch-exynos/watchdog.h
 create mode 100644 board/samsung/trats/Makefile
 create mode 100644 board/samsung/trats/trats.c
 create mode 100644 board/samsung/trats/trats_setup.h
 create mode 100644 include/configs/trats.h

-- 
1.7.4.1

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH v3 1/3] ARMV7: Exynos4: Add watchdog.h for Exynos4

2012-01-10 Thread HeungJun, Kim
This patch add watchdog.h for Exynos4

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
 arch/arm/include/asm/arch-exynos/watchdog.h |   53 +++
 1 files changed, 53 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-exynos/watchdog.h

diff --git a/arch/arm/include/asm/arch-exynos/watchdog.h 
b/arch/arm/include/asm/arch-exynos/watchdog.h
new file mode 100644
index 000..3015875
--- /dev/null
+++ b/arch/arm/include/asm/arch-exynos/watchdog.h
@@ -0,0 +1,53 @@
+/*
+ * Copyright (C) 2011 Samsung Electronics
+ * Heungjun Kim riverful@samsung.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
+ */
+
+#ifndef __ASM_ARM_ARCH_WATCHDOG_H_
+#define __ASM_ARM_ARCH_WATCHDOG_H_
+
+#define WTCON_RESET_OFFSET 0
+#define WTCON_INTEN_OFFSET 2
+#define WTCON_CLKSEL_OFFSET3
+#define WTCON_EN_OFFSET5
+#define WTCON_PRE_OFFSET   8
+
+#define WTCON_CLK_16   0x0
+#define WTCON_CLK_32   0x1
+#define WTCON_CLK_64   0x2
+#define WTCON_CLK_128  0x3
+
+#define WTCON_CLK(x)   ((x  0x3)  WTCON_CLKSEL_OFFSET)
+#define WTCON_PRESCALER(x) ((x)  WTCON_PRE_OFFSET)
+#define WTCON_EN   (0x1  WTCON_EN_OFFSET)
+#define WTCON_RESET(0x1  WTCON_RESET_OFFSET)
+#define WTCON_INT  (0x1  WTCON_INTEN_OFFSET)
+
+#ifndef __ASSEMBLY__
+struct exynos4_watchdog {
+   unsigned int wtcon;
+   unsigned int wtdat;
+   unsigned int wtcnt;
+   unsigned int wtclrint;
+};
+#endif /* __ASSEMBLY__ */
+
+#endif
-- 
1.7.4.1

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH v3 2/3] ARMV7: Exynos4: Add supoort power for Exynos4

2012-01-10 Thread HeungJun, Kim
This patch adds power.h and SAMSUNG_BASE() macro for using Exynos4 power.

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
 arch/arm/include/asm/arch-exynos/cpu.h   |1 +
 arch/arm/include/asm/arch-exynos/power.h |  230 ++
 2 files changed, 231 insertions(+), 0 deletions(-)
 create mode 100644 arch/arm/include/asm/arch-exynos/power.h

diff --git a/arch/arm/include/asm/arch-exynos/cpu.h 
b/arch/arm/include/asm/arch-exynos/cpu.h
index 6d97b99..3496616 100644
--- a/arch/arm/include/asm/arch-exynos/cpu.h
+++ b/arch/arm/include/asm/arch-exynos/cpu.h
@@ -109,6 +109,7 @@ SAMSUNG_BASE(uart, UART_BASE)
 SAMSUNG_BASE(usb_phy, USBPHY_BASE)
 SAMSUNG_BASE(usb_otg, USBOTG_BASE)
 SAMSUNG_BASE(watchdog, WATCHDOG_BASE)
+SAMSUNG_BASE(power, POWER_BASE)
 #endif
 
 #endif /* _EXYNOS4_CPU_H */
diff --git a/arch/arm/include/asm/arch-exynos/power.h 
b/arch/arm/include/asm/arch-exynos/power.h
new file mode 100644
index 000..fb442f7
--- /dev/null
+++ b/arch/arm/include/asm/arch-exynos/power.h
@@ -0,0 +1,230 @@
+/*
+ * Copyright (C) 2011 Samsung Electronics
+ * Heungjun Kim riverful@samsung.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
+ */
+
+#ifndef __ASM_ARM_ARCH_POWER_H_
+#define __ASM_ARM_ARCH_POWER_H_
+
+#ifndef __ASSEMBLY__
+struct exynos4_power {
+   unsigned intom_stat;
+   unsigned char   res1[0x8];
+   unsigned intrtc_clko_sel;
+   unsigned intgnss_rtc_out_ctrl;
+   unsigned char   res2[0x1ec];
+   unsigned intsystem_power_down_ctrl;
+   unsigned char   res3[0x1];
+   unsigned intsystem_power_down_option;
+   unsigned char   res4[0x1f4];
+   unsigned intswreset;
+   unsigned intrst_stat;
+   unsigned char   res5[0x1f8];
+   unsigned intwakeup_stat;
+   unsigned inteint_wakeup_mask;
+   unsigned intwakeup_mask;
+   unsigned char   res6[0xf4];
+   unsigned inthdmi_phy_control;
+   unsigned intusbdevice_phy_control;
+   unsigned intusbhost_phy_control;
+   unsigned intdac_phy_control;
+   unsigned intmipi_phy0_control;
+   unsigned intmipi_phy1_control;
+   unsigned intadc_phy_control;
+   unsigned intpcie_phy_control;
+   unsigned intsata_phy_control;
+   unsigned char   res7[0xdc];
+   unsigned intinform0;
+   unsigned intinform1;
+   unsigned intinform2;
+   unsigned intinform3;
+   unsigned intinform4;
+   unsigned intinform5;
+   unsigned intinform6;
+   unsigned intinform7;
+   unsigned char   res8[0x1e0];
+   unsigned intpmu_debug;
+   unsigned char   res9[0x5fc];
+   unsigned intarm_core0_sys_pwr_reg;
+   unsigned char   res10[0xc];
+   unsigned intarm_core1_sys_pwr_reg;
+   unsigned char   res11[0x6c];
+   unsigned intarm_common_sys_pwr_reg;
+   unsigned char   res12[0x3c];
+   unsigned intarm_cpu_l2_0_sys_pwr_reg;
+   unsigned intarm_cpu_l2_1_sys_pwr_reg;
+   unsigned char   res13[0x38];
+   unsigned intcmu_aclkstop_sys_pwr_reg;
+   unsigned intcmu_sclkstop_sys_pwr_reg;
+   unsigned char   res14[0x4];
+   unsigned intcmu_reset_sys_pwr_reg;
+   unsigned char   res15[0x10];
+   unsigned intapll_sysclk_sys_pwr_reg;
+   unsigned intmpll_sysclk_sys_pwr_reg;
+   unsigned intvpll_sysclk_sys_pwr_reg;
+   unsigned intepll_sysclk_sys_pwr_reg;
+   unsigned char   res16[0x8];
+   unsigned intcmu_clkstop_gps_alive_sys_pwr_reg;
+   unsigned intcmu_reset_gps_alive_sys_pwr_reg;
+   unsigned intcmu_clkstop_cam_sys_pwr_reg;
+   unsigned intcmu_clkstop_tv_sys_pwr_reg;
+   unsigned intcmu_clkstop_mfc_sys_pwr_reg;
+   unsigned intcmu_clkstop_g3d_sys_pwr_reg;
+   unsigned intcmu_clkstop_lcd0_sys_pwr_reg;
+   unsigned intcmu_clkstop_lcd1_sys_pwr_reg;
+   unsigned intcmu_clkstop_maudio_sys_pwr_reg;
+   unsigned intcmu_clkstop_gps_sys_pwr_reg;
+   unsigned intcmu_reset_cam_sys_pwr_reg;
+   unsigned int

[U-Boot] [PATCH v3 3/3] ARMV7: Exynos4: Add support for TRATS board

2012-01-10 Thread HeungJun, Kim
This patch adds support for Samsung TRATS board

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
 MAINTAINERS   |4 +
 board/samsung/trats/Makefile  |   43 ++
 board/samsung/trats/trats.c   |  349 
 board/samsung/trats/trats_setup.h |  814 +
 boards.cfg|1 +
 include/configs/trats.h   |  216 ++
 6 files changed, 1427 insertions(+), 0 deletions(-)
 create mode 100644 board/samsung/trats/Makefile
 create mode 100644 board/samsung/trats/trats.c
 create mode 100644 board/samsung/trats/trats_setup.h
 create mode 100644 include/configs/trats.h

diff --git a/MAINTAINERS b/MAINTAINERS
index 4bf12b5..60314a6 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -706,6 +706,10 @@ Chander Kashyap k.chan...@samsung.com
origen  ARM ARMV7 (EXYNOS4210 SoC)
SMDKV310ARM ARMV7 (EXYNOS4210 SoC)
 
+Heungjun Kim riverful@samsung.com
+
+   trats   ARM ARMV7 (EXYNOS4210 SoC)
+
 Torsten Koschorrek koschor...@synertronixx.de
scb9328 ARM920T (i.MXL)
 
diff --git a/board/samsung/trats/Makefile b/board/samsung/trats/Makefile
new file mode 100644
index 000..d21883f
--- /dev/null
+++ b/board/samsung/trats/Makefile
@@ -0,0 +1,43 @@
+#
+# Copyright (C) 2011 Samsung Electronics
+# Heungjun Kim riverful@samsung.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
+#
+
+include $(TOPDIR)/config.mk
+
+LIB= $(obj)lib$(BOARD).o
+
+COBJS-y+= trats.o
+
+SRCS:= $(COBJS-y:.o=.c)
+OBJS   := $(addprefix $(obj),$(COBJS-y))
+
+$(LIB):$(obj).depend $(OBJS)
+   $(call cmd_link_o_target, $(OBJS))
+
+#
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+#
diff --git a/board/samsung/trats/trats.c b/board/samsung/trats/trats.c
new file mode 100644
index 000..9070df5
--- /dev/null
+++ b/board/samsung/trats/trats.c
@@ -0,0 +1,349 @@
+/*
+ * Copyright (C) 2011 Samsung Electronics
+ * Heungjun Kim riverful@samsung.com
+ * Kyungmin Park kyungmin.p...@samsung.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
+ */
+
+#include common.h
+#include asm/io.h
+#include asm/arch/gpio.h
+#include asm/arch/mmc.h
+#include asm/arch/clock.h
+#include asm/arch/watchdog.h
+#include asm/arch/gpio.h
+#include asm/arch/power.h
+#include pmic.h
+#include usb/s3c_udc.h
+#include asm/arch/cpu.h
+#include max8998_pmic.h
+
+#include trats_setup.h
+
+DECLARE_GLOBAL_DATA_PTR;
+
+unsigned int board_rev;
+
+#ifdef CONFIG_REVISION_TAG
+u32 get_board_rev(void)
+{
+   return board_rev;
+}
+#endif
+
+static void check_hw_revision(void);
+static void pmic_reset(void);
+
+int board_init(void)
+{
+   gd-bd-bi_boot_params = PHYS_SDRAM_1 + 0x100;
+
+   check_hw_revision();
+   printf(HW Revision:\t0x%x\n, board_rev);
+
+#if defined(CONFIG_PMIC)
+   pmic_init();
+   pmic_reset();
+#endif
+
+   return 0;
+}
+
+int dram_init(void)
+{
+   gd-ram_size = get_ram_size((long *)PHYS_SDRAM_1, PHYS_SDRAM_1_SIZE) +
+   get_ram_size((long *)PHYS_SDRAM_2, PHYS_SDRAM_2_SIZE);
+
+   return 0;
+}
+
+void dram_init_banksize(void)
+{
+   gd-bd-bi_dram[0].start = PHYS_SDRAM_1;
+   gd-bd

Re: [U-Boot] [PATCH v2 0/4] Add SMDK5250 board support

2012-01-10 Thread HeungJun, Kim
Hi Chander Kashyap,

I'm going to share the status of size.

The case of assemble code:
textdata bss dec hex filename
   1929  20  121961 7a9 board/samsung/trats/libtrats.o
912   0   0 912 390 board/samsung/trats/lowlevel_init.o
   1017  20  121049 419 board/samsung/trats/trats.o

The case of C code:
textdata bss dec hex filename
   1845  20   41869 74d board/samsung/trats/libtrats.o
   1845  20   41869 74d board/samsung/trats/trats.o

Although the pre-version patch has been optimized to current version,
and so it might be the factor, but the size is decreased.

Thank you.

Regards,
Heungjun Kim



 -Original Message-
 From: linaro-dev-boun...@lists.linaro.org [mailto:linaro-dev-
 boun...@lists.linaro.org] On Behalf Of Chander Kashyap
 Sent: Tuesday, January 10, 2012 12:58 PM
 To: Simon Glass
 Cc: linaro-...@lists.linaro.org; bj...@samsung.com; patc...@linaro.org;
 mk7.k...@samsung.com; u-boot@lists.denx.de; sams...@lists.linaro.org
 Subject: Re: [U-Boot] [PATCH v2 0/4] Add SMDK5250 board support
 
 Dear Simon,
 
 On 9 January 2012 23:25, Simon Glass s...@chromium.org wrote:
  Hi Chander,
 
  On Sun, Jan 8, 2012 at 10:40 PM, Chander Kashyap
  chander.kash...@linaro.org wrote:
  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             |  215 +-
   arch/arm/include/asm/arch-exynos/clock.h      |  326 ++
   arch/arm/include/asm/arch-exynos/cpu.h        |   53 ++-
   arch/arm/include/asm/arch-exynos/gpio.h       |   32 ++
   board/samsung/smdk5250/Makefile               |   64 +++
   board/samsung/smdk5250/lowlevel_init.S        |  528
++
   board/samsung/smdk5250/mem_setup.S            |  600
 +
 
  Are you planning to reimplement most of these two files in C as per
  Wolfgang's comments on the TRATS board, or is that a separate issue?
 Not as of now. We have 14K for spl.  Using C style it might not fit into that.
 
  Regards,
  Simon
 
   board/samsung/smdk5250/mmc_boot.c             |   58 +++
   board/samsung/smdk5250/smdk5250.c             |  125 +
   board/samsung/smdk5250/smdk5250_setup.h       |  589
 
   board/samsung/smdk5250/tools/mkexynos_image.c |  117 +
   boards.cfg                                    |    1 +
   include/configs/s5pc210_universal.h           |    1 +
   include/configs/smdk5250.h                    |  188 
   15 files changed, 2878 insertions(+), 20 deletions(-)
   create mode 100644 board/samsung/smdk5250/Makefile
   create mode 100644 board/samsung/smdk5250/lowlevel_init.S
   create mode 100644 board/samsung/smdk5250/mem_setup.S
   create mode 100644 board/samsung/smdk5250/mmc_boot.c
   create mode 100644 board/samsung/smdk5250/smdk5250.c
   create mode 100644 board/samsung/smdk5250/smdk5250_setup.h
   create mode 100644 board/samsung/smdk5250/tools/mkexynos_image.c
   create mode 100644 include/configs/smdk5250.h
 
  --
  1.7.5.4
 
  ___
  U-Boot mailing list
  U-Boot@lists.denx.de
  http://lists.denx.de/mailman/listinfo/u-boot
 
 
 
 --
 with warm regards,
 Chander Kashyap
 
 ___
 linaro-dev mailing list
 linaro-...@lists.linaro.org
 http://lists.linaro.org/mailman/listinfo/linaro-dev

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH v3 RESEND] ARMV7: Exynos4: Add support for TRATS board

2012-01-10 Thread HeungJun, Kim
This patch adds support for Samsung TRATS board

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
Changes for RESEND since v3
  - Add prefix board_ for board functions
  - Rename setup.h from trats_setup.h
  - Remove *_OFFSET in setup.h
  - Remove GPIO and UART definitions in setup.h

 MAINTAINERS  |4 +
 board/samsung/trats/Makefile |   43 +++
 board/samsung/trats/setup.h  |  617 ++
 board/samsung/trats/trats.c  |  348 
 boards.cfg   |1 +
 include/configs/trats.h  |  216 +++
 6 files changed, 1229 insertions(+), 0 deletions(-)
 create mode 100644 board/samsung/trats/Makefile
 create mode 100644 board/samsung/trats/setup.h
 create mode 100644 board/samsung/trats/trats.c
 create mode 100644 include/configs/trats.h

diff --git a/MAINTAINERS b/MAINTAINERS
index 4bf12b5..60314a6 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -706,6 +706,10 @@ Chander Kashyap k.chan...@samsung.com
origen  ARM ARMV7 (EXYNOS4210 SoC)
SMDKV310ARM ARMV7 (EXYNOS4210 SoC)
 
+Heungjun Kim riverful@samsung.com
+
+   trats   ARM ARMV7 (EXYNOS4210 SoC)
+
 Torsten Koschorrek koschor...@synertronixx.de
scb9328 ARM920T (i.MXL)
 
diff --git a/board/samsung/trats/Makefile b/board/samsung/trats/Makefile
new file mode 100644
index 000..d21883f
--- /dev/null
+++ b/board/samsung/trats/Makefile
@@ -0,0 +1,43 @@
+#
+# Copyright (C) 2011 Samsung Electronics
+# Heungjun Kim riverful@samsung.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
+#
+
+include $(TOPDIR)/config.mk
+
+LIB= $(obj)lib$(BOARD).o
+
+COBJS-y+= trats.o
+
+SRCS:= $(COBJS-y:.o=.c)
+OBJS   := $(addprefix $(obj),$(COBJS-y))
+
+$(LIB):$(obj).depend $(OBJS)
+   $(call cmd_link_o_target, $(OBJS))
+
+#
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+#
diff --git a/board/samsung/trats/setup.h b/board/samsung/trats/setup.h
new file mode 100644
index 000..7520765
--- /dev/null
+++ b/board/samsung/trats/setup.h
@@ -0,0 +1,617 @@
+/*
+ * Machine Specific Values for TRATS board based on EXYNOS4210
+ *
+ * Copyright (C) 2011 Samsung Electronics
+ * Heungjun Kim riverful@samsung.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
+ */
+
+#ifndef _TRATS_SETUP_H
+#define _TRATS_SETUP_H
+
+#include config.h
+#include version.h
+#include asm/arch/cpu.h
+
+/* CLK_SRC_CPU: APLL(1), MPLL(1), CORE(0), HPM(0) */
+#define MUX_HPM_SEL_MOUTAPLL   0x0
+#define MUX_HPM_SEL_SCLKMPLL   0x1
+#define MUX_CORE_SEL_MOUTAPLL  0x0
+#define MUX_CORE_SEL_SCLKMPLL  0x1
+#define MUX_MPLL_SEL_FILPLL0x0
+#define MUX_MPLL_SEL_MOUTMPLLFOUT  0x1
+#define MUX_APLL_SEL_FILPLL0x0
+#define MUX_APLL_SEL_MOUTMPLLFOUT  0x1
+#define CLK_SRC_CPU_VAL((MUX_HPM_SEL_MOUTAPLL  20) \
+   | (MUX_CORE_SEL_MOUTAPLL  16) \
+   | (MUX_MPLL_SEL_MOUTMPLLFOUT  8)\
+   | (MUX_APLL_SEL_MOUTMPLLFOUT  0))
+
+/* CLK_DIV_CPU0 */
+#define APLL_RATIO 0x0
+#define

[U-Boot] [PATCH v3 RESEND 3/3] ARMV7: Exynos4: Add support for TRATS board

2012-01-10 Thread HeungJun, Kim
This patch adds support for Samsung TRATS board

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
Changes for RESEND since v3
  - Add prefix board_ for board functions
  - Rename setup.h from trats_setup.h
  - Remove *_OFFSET in setup.h
  - Remove GPIO and UART definitions in setup.h

 MAINTAINERS  |4 +
 board/samsung/trats/Makefile |   43 +++
 board/samsung/trats/setup.h  |  617 ++
 board/samsung/trats/trats.c  |  348 
 boards.cfg   |1 +
 include/configs/trats.h  |  216 +++
 6 files changed, 1229 insertions(+), 0 deletions(-)
 create mode 100644 board/samsung/trats/Makefile
 create mode 100644 board/samsung/trats/setup.h
 create mode 100644 board/samsung/trats/trats.c
 create mode 100644 include/configs/trats.h

diff --git a/MAINTAINERS b/MAINTAINERS
index 4bf12b5..60314a6 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -706,6 +706,10 @@ Chander Kashyap k.chan...@samsung.com
origen  ARM ARMV7 (EXYNOS4210 SoC)
SMDKV310ARM ARMV7 (EXYNOS4210 SoC)
 
+Heungjun Kim riverful@samsung.com
+
+   trats   ARM ARMV7 (EXYNOS4210 SoC)
+
 Torsten Koschorrek koschor...@synertronixx.de
scb9328 ARM920T (i.MXL)
 
diff --git a/board/samsung/trats/Makefile b/board/samsung/trats/Makefile
new file mode 100644
index 000..d21883f
--- /dev/null
+++ b/board/samsung/trats/Makefile
@@ -0,0 +1,43 @@
+#
+# Copyright (C) 2011 Samsung Electronics
+# Heungjun Kim riverful@samsung.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
+#
+
+include $(TOPDIR)/config.mk
+
+LIB= $(obj)lib$(BOARD).o
+
+COBJS-y+= trats.o
+
+SRCS:= $(COBJS-y:.o=.c)
+OBJS   := $(addprefix $(obj),$(COBJS-y))
+
+$(LIB):$(obj).depend $(OBJS)
+   $(call cmd_link_o_target, $(OBJS))
+
+#
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+#
diff --git a/board/samsung/trats/setup.h b/board/samsung/trats/setup.h
new file mode 100644
index 000..6667b8c
--- /dev/null
+++ b/board/samsung/trats/setup.h
@@ -0,0 +1,617 @@
+/*
+ * Machine Specific Values for TRATS board based on EXYNOS4210
+ *
+ * Copyright (C) 2011 Samsung Electronics
+ * Heungjun Kim riverful@samsung.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
+ */
+
+#ifndef _TRATS_SETUP_H
+#define _TRATS_SETUP_H
+
+#include config.h
+#include version.h
+#include asm/arch/cpu.h
+
+/* CLK_SRC_CPU: APLL(1), MPLL(1), CORE(0), HPM(0) */
+#define MUX_HPM_SEL_MOUTAPLL   0x0
+#define MUX_HPM_SEL_SCLKMPLL   0x1
+#define MUX_CORE_SEL_MOUTAPLL  0x0
+#define MUX_CORE_SEL_SCLKMPLL  0x1
+#define MUX_MPLL_SEL_FILPLL0x0
+#define MUX_MPLL_SEL_MOUTMPLLFOUT  0x1
+#define MUX_APLL_SEL_FILPLL0x0
+#define MUX_APLL_SEL_MOUTMPLLFOUT  0x1
+#define CLK_SRC_CPU_VAL((MUX_HPM_SEL_MOUTAPLL  20) \
+   | (MUX_CORE_SEL_MOUTAPLL  16) \
+   | (MUX_MPLL_SEL_MOUTMPLLFOUT  8)\
+   | (MUX_APLL_SEL_MOUTMPLLFOUT  0))
+
+/* CLK_DIV_CPU0 */
+#define APLL_RATIO 0x0
+#define

Re: [U-Boot] [PATCH V2] ARMV7: Add support for TRATS board

2012-01-08 Thread HeungJun, Kim
Hi Wolfgang Denk,

Sorry not to check the these documents. It's my mistake.
I have known that the another pull-request is needed after Acked by maintainers 
on ML. So, I sent by that way.

Ok, there is another comments by Minkyu Kang, so I send next version
after I fix these.

Thanks and Regards,
Heungjun Kim

 -Original Message-
 From: Wolfgang Denk [mailto:w...@denx.de]
 Sent: Saturday, January 07, 2012 8:23 AM
 To: HeungJun, Kim
 Cc: u-boot@lists.denx.de; kyungmin.p...@samsung.com; mk7.k...@samsung.com
 Subject: Re: [PATCH V2] ARMV7: Add support for TRATS board
 
 Dear HeungJun, Kim,
 
 In message 00bc0173$83da7820$8b8f6860$%k...@samsung.com you wrote:
 
  This is related with this:
  http://lists.denx.de/pipermail/u-boot/2012-January/114710.html
 
 Arghh... You should not need to include such information.  Proper mail
 threading isall we need.  But we really need it.
 
  And, I prepared version 2 patch modified with:
   1) sorting the list of the name in MAINTAINERS
   2) modifying to GPLv2+
   3) change assem code in lowlevel_init.S to C code in lowlevel_util.c
   4) do not defile values for variables if the variable is feature
   5) Remove miscellaneouses.
 
 Arghhh again.  Please stick to the rules.  The change log MUST be part
 of the patch submission itself.  For details please see
 http://www.denx.de/wiki/view/U-Boot/Patches#Sending_updated_patch_versions
 
 Best regards,
 
 Wolfgang Denk
 
 --
 DENX Software Engineering GmbH, MD: Wolfgang Denk  Detlev Zundel
 HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
 Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: w...@denx.de
 A star captain's most solemn oath is that he will give his life, even
 his entire crew, rather than violate the Prime Directive.
   -- Kirk, The Omega Glory, stardate unknown

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH V2] ARMV7: Add support for TRATS board

2012-01-08 Thread HeungJun, Kim
Hi Minkyu Kang,

Any other structures is existed in the arch/arm/include/asm/arch-exynos/*.
So, I'm fitting the codes at this. But,

 -Original Message-
 From: Minkyu Kang [mailto:proms...@gmail.com]
 Sent: Monday, January 09, 2012 11:42 AM
 To: HeungJun, Kim
 Cc: u-boot@lists.denx.de; kyungmin.p...@samsung.com; mk7.k...@samsung.com
 Subject: Re: [U-Boot] [PATCH V2] ARMV7: Add support for TRATS board
 
 Dear HeungJun, Kim,
 
 On 6 January 2012 21:55, HeungJun, Kim riverful@samsung.com wrote:
  This patch adds support for Samsung TRATS board
 
  Signed-off-by: HeungJun, Kim riverful@samsung.com
  Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
  ---
   MAINTAINERS                         |    4 +
   board/samsung/trats/Makefile        |   45 ++
   board/samsung/trats/lowlevel_init.S |   50 +++
   board/samsung/trats/lowlevel_util.c |  137 ++
   board/samsung/trats/trats.c         |  250 +++
   board/samsung/trats/trats_setup.h   |  812
 +++
   boards.cfg                          |    1 +
   include/configs/trats.h             |  216 ++
   8 files changed, 1515 insertions(+), 0 deletions(-)
   create mode 100644 board/samsung/trats/Makefile
   create mode 100644 board/samsung/trats/lowlevel_init.S
   create mode 100644 board/samsung/trats/lowlevel_util.c
   create mode 100644 board/samsung/trats/trats.c
   create mode 100644 board/samsung/trats/trats_setup.h
   create mode 100644 include/configs/trats.h
 
  diff --git a/board/samsung/trats/lowlevel_init.S
 b/board/samsung/trats/lowlevel_init.S
  new file mode 100644
  index 000..9159063
  --- /dev/null
  +++ b/board/samsung/trats/lowlevel_init.S
  @@ -0,0 +1,50 @@
  +/*
  + * Lowlevel setup for TRATS board based on EXYNOS4210
  + *
  + * Copyright (C) 2011 Samsung Electronics
  + * Heungjun Kim riverful@samsung.com
  + * Kyungmin Park kyungmin.p...@samsung.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
  + */
  +
  +#include config.h
  +#include version.h
  +#include asm/arch/cpu.h
  +#include asm/arch/clock.h
  +#include trats_setup.h
  +
  +       .globl pmu_init
  +       .globl uart_init
  +       .globl watchdog_disable
  +       .globl clock_init
  +       .globl pmic_reset
  +
  +       .globl lowlevel_init
  +lowlevel_init:
  +       push    {lr}
  +
  +       bl      pmic_reset              @ PMIC reset
  +       bl      clock_init              @ Init Clock
  +       bl      watchdog_disable        @ Disable Watchdog
  +       bl      uart_init               @ Init UART
  +       bl      pmu_init                @ Init PMU
  +
  +       pop     {pc}
  +       nop
  diff --git a/board/samsung/trats/lowlevel_util.c
 b/board/samsung/trats/lowlevel_util.c
  new file mode 100644
  index 000..d67a095
  --- /dev/null
  +++ b/board/samsung/trats/lowlevel_util.c
  @@ -0,0 +1,137 @@
  +/*
  + * Copyright (C) 2011 Samsung Electronics
  + * Heungjun Kim riverful@samsung.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
  + */
  +
  +#include common.h
  +#include asm/io.h
  +#include trats_setup.h
  +
  +void pmic_reset(void)
  +{
  +       u32 base = EXYNOS4_GPIO_PART2_BASE;
  +       u32 gpio;
  +
  +       gpio = readl(base + EXYNOS4_GPIO_X2_CON_OFFSET);
  +       gpio = ~EXYNOS4_GPIO_X2_CON_MASK;
  +       gpio |= EXYNOS4_GPIO_X2_CON_VAL;
  +       writel(EXYNOS4_GPIO_X2_CON_VAL, base

Re: [U-Boot] [PATCH V2] ARMV7: Add support for TRATS board

2012-01-08 Thread HeungJun, Kim
I missed one thing.

The watchdong SASMUNG_BASE() definitions is also not existed in the headers.

So, I can not put at this using structures, too.

Thanks and Regards,
Heungjun Kim


 -Original Message-
 From: u-boot-boun...@lists.denx.de [mailto:u-boot-boun...@lists.denx.de] On
 Behalf Of HeungJun, Kim
 Sent: Monday, January 09, 2012 3:06 PM
 To: 'Minkyu Kang'
 Cc: u-boot@lists.denx.de; kyungmin.p...@samsung.com; mk7.k...@samsung.com
 Subject: Re: [U-Boot] [PATCH V2] ARMV7: Add support for TRATS board
 
 Hi Minkyu Kang,
 
 Any other structures is existed in the arch/arm/include/asm/arch-exynos/*.
 So, I'm fitting the codes at this. But,
 
  -Original Message-
  From: Minkyu Kang [mailto:proms...@gmail.com]
  Sent: Monday, January 09, 2012 11:42 AM
  To: HeungJun, Kim
  Cc: u-boot@lists.denx.de; kyungmin.p...@samsung.com; mk7.k...@samsung.com
  Subject: Re: [U-Boot] [PATCH V2] ARMV7: Add support for TRATS board
 
  Dear HeungJun, Kim,
 
  On 6 January 2012 21:55, HeungJun, Kim riverful@samsung.com wrote:
   This patch adds support for Samsung TRATS board
  
   Signed-off-by: HeungJun, Kim riverful@samsung.com
   Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
   ---
    MAINTAINERS                         |    4 +
    board/samsung/trats/Makefile        |   45 ++
    board/samsung/trats/lowlevel_init.S |   50 +++
    board/samsung/trats/lowlevel_util.c |  137 ++
    board/samsung/trats/trats.c         |  250 +++
    board/samsung/trats/trats_setup.h   |  812
  +++
    boards.cfg                          |    1 +
    include/configs/trats.h             |  216 ++
    8 files changed, 1515 insertions(+), 0 deletions(-)
    create mode 100644 board/samsung/trats/Makefile
    create mode 100644 board/samsung/trats/lowlevel_init.S
    create mode 100644 board/samsung/trats/lowlevel_util.c
    create mode 100644 board/samsung/trats/trats.c
    create mode 100644 board/samsung/trats/trats_setup.h
    create mode 100644 include/configs/trats.h
  
   diff --git a/board/samsung/trats/lowlevel_init.S
  b/board/samsung/trats/lowlevel_init.S
   new file mode 100644
   index 000..9159063
   --- /dev/null
   +++ b/board/samsung/trats/lowlevel_init.S
   @@ -0,0 +1,50 @@
   +/*
   + * Lowlevel setup for TRATS board based on EXYNOS4210
   + *
   + * Copyright (C) 2011 Samsung Electronics
   + * Heungjun Kim riverful@samsung.com
   + * Kyungmin Park kyungmin.p...@samsung.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
   + */
   +
   +#include config.h
   +#include version.h
   +#include asm/arch/cpu.h
   +#include asm/arch/clock.h
   +#include trats_setup.h
   +
   +       .globl pmu_init
   +       .globl uart_init
   +       .globl watchdog_disable
   +       .globl clock_init
   +       .globl pmic_reset
   +
   +       .globl lowlevel_init
   +lowlevel_init:
   +       push    {lr}
   +
   +       bl      pmic_reset              @ PMIC reset
   +       bl      clock_init              @ Init Clock
   +       bl      watchdog_disable        @ Disable Watchdog
   +       bl      uart_init               @ Init UART
   +       bl      pmu_init                @ Init PMU
   +
   +       pop     {pc}
   +       nop
   diff --git a/board/samsung/trats/lowlevel_util.c
  b/board/samsung/trats/lowlevel_util.c
   new file mode 100644
   index 000..d67a095
   --- /dev/null
   +++ b/board/samsung/trats/lowlevel_util.c
   @@ -0,0 +1,137 @@
   +/*
   + * Copyright (C) 2011 Samsung Electronics
   + * Heungjun Kim riverful@samsung.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

[U-Boot] [PATCH V2] ARMV7: Add support for TRATS board

2012-01-06 Thread HeungJun, Kim
This patch adds support for Samsung TRATS board

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
 MAINTAINERS |4 +
 board/samsung/trats/Makefile|   45 ++
 board/samsung/trats/lowlevel_init.S |   50 +++
 board/samsung/trats/lowlevel_util.c |  137 ++
 board/samsung/trats/trats.c |  250 +++
 board/samsung/trats/trats_setup.h   |  812 +++
 boards.cfg  |1 +
 include/configs/trats.h |  216 ++
 8 files changed, 1515 insertions(+), 0 deletions(-)
 create mode 100644 board/samsung/trats/Makefile
 create mode 100644 board/samsung/trats/lowlevel_init.S
 create mode 100644 board/samsung/trats/lowlevel_util.c
 create mode 100644 board/samsung/trats/trats.c
 create mode 100644 board/samsung/trats/trats_setup.h
 create mode 100644 include/configs/trats.h

diff --git a/MAINTAINERS b/MAINTAINERS
index a56ca10..b760e7f 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -705,6 +705,10 @@ Chander Kashyap k.chan...@samsung.com
origen  ARM ARMV7 (EXYNOS4210 SoC)
SMDKV310ARM ARMV7 (EXYNOS4210 SoC)
 
+Heungjun Kim riverful@samsung.com
+
+   trats   ARM ARMV7 (EXYNOS4210 SoC)
+
 Torsten Koschorrek koschor...@synertronixx.de
scb9328 ARM920T (i.MXL)
 
diff --git a/board/samsung/trats/Makefile b/board/samsung/trats/Makefile
new file mode 100644
index 000..77bd4a8
--- /dev/null
+++ b/board/samsung/trats/Makefile
@@ -0,0 +1,45 @@
+#
+# Copyright (C) 2011 Samsung Electronics
+# Heungjun Kim riverful@samsung.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
+#
+
+include $(TOPDIR)/config.mk
+
+LIB= $(obj)lib$(BOARD).o
+
+COBJS-y:= trats.o lowlevel_util.o
+SOBJS  := lowlevel_init.o
+
+SRCS:= $(SOBJS:.o=.S) $(COBJS-y:.o=.c)
+OBJS   := $(addprefix $(obj),$(COBJS-y))
+SOBJS  := $(addprefix $(obj),$(SOBJS))
+
+$(LIB):$(obj).depend $(SOBJS) $(OBJS)
+   $(call cmd_link_o_target, $(SOBJS) $(OBJS))
+
+#
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+#
diff --git a/board/samsung/trats/lowlevel_init.S 
b/board/samsung/trats/lowlevel_init.S
new file mode 100644
index 000..9159063
--- /dev/null
+++ b/board/samsung/trats/lowlevel_init.S
@@ -0,0 +1,50 @@
+/*
+ * Lowlevel setup for TRATS board based on EXYNOS4210
+ *
+ * Copyright (C) 2011 Samsung Electronics
+ * Heungjun Kim riverful@samsung.com
+ * Kyungmin Park kyungmin.p...@samsung.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
+ */
+
+#include config.h
+#include version.h
+#include asm/arch/cpu.h
+#include asm/arch/clock.h
+#include trats_setup.h
+
+   .globl pmu_init
+   .globl uart_init
+   .globl watchdog_disable
+   .globl clock_init
+   .globl pmic_reset
+
+   .globl lowlevel_init
+lowlevel_init:
+   push{lr}
+
+   bl  pmic_reset  @ PMIC reset
+   bl  clock_init  @ Init Clock
+   bl  watchdog_disable@ Disable Watchdog
+   bl  uart_init   @ Init UART
+   bl  pmu_init@ Init PMU
+
+   pop {pc}
+   nop
diff --git a/board/samsung/trats/lowlevel_util.c 
b/board

Re: [U-Boot] [PATCH V2] ARMV7: Add support for TRATS board

2012-01-06 Thread HeungJun, Kim
Hi Wolfgang Denk,

This is related with this:
http://lists.denx.de/pipermail/u-boot/2012-January/114710.html

And, I prepared version 2 patch modified with:
 1) sorting the list of the name in MAINTAINERS
 2) modifying to GPLv2+
 3) change assem code in lowlevel_init.S to C code in lowlevel_util.c
 4) do not defile values for variables if the variable is feature
 5) Remove miscellaneouses.

Thanks and Regards,
Heungjun Kim

 -Original Message-
 From: HeungJun, Kim [mailto:riverful@samsung.com]
 Sent: Friday, January 06, 2012 9:55 PM
 To: u-boot@lists.denx.de
 Cc: w...@denx.de; kyungmin.p...@samsung.com; mk7.k...@samsung.com; HeungJun, 
 Kim
 Subject: [PATCH V2] ARMV7: Add support for TRATS board
 
 This patch adds support for Samsung TRATS board
 
 Signed-off-by: HeungJun, Kim riverful@samsung.com
 Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
 ---
  MAINTAINERS |4 +
  board/samsung/trats/Makefile|   45 ++
  board/samsung/trats/lowlevel_init.S |   50 +++
  board/samsung/trats/lowlevel_util.c |  137 ++
  board/samsung/trats/trats.c |  250 +++
  board/samsung/trats/trats_setup.h   |  812
+++
  boards.cfg  |1 +
  include/configs/trats.h |  216 ++
  8 files changed, 1515 insertions(+), 0 deletions(-)
  create mode 100644 board/samsung/trats/Makefile
  create mode 100644 board/samsung/trats/lowlevel_init.S
  create mode 100644 board/samsung/trats/lowlevel_util.c
  create mode 100644 board/samsung/trats/trats.c
  create mode 100644 board/samsung/trats/trats_setup.h
  create mode 100644 include/configs/trats.h
 
 diff --git a/MAINTAINERS b/MAINTAINERS
 index a56ca10..b760e7f 100644
 --- a/MAINTAINERS
 +++ b/MAINTAINERS
 @@ -705,6 +705,10 @@ Chander Kashyap k.chan...@samsung.com
   origen  ARM ARMV7 (EXYNOS4210 SoC)
   SMDKV310ARM ARMV7 (EXYNOS4210 SoC)
 
 +Heungjun Kim riverful@samsung.com
 +
 + trats   ARM ARMV7 (EXYNOS4210 SoC)
 +
  Torsten Koschorrek koschor...@synertronixx.de
   scb9328 ARM920T (i.MXL)
 
 diff --git a/board/samsung/trats/Makefile b/board/samsung/trats/Makefile
 new file mode 100644
 index 000..77bd4a8
 --- /dev/null
 +++ b/board/samsung/trats/Makefile
 @@ -0,0 +1,45 @@
 +#
 +# Copyright (C) 2011 Samsung Electronics
 +# Heungjun Kim riverful@samsung.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
 +#
 +
 +include $(TOPDIR)/config.mk
 +
 +LIB  = $(obj)lib$(BOARD).o
 +
 +COBJS-y  := trats.o lowlevel_util.o
 +SOBJS:= lowlevel_init.o
 +
 +SRCS:= $(SOBJS:.o=.S) $(COBJS-y:.o=.c)
 +OBJS := $(addprefix $(obj),$(COBJS-y))
 +SOBJS:= $(addprefix $(obj),$(SOBJS))
 +
 +$(LIB):  $(obj).depend $(SOBJS) $(OBJS)
 + $(call cmd_link_o_target, $(SOBJS) $(OBJS))
 +
 +#
 +
 +# defines $(obj).depend target
 +include $(SRCTREE)/rules.mk
 +
 +sinclude $(obj).depend
 +
 +#
 diff --git a/board/samsung/trats/lowlevel_init.S
 b/board/samsung/trats/lowlevel_init.S
 new file mode 100644
 index 000..9159063
 --- /dev/null
 +++ b/board/samsung/trats/lowlevel_init.S
 @@ -0,0 +1,50 @@
 +/*
 + * Lowlevel setup for TRATS board based on EXYNOS4210
 + *
 + * Copyright (C) 2011 Samsung Electronics
 + * Heungjun Kim riverful@samsung.com
 + * Kyungmin Park kyungmin.p...@samsung.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

[U-Boot] [PATCH] ARMV7: Add support for TRATS board

2012-01-05 Thread HeungJun, Kim
This patch adds support for Samsung TRATS board

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
 MAINTAINERS |4 +
 board/samsung/trats/Makefile|   44 
 board/samsung/trats/lowlevel_init.S |  284 +
 board/samsung/trats/trats.c |  246 +++
 board/samsung/trats/trats_setup.h   |  460 +++
 boards.cfg  |1 +
 include/configs/trats.h |  222 +
 7 files changed, 1261 insertions(+), 0 deletions(-)
 create mode 100644 board/samsung/trats/Makefile
 create mode 100644 board/samsung/trats/lowlevel_init.S
 create mode 100644 board/samsung/trats/trats.c
 create mode 100644 board/samsung/trats/trats_setup.h
 create mode 100644 include/configs/trats.h

diff --git a/MAINTAINERS b/MAINTAINERS
index a56ca10..c856c59 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -700,6 +700,10 @@ Minkyu Kang mk7.k...@samsung.com
s5p_goniARM ARMV7 (S5PC110 SoC)
s5pc210_universal   ARM ARMV7 (EXYNOS4210 SoC)
 
+Heungjun Kim riverful@samsung.com
+
+   trats   ARM ARMV7 (EXYNOS4210 SoC)
+
 Chander Kashyap k.chan...@samsung.com
 
origen  ARM ARMV7 (EXYNOS4210 SoC)
diff --git a/board/samsung/trats/Makefile b/board/samsung/trats/Makefile
new file mode 100644
index 000..5a31a7b
--- /dev/null
+++ b/board/samsung/trats/Makefile
@@ -0,0 +1,44 @@
+#
+# Copyright (C) 2010 Samsung Electronics
+# Heungjun Kim riverful@samsung.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 version 2 as
+# published by the Free Software Foundation.
+#
+# 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
+#
+
+include $(TOPDIR)/config.mk
+
+LIB= $(obj)lib$(BOARD).o
+
+COBJS-y:= trats.o
+SOBJS  := lowlevel_init.o
+
+SRCS:= $(SOBJS:.o=.S) $(COBJS-y:.o=.c)
+OBJS   := $(addprefix $(obj),$(COBJS-y))
+SOBJS  := $(addprefix $(obj),$(SOBJS))
+
+$(LIB):$(obj).depend $(SOBJS) $(OBJS)
+   $(call cmd_link_o_target, $(SOBJS) $(OBJS))
+
+#
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+#
diff --git a/board/samsung/trats/lowlevel_init.S 
b/board/samsung/trats/lowlevel_init.S
new file mode 100644
index 000..7b8e15b
--- /dev/null
+++ b/board/samsung/trats/lowlevel_init.S
@@ -0,0 +1,284 @@
+/*
+ * Lowlevel setup for TRATS board based on EXYNOS4210
+ *
+ * Copyright (C) 2010 Samsung Electronics
+ * Heungjun Kim riverful@samsung.com
+ * Kyungmin Park kyungmin.p...@samsung.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 version 2 as
+ * published by the Free Software Foundation.
+ *
+ * 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
+ */
+
+#include config.h
+#include version.h
+#include asm/arch/cpu.h
+#include asm/arch/clock.h
+#include trats_setup.h
+
+/*
+ * Register usages:
+ *
+ * r5 has zero always
+ * r7 has GPIO part1 base 0x1140
+ * r6 has GPIO part2 base 0x1100
+ */
+
+   .globl lowlevel_init
+lowlevel_init:
+   push{lr}
+
+   /* r5 has always zero */
+   mov r5, #0
+   ldr r7, =EXYNOS4_GPIO_PART1_BASE
+   ldr r6, =EXYNOS4_GPIO_PART2_BASE
+
+   /*
+* PMIC manual reset
+* nPOWER: XEINT_23: GPX2[7]
+*/
+   ldr r1, =EXYNOS4_GPIO_X2_CON_VAL
+   str r1, [r6, #EXYNOS4_GPIO_X2_CON_OFFSET]
+   ldr r1, =EXYNOS4_GPIO_X2_DAT_VAL
+   str r1, [r6, #EXYNOS4_GPIO_X2_DAT_OFFSET]
+
+   /* init system clock */
+   bl  system_clock_init
+
+   /* Disable Watchdog */
+   ldr r0

[U-Boot] [PATCH] ARMV7: Add support for TRATS board

2012-01-05 Thread HeungJun, Kim
This patch adds support for Samsung TRATS board

Signed-off-by: HeungJun, Kim riverful@samsung.com
Signed-off-by: Kyungmin Park kyungmin.p...@samsung.com
---
 MAINTAINERS |4 +
 board/samsung/trats/Makefile|   44 
 board/samsung/trats/lowlevel_init.S |  284 +
 board/samsung/trats/trats.c |  246 +++
 board/samsung/trats/trats_setup.h   |  460 +++
 boards.cfg  |1 +
 include/configs/trats.h |  222 +
 7 files changed, 1261 insertions(+), 0 deletions(-)
 create mode 100644 board/samsung/trats/Makefile
 create mode 100644 board/samsung/trats/lowlevel_init.S
 create mode 100644 board/samsung/trats/trats.c
 create mode 100644 board/samsung/trats/trats_setup.h
 create mode 100644 include/configs/trats.h

diff --git a/MAINTAINERS b/MAINTAINERS
index a56ca10..c856c59 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -700,6 +700,10 @@ Minkyu Kang mk7.k...@samsung.com
s5p_goniARM ARMV7 (S5PC110 SoC)
s5pc210_universal   ARM ARMV7 (EXYNOS4210 SoC)
 
+Heungjun Kim riverful@samsung.com
+
+   trats   ARM ARMV7 (EXYNOS4210 SoC)
+
 Chander Kashyap k.chan...@samsung.com
 
origen  ARM ARMV7 (EXYNOS4210 SoC)
diff --git a/board/samsung/trats/Makefile b/board/samsung/trats/Makefile
new file mode 100644
index 000..5a31a7b
--- /dev/null
+++ b/board/samsung/trats/Makefile
@@ -0,0 +1,44 @@
+#
+# Copyright (C) 2010 Samsung Electronics
+# Heungjun Kim riverful@samsung.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 version 2 as
+# published by the Free Software Foundation.
+#
+# 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
+#
+
+include $(TOPDIR)/config.mk
+
+LIB= $(obj)lib$(BOARD).o
+
+COBJS-y:= trats.o
+SOBJS  := lowlevel_init.o
+
+SRCS:= $(SOBJS:.o=.S) $(COBJS-y:.o=.c)
+OBJS   := $(addprefix $(obj),$(COBJS-y))
+SOBJS  := $(addprefix $(obj),$(SOBJS))
+
+$(LIB):$(obj).depend $(SOBJS) $(OBJS)
+   $(call cmd_link_o_target, $(SOBJS) $(OBJS))
+
+#
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+#
diff --git a/board/samsung/trats/lowlevel_init.S 
b/board/samsung/trats/lowlevel_init.S
new file mode 100644
index 000..7b8e15b
--- /dev/null
+++ b/board/samsung/trats/lowlevel_init.S
@@ -0,0 +1,284 @@
+/*
+ * Lowlevel setup for TRATS board based on EXYNOS4210
+ *
+ * Copyright (C) 2010 Samsung Electronics
+ * Heungjun Kim riverful@samsung.com
+ * Kyungmin Park kyungmin.p...@samsung.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 version 2 as
+ * published by the Free Software Foundation.
+ *
+ * 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
+ */
+
+#include config.h
+#include version.h
+#include asm/arch/cpu.h
+#include asm/arch/clock.h
+#include trats_setup.h
+
+/*
+ * Register usages:
+ *
+ * r5 has zero always
+ * r7 has GPIO part1 base 0x1140
+ * r6 has GPIO part2 base 0x1100
+ */
+
+   .globl lowlevel_init
+lowlevel_init:
+   push{lr}
+
+   /* r5 has always zero */
+   mov r5, #0
+   ldr r7, =EXYNOS4_GPIO_PART1_BASE
+   ldr r6, =EXYNOS4_GPIO_PART2_BASE
+
+   /*
+* PMIC manual reset
+* nPOWER: XEINT_23: GPX2[7]
+*/
+   ldr r1, =EXYNOS4_GPIO_X2_CON_VAL
+   str r1, [r6, #EXYNOS4_GPIO_X2_CON_OFFSET]
+   ldr r1, =EXYNOS4_GPIO_X2_DAT_VAL
+   str r1, [r6, #EXYNOS4_GPIO_X2_DAT_OFFSET]
+
+   /* init system clock */
+   bl  system_clock_init
+
+   /* Disable Watchdog */
+   ldr r0

Re: [U-Boot] [PATCH 1/6] S5PC100: Samsung S5PC100 SoC support

2009-07-08 Thread HeungJun Kim
Mr. Jean,

Yes. Definitely.
To send the new version patch may be so late,
cause of my busy days, not my laziness.

BTW, is there any issues or problem?
If there is, can you tell me about that things for me to handle it?
I hope your waiting a few days.
sorry for that.

Best regards,
riverful

2009/7/8, Jean-Christophe PLAGNIOL-VILLARD plagn...@jcrosoft.com:
 On 17:05 Thu 25 Jun , HeungJun Kim wrote:
 S5PC100 processor is ARM Cortex A8 Processor SoC
 and SMDKC100 Board use this.
 So, this patch tested on SMDKC100 Board.

 I'll send 6 patch for working on SMDKC100 Board including this.
 But, this patch make the change to ARM Cortex A8 specific code
 like a cpu/arm_cortexa8/cpu.c, start.S.

 So, I wanna be reviewed to know how to contribute this whole patch.

 CC: Dirk Behme dirk.behme at googlemail.com
 Signed-off-by: HeungJun, Kim riverful@samsung.com

 ---
 do you plan to send a new version?

 Best Regards,
 J.

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH] MTD: change env_address type from unsigned long to loff_t

2009-06-29 Thread HeungJun Kim
If use the onenand boot, the env_relocate_spec() calls mtd-read(),
and the type of the argument #2 of mtd-read() was changed to loff_t.
But, the env_addr type is still unsigned long, thus this patch change
the type from unsigned long to loff_t.

Acked-by: Kyungmin Park kyungmin.p...@samsung.com
Signed-off-by: HeungJun, Kim riverful@samsung.com

---

 common/env_onenand.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/common/env_onenand.c b/common/env_onenand.c
index ed77051..48089a9 100644
--- a/common/env_onenand.c
+++ b/common/env_onenand.c
@@ -58,7 +58,7 @@ uchar env_get_char_spec(int index)

 void env_relocate_spec(void)
 {
-   unsigned long env_addr;
+   loff_t env_addr;
int use_default = 0;
size_t retlen;

-- 
1.5.6.3
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH 3/6] S5PC100: serial driver for SMDKC100 support

2009-06-25 Thread HeungJun Kim
This patch is the serial driver for S5PC100  SMDKC100.

Signed-off-by: HeungJun, Kim riverful@samsung.com

---

 drivers/serial/Makefile |1 +
 drivers/serial/serial_s5pc100.c |  179 +++
 2 files changed, 180 insertions(+), 0 deletions(-)
 create mode 100644 drivers/serial/serial_s5pc100.c

diff --git a/drivers/serial/Makefile b/drivers/serial/Makefile
index 64882a2..3334442 100644
--- a/drivers/serial/Makefile
+++ b/drivers/serial/Makefile
@@ -49,6 +49,7 @@ COBJS-$(CONFIG_PXA_SERIAL) += serial_pxa.o
 COBJS-$(CONFIG_SA1100_SERIAL) += serial_sa1100.o
 COBJS-$(CONFIG_S3C24X0_SERIAL) += serial_s3c24x0.o
 COBJS-$(CONFIG_S3C44B0_SERIAL) += serial_s3c44b0.o
+COBJS-$(CONFIG_S5PC100_SERIAL) += serial_s5pc100.o
 COBJS-$(CONFIG_XILINX_UARTLITE) += serial_xuartlite.o
 COBJS-$(CONFIG_SCIF_CONSOLE) += serial_sh.o
 COBJS-$(CONFIG_USB_TTY) += usbtty.o
diff --git a/drivers/serial/serial_s5pc100.c b/drivers/serial/serial_s5pc100.c
new file mode 100644
index 000..9394e77
--- /dev/null
+++ b/drivers/serial/serial_s5pc100.c
@@ -0,0 +1,179 @@
+/*
+ * (C) Copyright 2009
+ * Inki Dae, SAMSUNG Electronics, inki@samsung.com
+ * Heungjun Kim, SAMSUNG Electronics, riverful@samsung.com
+ * Minkyu Kang, SAMSUNG Electronics, mk7.k...@samsung.com
+ *
+ * (C) Copyright 2002
+ * Gary Jennejohn, DENX Software Engineering, g...@denx.de
+ *
+ * (C) Copyright 2008
+ * Guennadi Liakhovetki, DENX Software Engineering, l...@denx.de
+ *
+ * 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
+ *
+ */
+
+#include common.h
+
+#ifdef CONFIG_SERIAL0
+#define UART_NRS5PC1XX_UART0
+#elif defined(CONFIG_SERIAL1)
+#define UART_NRS5PC1XX_UART1
+#elif defined(CONFIG_SERIAL2)
+#define UART_NRS5PC1XX_UART2
+#elif defined(CONFIG_SERIAL3)
+#define UART_NRS5PC1XX_UART3
+#else
+#error Bad: you didn't configure serial ...
+#endif
+
+#define barrier() asm volatile( ::: memory)
+
+static inline s5pc1xx_uart_t *s5pc1xx_get_base_uart(enum s5pc1xx_uarts_nr nr)
+{
+   return (s5pc1xx_uart_t *)(S5P_UART_BASE + (nr * 0x400));
+}
+
+/*
+ * The coefficient, used to calculate the baudrate on S5PC1XX UARTs is
+ * calculated as
+ * C = UBRDIV * 16 + number_of_set_bits_in_UDIVSLOT
+ * however, section 31.6.11 of the datasheet doesn't recomment using 1 for 1,
+ * 3 for 2, ... (2^n - 1) for n, instead, they suggest using these constants:
+ */
+static const int udivslot[] = {
+   0,
+   0x0080,
+   0x0808,
+   0x0888,
+   0x,
+   0x4924,
+   0x4a52,
+   0x54aa,
+   0x,
+   0xd555,
+   0xd5d5,
+   0xddd5,
+   0x,
+   0xdfdd,
+   0xdfdf,
+   0xffdf,
+};
+
+void serial_setbrg(void)
+{
+   DECLARE_GLOBAL_DATA_PTR;
+   s5pc1xx_uart_t *const uart = s5pc1xx_get_base_uart(UART_NR);
+   u32 pclk = get_PCLK();
+   u32 baudrate = gd-baudrate;
+   int i;
+
+   i = (pclk / baudrate) % 16;
+
+   uart-UBRDIV = pclk / baudrate / 16 - 1;
+   uart-UDIVSLOT = udivslot[i];
+
+   for (i = 0; i  100; i++);
+   barrier();
+}
+
+/*
+ * Initialise the serial port with the given baudrate. The settings
+ * are always 8 data bits, no parity, 1 stop bit, no start bits.
+ */
+int serial_init(void)
+{
+   s5pc1xx_uart_t *const uart = s5pc1xx_get_base_uart(UART_NR);
+
+   /* reset and enable FIFOs, set triggers to the maximum */
+   uart-UFCON = 0;
+   uart-UMCON = 0;
+   /* 8N1 */
+   uart-ULCON = 0x3;
+   /* No interrupts, no DMA, pure polling */
+   uart-UCON = 0x245;
+
+   serial_setbrg();
+
+   return 0;
+}
+
+/*
+ * Read a single byte from the serial port. Returns 1 on success, 0
+ * otherwise. When the function is succesfull, the character read is
+ * written into its argument c.
+ */
+int serial_getc(void)
+{
+   s5pc1xx_uart_t *const uart = s5pc1xx_get_base_uart(UART_NR);
+
+   /* wait for character to arrive */
+   while (!(uart-UTRSTAT  0x1));
+
+   return uart-URXH  0xff;
+}
+
+#ifdef CONFIG_MODEM_SUPPORT
+static int be_quiet;
+void disable_putc(void)
+{
+   be_quiet = 1;
+}
+
+void enable_putc(void)
+{
+   be_quiet = 0;
+}
+#endif
+
+
+/*
+ * Output a single byte to the serial port.
+ */
+void serial_putc(const char c)
+{
+   s5pc1xx_uart_t *const uart

[U-Boot] [PATCH 2/6] S5PC100: SMDKC100 Board support

2009-06-25 Thread HeungJun Kim
This patch initializes DRAM memory, OneNAND,  Board specific functions.
Also, it includes SMDKC100 configuration file  modification of Makefile.

Signed-off-by: HeungJun, Kim riverful@samsung.com

---

 Makefile   |5 +
 board/samsung/smdkc100/Makefile|   54 +++
 board/samsung/smdkc100/config.mk   |   24 +++
 board/samsung/smdkc100/lowlevel_init.S |  215 
 board/samsung/smdkc100/mem_setup.S |  197 ++
 board/samsung/smdkc100/onenand.c   |   78 ++
 board/samsung/smdkc100/smdkc100.c  |   70 +
 board/samsung/smdkc100/u-boot.lds  |   63 
 include/configs/s5pc100_smdkc100.h |  244 
 9 files changed, 950 insertions(+), 0 deletions(-)
 create mode 100644 board/samsung/smdkc100/Makefile
 create mode 100644 board/samsung/smdkc100/config.mk
 create mode 100644 board/samsung/smdkc100/lowlevel_init.S
 create mode 100644 board/samsung/smdkc100/mem_setup.S
 create mode 100644 board/samsung/smdkc100/onenand.c
 create mode 100644 board/samsung/smdkc100/smdkc100.c
 create mode 100644 board/samsung/smdkc100/u-boot.lds
 create mode 100644 include/configs/s5pc100_smdkc100.h

diff --git a/Makefile b/Makefile
index ebb12e9..cba7517 100644
--- a/Makefile
+++ b/Makefile
@@ -3034,6 +3034,11 @@ omap3_zoom1_config : unconfig
 omap3_zoom2_config :   unconfig
@$(MKCONFIG) $(@:_config=) arm arm_cortexa8 zoom2 omap3 omap3

+s5pc100_smdkc100_config:   unconfig
+   @echo #define CONFIG_ONENAND_U_BOOT  $(obj)include/config.h
+   @$(MKCONFIG) $(@:_config=) arm arm_cortexa8 smdkc100 samsung s5pc100
+   @echo CONFIG_ONENAND_U_BOOT = y  $(obj)include/config.mk
+
 #
 ## XScale Systems
 #
diff --git a/board/samsung/smdkc100/Makefile b/board/samsung/smdkc100/Makefile
new file mode 100644
index 000..7d0b6b0
--- /dev/null
+++ b/board/samsung/smdkc100/Makefile
@@ -0,0 +1,54 @@
+#
+# (C) Copyright 2000, 2001, 2002
+# Wolfgang Denk, DENX Software Engineering, w...@denx.de.
+#
+# (C) Copyright 2008
+# Guennadi Liakhovetki, DENX Software Engineering, l...@denx.de
+#
+# 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
+#
+
+include $(TOPDIR)/config.mk
+
+LIB= $(obj)lib$(BOARD).a
+
+COBJS-y:= smdkc100.o onenand.o
+SOBJS  := lowlevel_init.o
+
+SRCS:= $(SOBJS:.o=.S) $(COBJS-y:.o=.c)
+OBJS   := $(addprefix $(obj),$(COBJS-y))
+SOBJS  := $(addprefix $(obj),$(SOBJS))
+
+$(LIB):$(obj).depend $(SOBJS) $(OBJS)
+   $(AR) $(ARFLAGS) $@ $(SOBJS) $(OBJS)
+
+clean:
+   rm -f $(SOBJS) $(OBJS)
+
+distclean: clean
+   rm -f $(LIB) core *.bak $(obj).depend
+
+#
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+#
diff --git a/board/samsung/smdkc100/config.mk b/board/samsung/smdkc100/config.mk
new file mode 100644
index 000..51c8149
--- /dev/null
+++ b/board/samsung/smdkc100/config.mk
@@ -0,0 +1,24 @@
+#
+# (C) Copyright 2002
+# Gary Jennejohn, DENX Software Engineering, g...@denx.de
+# David Mueller, ELSOFT AG, d.muel...@elsoft.ch
+#
+# (C) Copyright 2008
+# Guennadi Liakhovetki, DENX Software Engineering, l...@denx.de
+#
+# SAMSUNG SMDK6400 board with mDirac3 (ARM1176) cpu
+#
+# see http://www.samsung.com/ for more information on SAMSUNG
+
+# On SMDK6400 we use the 64 MB SDRAM bank at
+#
+# 0x5000 to 0x5800
+#
+# Linux-Kernel is expected to be at 0x50008000, entry 0x50008000
+#
+# we load ourselves to 0x57e0 without MMU
+# with MMU, load address is changed to 0xc7e0
+#
+# download area is 0x5000c000
+
+TEXT_BASE = 0x2480
diff --git a/board/samsung/smdkc100/lowlevel_init.S
b/board/samsung/smdkc100/lowlevel_init.S
new file mode 100644
index 000..3bdee58
--- /dev/null
+++ b/board/samsung/smdkc100/lowlevel_init.S
@@ -0,0 +1,215 @@
+/*
+ * Memory Setup stuff - taken from blob memsetup.S
+ *
+ * Copyright (C) 2009 Samsung Electronics
+ * Kyungmin Park

[U-Boot] [PATCH 5/6] S5PC100: MTD: change env_address type

2009-06-25 Thread HeungJun Kim
This patch changed the type from unsigned long to loff_t in the
common/env_onenand.c.

The address type is changed from unsigned long to loff_t,
but common/env_onenand.c is not yet. So, this patch is needed
to get the accurate value of env_addr.

Signed-off-by: HeungJun, Kim riverful@samsung.com

---

The env_relocate() in the common/env_common.c calls
the env_relocate_spec() in the env_relocate_spec(),
if use the onenand boot.
But, env_addr's type is still unsigned long, thus it needed
to be changed to loff_t.

 common/env_onenand.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/common/env_onenand.c b/common/env_onenand.c
index ed77051..48089a9 100644
--- a/common/env_onenand.c
+++ b/common/env_onenand.c
@@ -58,7 +58,7 @@ uchar env_get_char_spec(int index)

 void env_relocate_spec(void)
 {
-   unsigned long env_addr;
+   loff_t env_addr;
int use_default = 0;
size_t retlen;

-- 
1.5.6.3
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


[U-Boot] [PATCH 6/6] S5PC100: Add onenand_ipl for SMDKC100 support

2009-06-25 Thread HeungJun Kim
The SMDKC100 Board has 256MB onenand.
So, It's bootable, if this patch is adapted thus the board use onenand_ipl.

Signed-off-by: HeungJun, Kim riverful@samsung.com

---

This patch support onenand boot on SMDKC100 Board.

 onenand_ipl/board/samsung/smdkc100/Makefile|   95 
 .../board/samsung/smdkc100/u-boot-onenand.lds  |   53 +++
 onenand_ipl/onenand_ipl.h  |   11 +++
 onenand_ipl/onenand_read.c |   18 
 4 files changed, 177 insertions(+), 0 deletions(-)
 create mode 100644 onenand_ipl/board/samsung/smdkc100/Makefile
 create mode 100644 onenand_ipl/board/samsung/smdkc100/u-boot-onenand.lds

diff --git a/onenand_ipl/board/samsung/smdkc100/Makefile
b/onenand_ipl/board/samsung/smdkc100/Makefile
new file mode 100644
index 000..4301938
--- /dev/null
+++ b/onenand_ipl/board/samsung/smdkc100/Makefile
@@ -0,0 +1,95 @@
+#
+#  Samsung SMDKC100(S5PC100) board OneNAND IPL
+#
+#  Copyright (C) 2009 Samsung Electronics
+#  Minkyu Kang mk7.k...@samsung.com
+#
+# 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.
+#
+
+include $(TOPDIR)/config.mk
+TEXT_BASE = 0xD0034000
+TEXT_BASE2K = 0xD0034800
+TEXT_BASE4K = 0xD0035000
+
+LDSCRIPT= $(TOPDIR)/onenand_ipl/board/$(BOARDDIR)/u-boot-onenand.lds
+LDFLAGS= -Bstatic -T $(LDSCRIPT) -Ttext $(TEXT_BASE) 
$(PLATFORM_LDFLAGS)
+AFLAGS += -DCONFIG_ONENAND_IPL -g
+CFLAGS += -DCONFIG_ONENAND_IPL -g
+OBJCFLAGS += --gap-fill=0x00
+
+SOBJS  := lowlevel_init.o mem_setup.o
+SOBJS  += start.o
+COBJS  += onenand_read.o
+COBJS  += onenand_boot.o
+
+SRCS   := $(addprefix $(obj),$(SOBJS:.o=.S) $(COBJS:.o=.c))
+OBJS   := $(addprefix $(obj),$(SOBJS) $(COBJS))
+__OBJS := $(SOBJS) $(COBJS)
+LNDIR  := $(OBJTREE)/onenand_ipl/board/$(BOARDDIR)
+
+onenandobj := $(OBJTREE)/onenand_ipl/
+
+ALL= $(onenandobj)onenand-ipl $(onenandobj)onenand-ipl.bin
$(onenandobj)onenand-ipl-2k.bin $(onenandobj)onenand-ipl-4k.bin
+
+all:   $(obj).depend $(ALL)
+
+$(onenandobj)onenand-ipl-2k.bin:   $(onenandobj)onenand-ipl
+   $(OBJCOPY) ${OBJCFLAGS} --pad-to=$(TEXT_BASE2K) -O binary $ $@
+
+$(onenandobj)onenand-ipl-4k.bin:   $(onenandobj)onenand-ipl
+   $(OBJCOPY) ${OBJCFLAGS} --pad-to=$(TEXT_BASE4K) -O binary $ $@
+
+$(onenandobj)onenand-ipl.bin:  $(onenandobj)onenand-ipl
+   $(OBJCOPY) ${OBJCFLAGS} -O binary $ $@
+
+$(onenandobj)onenand-ipl:  $(OBJS)
+   cd $(LNDIR)  $(LD) $(LDFLAGS) $$UNDEF_SYM $(__OBJS) \
+   -Map $...@.map -o $@
+
+# create symbolic links from common files
+
+# from cpu directory
+$(obj)start.S:
+   @rm -f $@
+   ln -s $(SRCTREE)/cpu/$(CPU)/start.S $@
+
+$(obj)mem_setup.S:
+   ln -sf $(SRCTREE)/board/$(BOARDDIR)/mem_setup.S $@
+
+$(obj)lowlevel_init.S:
+   ln -sf $(SRCTREE)/board/$(BOARDDIR)/lowlevel_init.S $@
+
+# from onenand_ipl directory
+$(obj)onenand_ipl.h:
+   @rm -f $@
+   ln -s $(SRCTREE)/onenand_ipl/onenand_ipl.h $@
+
+$(obj)onenand_boot.c:  $(obj)onenand_ipl.h
+   @rm -f $@
+   ln -s $(SRCTREE)/onenand_ipl/onenand_boot.c $@
+
+$(obj)onenand_read.c:  $(obj)onenand_ipl.h
+   @rm -f $@
+   ln -s $(SRCTREE)/onenand_ipl/onenand_read.c $@
+
+#
+
+$(obj)%.o: $(obj)%.S
+   $(CC) $(AFLAGS) -c -o $@ $
+
+$(obj)%.o: $(obj)$.c
+   $(CC) $(CFLAGS) -c -o $@ $
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+clean:
+   rm onenand_boot.c onenand_read.c
+
+#
diff --git a/onenand_ipl/board/samsung/smdkc100/u-boot-onenand.lds
b/onenand_ipl/board/samsung/smdkc100/u-boot-onenand.lds
new file mode 100644
index 000..559f9f2
--- /dev/null
+++ b/onenand_ipl/board/samsung/smdkc100/u-boot-onenand.lds
@@ -0,0 +1,53 @@
+/*
+ * (C) Copyright 2005-2008 Samsung Electronics
+ * Kyungmin Park kyungmin.p...@samsung.com
+ *
+ * Derived from X-loader
+ *
+ * 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

Re: [U-Boot] REJECT: Too many recipients to the message

2009-06-01 Thread HeungJun, Kim
Dear Wolfgang  everyone,

It happened ”Too many recipients to the message”, and I'm very sorry that my 
messages's many CC cause this event. 

Before that, I didn't find the recipients # limits on the u-boot mailinglist 
guidelines. So, I just send the messages like other my situation.

If It's hard to configure mailing list server, I think the warnning about“The 
limit of CC” is showed on the u-boot mailinglist guidlines or anywhere.

Thanks  Sorry.

Best Regards,
Riverful


- 원본 메시지 -
보낸 사람: T Ziomek ctz...@email.mot.com
보낸 날짜: 2009년 6월 2일 화요일 오전 9:09
받는 사람: Wolfgang Denk w...@denx.de
참조: Scott Wood scottw...@freescale.com; u-boot@lists.denx.de
제목: Re: [U-Boot] REJECT: Too many recipients to the message

On Tue, Jun 02, 2009 at 12:00:21AM +0200, Wolfgang Denk wrote:
 Dear T Ziomek,
 
 In message 20090601210846.gj8...@email.mot.com you wrote:
 
  How about reconfiguring the list software instead?
 
 I see no reason for that yet.
  
  I see no reason, at least none articulated as of yet, for the current
  configuration.
 
 The current configurations is (1) the default one,

Unless there's a good reason it's the default, I wouldn't defer to that
in the presence of good arguments otherwise.

and (2) pretty
 useful to detect list abuse that has not been cought yet by other
 means.

What sort(s) of abuse has configuration this helped catch?

   We neever before had any such problems. Currently  these  are  caused
   because  some  messages have 5 (or more) samsung.com addresses listed
   on Cc:; for example,  [PATCH]  The  omap3  L2  cache  enable/disable
   function to omap3 dependent code has 6 such addresses on Cc:
  
  And what problem does that cause?
 
 Such messages need manual moderation which (1) delays the messages and
 (2) causes additional work to the list moderator (me).

But that's a problem caused by the list server's config, not inherently
by the # of CCs.

   I doubt that this is really  necessary.
  
  Necessary is in the eye of the beholder here.  And IMHO the presump-
  tion should be that the sender of an email is addressing it properly.
  Absent either (a) clear, significant abuse of emails' recipients or (b)
  a measurable and significant impact on the list provider [1], let people
  CC who they consider appropriate and let the list server send emails to
  whomever it is asked to send emails to.
  
  [1]  E.g. exceeding bandwidth quotas, mail delivery being delayed for
  hours, etc.

I take this example back; as Scott reminds us the CCs don't affect the
list server (except for a few more bytes in the headers of a message it
relays).  In which case I have even more trouble seeing the harm in re-
moving the list server's [apparently arbitrary and unsubstantiated] CC
limit.  Or at least changing it to a much higher number.

 Messages get delayed, and they exceed my patience quota ;-)

Again, not inherently because of having too many CCs.


Raise/remove the limit, and your immediate issue is resolved.  What's
not to like?

Tom
-- 
A: Because it breaks the logical|
flow of the message.|   Email to user 'CTZ001'
| at 'email.mot.com'
Q: Why is top posting frowned upon? |
___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot


Re: [U-Boot] [PATCH] Move L2-cache enable/disable function to soc dependent code

2009-05-30 Thread HeungJun, Kim
Ok. Jean.
Very thanks to review. 
I have a question about one thing you pointed out.

===
as it's nearly only in asm implement it in assembly olny will be better
 + /* ES2 onwards we can disable/enable L2 ourselves */
 + if (get_cpu_rev() = CPU_3XX_ES20) {
 + __asm__ __volatile__(mrc p15, 0, %0, c1, c0, 1:=r(i));
 + __asm__ __volatile__(orr %0, %0, #0x2:=r(i));
===

I think you tell me the position is in the assembly code like lowlevel_init.S. 
Is it right?
Can you explain more detailed about this part, plz? :)

If my thinking is alright, I'll re-update this patch soon. 

Best Regards,
Riverful

- 원본 메시지 -
보낸 사람: Jean-Christophe PLAGNIOL-VILLARD plagn...@jcrosoft.com
보낸 날짜: 2009년 5월 30일 토요일 오전 6:46
받는 사람: Kim, Heung Jun river...@gmail.com
참조: u-boot@lists.denx.de; Dirk Behme dirk.be...@googlemail.com; 
riverful@samsung.com; inki@samsung.com; mk7.k...@samsung.com; 
kyungmin.p...@samsung.com; bh...@samsung.com; jh106.c...@samsung.com
제목: Re: [U-Boot] [PATCH] Move L2-cache enable/disable function to soc   
dependent code

On 20:27 Fri 29 May , Kim, Heung Jun wrote:
 The L2 cache enable/disable function in the cpu/arm_cortexa8/cpu.c moved
 to cpu/arm_cortexa8/omap3/cache.c.
please mention omap3 in the title too
 
 Signed-off-by: HeungJun, Kim riverful@samsung.com
 ---
 + * (C) Copyright 2002
 + * Gary Jennejohn, DENX Software Engineering, g...@denx.de
 + *
 + * 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
 + */
 +
 +/*
 + * L2 cache specific code
 + */
 +
 +#include common.h
 +#include command.h
 +#include asm/arch/sys_proto.h
 +
 +void l2_cache_enable()
 +{
 + unsigned long i;
 + volatile unsigned int j;
 +
as it's nearly only in asm implement it in assembly olny will be better
 + /* ES2 onwards we can disable/enable L2 ourselves */
 + if (get_cpu_rev() = CPU_3XX_ES20) {
 + __asm__ __volatile__(mrc p15, 0, %0, c1, c0, 1:=r(i));
 + __asm__ __volatile__(orr %0, %0, #0x2:=r(i));
snip
 diff --git a/include/asm-arm/arch-omap3/sys_proto.h
 b/include/asm-arm/arch-omap3/sys_proto.h
 index 7361d08..4f43aef 100644
 --- a/include/asm-arm/arch-omap3/sys_proto.h
 +++ b/include/asm-arm/arch-omap3/sys_proto.h
 @@ -63,5 +63,7 @@ void make_cs1_contiguous(void);
  void omap_nand_switch_ecc(int);
  void power_init_r(void);
  void dieid_num_r(void);
 +void l2_cache_disable();
 +void l2_cache_enable();
please move these two funtcions in
include/asm-arm/cache.h

please rebase it against the u-boot-arm/next

Best Regards,
J.

___
U-Boot mailing list
U-Boot@lists.denx.de
http://lists.denx.de/mailman/listinfo/u-boot