aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/plat-s3c24xx/cpu.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/plat-s3c24xx/cpu.c')
-rw-r--r--arch/arm/plat-s3c24xx/cpu.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/arch/arm/plat-s3c24xx/cpu.c b/arch/arm/plat-s3c24xx/cpu.c
index 494f4f3a9332..32db85651af0 100644
--- a/arch/arm/plat-s3c24xx/cpu.c
+++ b/arch/arm/plat-s3c24xx/cpu.c
@@ -181,10 +181,18 @@ static struct map_desc s3c_iodesc[] __initdata = {
181 181
182static unsigned long s3c24xx_read_idcode_v5(void) 182static unsigned long s3c24xx_read_idcode_v5(void)
183{ 183{
184#if defined(CONFIG_CPU_S3C2416)
185 /* s3c2416 is v5, with S3C24XX_GSTATUS1 instead of S3C2412_GSTATUS1 */
186
187 u32 gs = __raw_readl(S3C24XX_GSTATUS1);
188
189 /* test for s3c2416 or similar device */
190 if ((gs >> 16) == 0x3245)
191 return gs;
192#endif
193
184#if defined(CONFIG_CPU_S3C2412) || defined(CONFIG_CPU_S3C2413) 194#if defined(CONFIG_CPU_S3C2412) || defined(CONFIG_CPU_S3C2413)
185 return __raw_readl(S3C2412_GSTATUS1); 195 return __raw_readl(S3C2412_GSTATUS1);
186#elif defined(CONFIG_CPU_S3C2416)
187 return __raw_readl(S3C24XX_GSTATUS1);
188#else 196#else
189 return 1UL; /* don't look like an 2400 */ 197 return 1UL; /* don't look like an 2400 */
190#endif 198#endif