RE: [PATCH 4/9] ARM: EXYNOS: add support for ARCH_EXYNOS5 and EXYNOS5250

2012-02-09 Thread Kukjin Kim
Kyungmin Park wrote:
 
 On 2/1/12, Kukjin Kim kgene@samsung.com wrote:

[snip]

   machine-$(CONFIG_ARCH_EXYNOS4) := exynos
  +machine-$(CONFIG_ARCH_EXYNOS5) := exynos
 It already has CONFIG_ARCH_EXYNOS so it's enough
 machine-$(CONFIG_ARCH_EXYNOS) := exynos

Basically I'd like to keep the ARCH_EXYNOS4 and ARCH_EXYNOS5 it can be a
duplicated line though. Because it is a different core.

[snip]

  +config ARCH_EXYNOS5
  +   bool SAMSUNG EXYNOS5
  +   select HAVE_SMP
  +   help
  + Samsung EXYNOS5 SoCs based systems
 It's helpful to add which ARM core is used. in case of exynos4 has
 CA9, exynos5 has CA15.

Looks good, ok, the description of Cortex-A9 and Cortex-A15 will be added.

[snip]

  +config SOC_EXYNOS5250
  +   bool SAMSUNG EXYNOS5250
  +   default y
 default y?

Yes. I think at least one SoC should be selected when one ARCH_ is selected.
And as you know, now ARCH_EXYNOS5 is used only for EXYNOS5250 SoC.

[snip]

   #define EXYNOS4_PA_SYSRAM0 0x02025000
   #define EXYNOS4_PA_SYSRAM1 0x0202
  +#define EXYNOS5_PA_SYSRAM  0x0202
 Do you really use the single map file? Doesn't it better split each
series?

Now that would be better if could keep less headers.

[snip]

Thanks.

Best regards,
Kgene.
--
Kukjin Kim kgene@samsung.com, Senior Engineer,
SW Solution Development Team, Samsung Electronics Co., Ltd.

--
To unsubscribe from this list: send the line unsubscribe linux-samsung-soc in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Re: [PATCH 4/9] ARM: EXYNOS: add support for ARCH_EXYNOS5 and EXYNOS5250

2012-01-31 Thread Kyungmin Park
On 2/1/12, Kukjin Kim kgene@samsung.com wrote:
 Signed-off-by: Kukjin Kim kgene@samsung.com
 ---
  arch/arm/Makefile|1 +
  arch/arm/mach-exynos/Kconfig |   13 ++
  arch/arm/mach-exynos/Makefile|1 +
  arch/arm/mach-exynos/common.c|  163
 --
  arch/arm/mach-exynos/common.h|   19 +++
  arch/arm/mach-exynos/include/mach/map.h  |   21 +++-
  arch/arm/mach-exynos/include/mach/regs-pmu.h |1 +
  arch/arm/plat-s5p/Kconfig|4 +-
  arch/arm/plat-samsung/include/plat/cpu.h |   10 ++
  9 files changed, 217 insertions(+), 16 deletions(-)

 diff --git a/arch/arm/Makefile b/arch/arm/Makefile
 index 40319d9..a0a5031 100644
 --- a/arch/arm/Makefile
 +++ b/arch/arm/Makefile
 @@ -181,6 +181,7 @@ machine-$(CONFIG_ARCH_S5P64X0):= s5p64x0
  machine-$(CONFIG_ARCH_S5PC100)   := s5pc100
  machine-$(CONFIG_ARCH_S5PV210)   := s5pv210
  machine-$(CONFIG_ARCH_EXYNOS4)   := exynos
 +machine-$(CONFIG_ARCH_EXYNOS5)   := exynos
It already has CONFIG_ARCH_EXYNOS so it's enough
machine-$(CONFIG_ARCH_EXYNOS) := exynos
  machine-$(CONFIG_ARCH_SA1100):= sa1100
  machine-$(CONFIG_ARCH_SHARK) := shark
  machine-$(CONFIG_ARCH_SHMOBILE)  := shmobile
 diff --git a/arch/arm/mach-exynos/Kconfig b/arch/arm/mach-exynos/Kconfig
 index 5d602f6..60905d5 100644
 --- a/arch/arm/mach-exynos/Kconfig
 +++ b/arch/arm/mach-exynos/Kconfig
 @@ -22,6 +22,12 @@ config ARCH_EXYNOS4
   help
 Samsung EXYNOS4 SoCs based systems

 +config ARCH_EXYNOS5
 + bool SAMSUNG EXYNOS5
 + select HAVE_SMP
 + help
 +   Samsung EXYNOS5 SoCs based systems
It's helpful to add which ARM core is used. in case of exynos4 has
CA9, exynos5 has CA15.
 +
  endchoice

  comment EXYNOS SoCs
 @@ -53,6 +59,13 @@ config SOC_EXYNOS4412
   help
 Enable EXYNOS4412 SoC support

 +config SOC_EXYNOS5250
 + bool SAMSUNG EXYNOS5250
 + default y
default y?
 + depends on ARCH_EXYNOS5
 + help
 +   Enable EXYNOS5250 SoC support
 +
  config EXYNOS4_MCT
   bool
   default y
 diff --git a/arch/arm/mach-exynos/Makefile b/arch/arm/mach-exynos/Makefile
 index 2117f02..33d27d4 100644
 --- a/arch/arm/mach-exynos/Makefile
 +++ b/arch/arm/mach-exynos/Makefile
 @@ -14,6 +14,7 @@ obj-:=

  obj-$(CONFIG_ARCH_EXYNOS)+= common.o
  obj-$(CONFIG_ARCH_EXYNOS4)   += clock-exynos4.o
 +obj-$(CONFIG_ARCH_EXYNOS5)   += clock-exynos5.o
  obj-$(CONFIG_CPU_EXYNOS4210) += clock-exynos4210.o
  obj-$(CONFIG_SOC_EXYNOS4212) += clock-exynos4212.o

 diff --git a/arch/arm/mach-exynos/common.c b/arch/arm/mach-exynos/common.c
 index a168533..6ab3c5a 100644
 --- a/arch/arm/mach-exynos/common.c
 +++ b/arch/arm/mach-exynos/common.c
 @@ -49,6 +49,7 @@
  static const char name_exynos4210[] = EXYNOS4210;
  static const char name_exynos4212[] = EXYNOS4212;
  static const char name_exynos4412[] = EXYNOS4412;
 +static const char name_exynos5250[] = EXYNOS5250;

  static struct cpu_table cpu_ids[] __initdata = {
   {
 @@ -75,6 +76,14 @@ static struct cpu_table cpu_ids[] __initdata = {
   .init_uarts = exynos_init_uarts,
   .init   = exynos_init,
   .name   = name_exynos4412,
 + }, {
 + .idcode = EXYNOS5250_SOC_ID,
 + .idmask = EXYNOS5_SOC_MASK,
 + .map_io = exynos5_map_io,
 + .init_clocks= exynos5_init_clocks,
 + .init_uarts = exynos_init_uarts,
 + .init   = exynos_init,
 + .name   = name_exynos5250,
   },
  };

 @@ -83,10 +92,14 @@ static struct cpu_table cpu_ids[] __initdata = {
  static struct map_desc exynos_iodesc[] __initdata = {
   {
   .virtual= (unsigned long)S5P_VA_CHIPID,
 - .pfn= __phys_to_pfn(EXYNOS4_PA_CHIPID),
 + .pfn= __phys_to_pfn(EXYNOS_PA_CHIPID),
   .length = SZ_4K,
   .type   = MT_DEVICE,
 - }, {
 + },
 +};
 +
 +static struct map_desc exynos4_iodesc[] __initdata = {
 + {
   .virtual= (unsigned long)S3C_VA_SYS,
   .pfn= __phys_to_pfn(EXYNOS4_PA_SYSCON),
   .length = SZ_64K,
 @@ -136,11 +149,7 @@ static struct map_desc exynos_iodesc[] __initdata = {
   .pfn= __phys_to_pfn(EXYNOS4_PA_UART),
   .length = SZ_512K,
   .type   = MT_DEVICE,
 - },
 -};
 -
 -static struct map_desc exynos4_iodesc[] __initdata = {
 - {
 + }, {
   .virtual= (unsigned long)S5P_VA_CMU,
   .pfn= __phys_to_pfn(EXYNOS4_PA_CMU),
   .length = SZ_128K,
 @@ -201,6 +210,70 @@ static struct map_desc