aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-s3c24xx/mach-vr1000.c
diff options
context:
space:
mode:
authorHeiko Stuebner <heiko@sntech.de>2014-05-08 16:48:57 -0400
committerKukjin Kim <kgene.kim@samsung.com>2014-05-12 19:00:01 -0400
commit51cb128987d96538fdea4ce3704e79257afad4a5 (patch)
tree1109bd22e3f6a5fb9e3274bd3d158c4a05d17c94 /arch/arm/mach-s3c24xx/mach-vr1000.c
parent5799ea12a41286d9588155a1abd828f43bc63d6b (diff)
ARM: S3C24XX: enable usage of common dclk if common clock framework is enabled
Add platform device and select the correct implementation automatically depending on wether the old samsung_clock or the common clock framework is enabled. This is only done for machines already using the old dclk implementation, as everybody else should move to use dt anyway. The machine-specific settings for the external clocks will have to be set by somebody with knowledge about the specific hardware. Signed-off-by: Heiko Stuebner <heiko@sntech.de> Reviewed-by: Tomasz Figa <t.figa@samsung.com> [pebolle@tiscali.nl: pointed out typo and fixed] Signed-off-by: Kukjin Kim <kgene.kim@samsung.com>
Diffstat (limited to 'arch/arm/mach-s3c24xx/mach-vr1000.c')
-rw-r--r--arch/arm/mach-s3c24xx/mach-vr1000.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/arm/mach-s3c24xx/mach-vr1000.c b/arch/arm/mach-s3c24xx/mach-vr1000.c
index 1cc5b1bd51cd..bedaeefdc9f0 100644
--- a/arch/arm/mach-s3c24xx/mach-vr1000.c
+++ b/arch/arm/mach-s3c24xx/mach-vr1000.c
@@ -286,6 +286,7 @@ static struct i2c_board_info vr1000_i2c_devs[] __initdata = {
286/* devices for this board */ 286/* devices for this board */
287 287
288static struct platform_device *vr1000_devices[] __initdata = { 288static struct platform_device *vr1000_devices[] __initdata = {
289 &s3c2410_device_dclk,
289 &s3c_device_ohci, 290 &s3c_device_ohci,
290 &s3c_device_lcd, 291 &s3c_device_lcd,
291 &s3c_device_wdt, 292 &s3c_device_wdt,
@@ -299,6 +300,7 @@ static struct platform_device *vr1000_devices[] __initdata = {
299 &vr1000_led3, 300 &vr1000_led3,
300}; 301};
301 302
303#ifdef CONFIG_SAMSUNG_CLOCK
302static struct clk *vr1000_clocks[] __initdata = { 304static struct clk *vr1000_clocks[] __initdata = {
303 &s3c24xx_dclk0, 305 &s3c24xx_dclk0,
304 &s3c24xx_dclk1, 306 &s3c24xx_dclk1,
@@ -306,6 +308,7 @@ static struct clk *vr1000_clocks[] __initdata = {
306 &s3c24xx_clkout1, 308 &s3c24xx_clkout1,
307 &s3c24xx_uclk, 309 &s3c24xx_uclk,
308}; 310};
311#endif
309 312
310static void vr1000_power_off(void) 313static void vr1000_power_off(void)
311{ 314{
@@ -314,6 +317,7 @@ static void vr1000_power_off(void)
314 317
315static void __init vr1000_map_io(void) 318static void __init vr1000_map_io(void)
316{ 319{
320#if CONFIG_SAMSUNG_CLOCK
317 /* initialise clock sources */ 321 /* initialise clock sources */
318 322
319 s3c24xx_dclk0.parent = &clk_upll; 323 s3c24xx_dclk0.parent = &clk_upll;
@@ -328,6 +332,7 @@ static void __init vr1000_map_io(void)
328 s3c24xx_uclk.parent = &s3c24xx_clkout1; 332 s3c24xx_uclk.parent = &s3c24xx_clkout1;
329 333
330 s3c24xx_register_clocks(vr1000_clocks, ARRAY_SIZE(vr1000_clocks)); 334 s3c24xx_register_clocks(vr1000_clocks, ARRAY_SIZE(vr1000_clocks));
335#endif
331 336
332 pm_power_off = vr1000_power_off; 337 pm_power_off = vr1000_power_off;
333 338