Commit f0176794 authored by Ben Dooks's avatar Ben Dooks Committed by Ben Dooks

ARM: S3C2410: Add S3C2410A sysdev.

Add a sysdev S3C2410A sysdev to allow the differentiation
of the S3C2410A from the S3C2410. This is needed for the
CPUFREQ code to enable the extra features and update cpu
specific information.
Signed-off-by: default avatarBen Dooks <ben@simtec.co.uk>
Signed-off-by: default avatarBen Dooks <ben-linux@fluff.org>
parent 140780ab
...@@ -164,6 +164,17 @@ static int __init s3c2410_dma_drvinit(void) ...@@ -164,6 +164,17 @@ static int __init s3c2410_dma_drvinit(void)
} }
arch_initcall(s3c2410_dma_drvinit); arch_initcall(s3c2410_dma_drvinit);
static struct sysdev_driver s3c2410a_dma_driver = {
.add = s3c2410_dma_add,
};
static int __init s3c2410a_dma_drvinit(void)
{
return sysdev_driver_register(&s3c2410a_sysclass, &s3c2410a_dma_driver);
}
arch_initcall(s3c2410a_dma_drvinit);
#endif #endif
#if defined(CONFIG_CPU_S3C2442) #if defined(CONFIG_CPU_S3C2442)
......
...@@ -39,9 +39,22 @@ static struct sysdev_driver s3c2410_irq_driver = { ...@@ -39,9 +39,22 @@ static struct sysdev_driver s3c2410_irq_driver = {
.resume = s3c24xx_irq_resume, .resume = s3c24xx_irq_resume,
}; };
static int s3c2410_irq_init(void) static int __init s3c2410_irq_init(void)
{ {
return sysdev_driver_register(&s3c2410_sysclass, &s3c2410_irq_driver); return sysdev_driver_register(&s3c2410_sysclass, &s3c2410_irq_driver);
} }
arch_initcall(s3c2410_irq_init); arch_initcall(s3c2410_irq_init);
static struct sysdev_driver s3c2410a_irq_driver = {
.add = s3c2410_irq_add,
.suspend = s3c24xx_irq_suspend,
.resume = s3c24xx_irq_resume,
};
static int __init s3c2410a_irq_init(void)
{
return sysdev_driver_register(&s3c2410a_sysclass, &s3c2410a_irq_driver);
}
arch_initcall(s3c2410a_irq_init);
...@@ -119,6 +119,18 @@ static int __init s3c2410_pm_drvinit(void) ...@@ -119,6 +119,18 @@ static int __init s3c2410_pm_drvinit(void)
} }
arch_initcall(s3c2410_pm_drvinit); arch_initcall(s3c2410_pm_drvinit);
static struct sysdev_driver s3c2410a_pm_driver = {
.add = s3c2410_pm_add,
.resume = s3c2410_pm_resume,
};
static int __init s3c2410a_pm_drvinit(void)
{
return sysdev_driver_register(&s3c2410a_sysclass, &s3c2410a_pm_driver);
}
arch_initcall(s3c2410a_pm_drvinit);
#endif #endif
#if defined(CONFIG_CPU_S3C2440) #if defined(CONFIG_CPU_S3C2440)
......
...@@ -116,6 +116,13 @@ struct sysdev_class s3c2410_sysclass = { ...@@ -116,6 +116,13 @@ struct sysdev_class s3c2410_sysclass = {
.name = "s3c2410-core", .name = "s3c2410-core",
}; };
/* Note, we would have liked to name this s3c2410-core, but we cannot
* register two sysdev_class with the same name.
*/
struct sysdev_class s3c2410a_sysclass = {
.name = "s3c2410a-core",
};
static struct sys_device s3c2410_sysdev = { static struct sys_device s3c2410_sysdev = {
.cls = &s3c2410_sysclass, .cls = &s3c2410_sysclass,
}; };
...@@ -133,9 +140,22 @@ static int __init s3c2410_core_init(void) ...@@ -133,9 +140,22 @@ static int __init s3c2410_core_init(void)
core_initcall(s3c2410_core_init); core_initcall(s3c2410_core_init);
static int __init s3c2410a_core_init(void)
{
return sysdev_class_register(&s3c2410a_sysclass);
}
core_initcall(s3c2410a_core_init);
int __init s3c2410_init(void) int __init s3c2410_init(void)
{ {
printk("S3C2410: Initialising architecture\n"); printk("S3C2410: Initialising architecture\n");
return sysdev_register(&s3c2410_sysdev); return sysdev_register(&s3c2410_sysdev);
} }
int __init s3c2410a_init(void)
{
s3c2410_sysdev.cls = &s3c2410a_sysclass;
return s3c2410_init();
}
...@@ -65,6 +65,7 @@ extern struct sys_timer s3c24xx_timer; ...@@ -65,6 +65,7 @@ extern struct sys_timer s3c24xx_timer;
/* system device classes */ /* system device classes */
extern struct sysdev_class s3c2410_sysclass; extern struct sysdev_class s3c2410_sysclass;
extern struct sysdev_class s3c2410a_sysclass;
extern struct sysdev_class s3c2412_sysclass; extern struct sysdev_class s3c2412_sysclass;
extern struct sysdev_class s3c2440_sysclass; extern struct sysdev_class s3c2440_sysclass;
extern struct sysdev_class s3c2442_sysclass; extern struct sysdev_class s3c2442_sysclass;
......
...@@ -81,7 +81,7 @@ static struct cpu_table cpu_ids[] __initdata = { ...@@ -81,7 +81,7 @@ static struct cpu_table cpu_ids[] __initdata = {
.map_io = s3c2410_map_io, .map_io = s3c2410_map_io,
.init_clocks = s3c2410_init_clocks, .init_clocks = s3c2410_init_clocks,
.init_uarts = s3c2410_init_uarts, .init_uarts = s3c2410_init_uarts,
.init = s3c2410_init, .init = s3c2410a_init,
.name = name_s3c2410a .name = name_s3c2410a
}, },
{ {
......
...@@ -14,6 +14,7 @@ ...@@ -14,6 +14,7 @@
#ifdef CONFIG_CPU_S3C2410 #ifdef CONFIG_CPU_S3C2410
extern int s3c2410_init(void); extern int s3c2410_init(void);
extern int s3c2410a_init(void);
extern void s3c2410_map_io(void); extern void s3c2410_map_io(void);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment