Skip to contentSkip to conversation

s3c64xx: Add ifdef at the S3C64XX only codes

PATCH New Joonyoung Shim 2 participants 2 messages Feb 8, 2010 – Feb 9, 2010

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 s3c64xx: Add ifdef at the S3C64XX only codes

The s3c6400.h file is only for S3C64XX cpu and the pheripheral port address(0x70000000 - 0x7fffffff) exists at only S3C64XX cpu, so they should be included by only S3C64XX cpu.

---
 cpu/arm1176/cpu.c   |    2 ++
 cpu/arm1176/start.S |    4 ++++
 2 files changed, 6 insertions(+), 0 deletions(-)
cpu/arm1176/cpu.c +2 -0
index 2c0014f..befa0cd 100644
@@ -33,7 +33,9 @@
 
 #include <common.h>
 #include <command.h>
+#ifdef CONFIG_S3C64XX
 #include <asm/arch/s3c6400.h>
+#endif
 #include <asm/system.h>
 
 static void cache_flush (void);
cpu/arm1176/start.S +4 -0
index 68a356d..e2b6c9b 100644
@@ -35,7 +35,9 @@
 #ifdef CONFIG_ENABLE_MMU
 #include <asm/proc/domain.h>
 #endif
+#ifdef CONFIG_S3C64XX
 #include <asm/arch/s3c6400.h>
+#endif
 
 #if !defined(CONFIG_ENABLE_MMU) && !defined(CONFIG_SYS_PHY_UBOOT_BASE)
 #define CONFIG_SYS_PHY_UBOOT_BASE	CONFIG_SYS_UBOOT_BASE
@@ -190,10 +192,12 @@ mmu_disable:
 #endif
 
 mmu_disable_phys:
+#ifdef CONFIG_S3C64XX
 	/* Peri port setup */
 	ldr	r0, =0x70000000
 	orr	r0, r0, #0x13
 	mcr	p15,0,r0,c15,c2,4       @ 256M (0x70000000 - 0x7fffffff)
+#endif
 
 	/*
 	 * Go setup Memory and board specific bits prior to relocation.
Signature · 1 line
1.6.3.3
#1 lore raw

PATCH v2 1/1 s3c64xx: Add ifdef at the S3C64XX only codes

Dear Joonyoung Shim,

Quoted 10 lines · Joonyoung Shim

The s3c6400.h file is only for S3C64XX cpu and the pheripheral port address(0x70000000 - 0x7fffffff) exists at only S3C64XX cpu, so they should be included by only S3C64XX cpu.

---
?cpu/arm1176/cpu.c ? | ? ?2 ++
?cpu/arm1176/start.S | ? ?4 ++++
?2 files changed, 6 insertions(+), 0 deletions(-)

applied to u-boot-samsung

Thanks
Minkyu Kang

Signature · 2 lines
from. prom.
www.promsoft.net