aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-s5p6442
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-s5p6442')
-rw-r--r--arch/arm/mach-s5p6442/clock.c16
-rw-r--r--arch/arm/mach-s5p6442/include/mach/map.h3
-rw-r--r--arch/arm/mach-s5p6442/mach-smdk6442.c10
-rw-r--r--arch/arm/mach-s5p6442/setup-i2c0.c5
4 files changed, 20 insertions, 14 deletions
diff --git a/arch/arm/mach-s5p6442/clock.c b/arch/arm/mach-s5p6442/clock.c
index 16d6e7e61b50..fbbc7bede685 100644
--- a/arch/arm/mach-s5p6442/clock.c
+++ b/arch/arm/mach-s5p6442/clock.c
@@ -340,7 +340,7 @@ void __init_or_cpufreq s5p6442_setup_clocks(void)
340 clk_pclkd1.rate = pclkd1; 340 clk_pclkd1.rate = pclkd1;
341} 341}
342 342
343static struct clk init_clocks_disable[] = { 343static struct clk init_clocks_off[] = {
344 { 344 {
345 .name = "pdma", 345 .name = "pdma",
346 .id = -1, 346 .id = -1,
@@ -408,23 +408,13 @@ static struct clk *clks[] __initdata = {
408 408
409void __init s5p6442_register_clocks(void) 409void __init s5p6442_register_clocks(void)
410{ 410{
411 struct clk *clkptr;
412 int i, ret;
413
414 s3c24xx_register_clocks(clks, ARRAY_SIZE(clks)); 411 s3c24xx_register_clocks(clks, ARRAY_SIZE(clks));
415 412
416 s3c_register_clksrc(clksrcs, ARRAY_SIZE(clksrcs)); 413 s3c_register_clksrc(clksrcs, ARRAY_SIZE(clksrcs));
417 s3c_register_clocks(init_clocks, ARRAY_SIZE(init_clocks)); 414 s3c_register_clocks(init_clocks, ARRAY_SIZE(init_clocks));
418 415
419 clkptr = init_clocks_disable; 416 s3c_register_clocks(init_clocks_off, ARRAY_SIZE(init_clocks_off));
420 for (i = 0; i < ARRAY_SIZE(init_clocks_disable); i++, clkptr++) { 417 s3c_disable_clocks(init_clocks_off, ARRAY_SIZE(init_clocks_off));
421 ret = s3c24xx_register_clock(clkptr);
422 if (ret < 0) {
423 printk(KERN_ERR "Fail to register clock %s (%d)\n",
424 clkptr->name, ret);
425 } else
426 (clkptr->enable)(clkptr, 0);
427 }
428 418
429 s3c_pwmclk_init(); 419 s3c_pwmclk_init();
430} 420}
diff --git a/arch/arm/mach-s5p6442/include/mach/map.h b/arch/arm/mach-s5p6442/include/mach/map.h
index 31fb2e68d527..203dd5a18bd5 100644
--- a/arch/arm/mach-s5p6442/include/mach/map.h
+++ b/arch/arm/mach-s5p6442/include/mach/map.h
@@ -28,6 +28,9 @@
28#define S5P6442_PA_VIC1 (0xE4100000) 28#define S5P6442_PA_VIC1 (0xE4100000)
29#define S5P6442_PA_VIC2 (0xE4200000) 29#define S5P6442_PA_VIC2 (0xE4200000)
30 30
31#define S5P6442_PA_SROMC (0xE7000000)
32#define S5P_PA_SROMC S5P6442_PA_SROMC
33
31#define S5P6442_PA_MDMA 0xE8000000 34#define S5P6442_PA_MDMA 0xE8000000
32#define S5P6442_PA_PDMA 0xE9000000 35#define S5P6442_PA_PDMA 0xE9000000
33 36
diff --git a/arch/arm/mach-s5p6442/mach-smdk6442.c b/arch/arm/mach-s5p6442/mach-smdk6442.c
index 819fd80d00af..e69f137b0a39 100644
--- a/arch/arm/mach-s5p6442/mach-smdk6442.c
+++ b/arch/arm/mach-s5p6442/mach-smdk6442.c
@@ -12,6 +12,7 @@
12#include <linux/types.h> 12#include <linux/types.h>
13#include <linux/init.h> 13#include <linux/init.h>
14#include <linux/serial_core.h> 14#include <linux/serial_core.h>
15#include <linux/i2c.h>
15 16
16#include <asm/mach/arch.h> 17#include <asm/mach/arch.h>
17#include <asm/mach/map.h> 18#include <asm/mach/map.h>
@@ -25,6 +26,7 @@
25#include <plat/s5p6442.h> 26#include <plat/s5p6442.h>
26#include <plat/devs.h> 27#include <plat/devs.h>
27#include <plat/cpu.h> 28#include <plat/cpu.h>
29#include <plat/iic.h>
28 30
29/* Following are default values for UCON, ULCON and UFCON UART registers */ 31/* Following are default values for UCON, ULCON and UFCON UART registers */
30#define SMDK6442_UCON_DEFAULT (S3C2410_UCON_TXILEVEL | \ 32#define SMDK6442_UCON_DEFAULT (S3C2410_UCON_TXILEVEL | \
@@ -65,10 +67,15 @@ static struct s3c2410_uartcfg smdk6442_uartcfgs[] __initdata = {
65}; 67};
66 68
67static struct platform_device *smdk6442_devices[] __initdata = { 69static struct platform_device *smdk6442_devices[] __initdata = {
70 &s3c_device_i2c0,
68 &s5p6442_device_iis0, 71 &s5p6442_device_iis0,
69 &s3c_device_wdt, 72 &s3c_device_wdt,
70}; 73};
71 74
75static struct i2c_board_info smdk6442_i2c_devs0[] __initdata = {
76 { I2C_BOARD_INFO("wm8580", 0x1b), },
77};
78
72static void __init smdk6442_map_io(void) 79static void __init smdk6442_map_io(void)
73{ 80{
74 s5p_init_io(NULL, 0, S5P_VA_CHIPID); 81 s5p_init_io(NULL, 0, S5P_VA_CHIPID);
@@ -78,6 +85,9 @@ static void __init smdk6442_map_io(void)
78 85
79static void __init smdk6442_machine_init(void) 86static void __init smdk6442_machine_init(void)
80{ 87{
88 s3c_i2c0_set_platdata(NULL);
89 i2c_register_board_info(0, smdk6442_i2c_devs0,
90 ARRAY_SIZE(smdk6442_i2c_devs0));
81 platform_add_devices(smdk6442_devices, ARRAY_SIZE(smdk6442_devices)); 91 platform_add_devices(smdk6442_devices, ARRAY_SIZE(smdk6442_devices));
82} 92}
83 93
diff --git a/arch/arm/mach-s5p6442/setup-i2c0.c b/arch/arm/mach-s5p6442/setup-i2c0.c
index 662695dd7761..aad85656b0cc 100644
--- a/arch/arm/mach-s5p6442/setup-i2c0.c
+++ b/arch/arm/mach-s5p6442/setup-i2c0.c
@@ -14,12 +14,15 @@
14 14
15#include <linux/kernel.h> 15#include <linux/kernel.h>
16#include <linux/types.h> 16#include <linux/types.h>
17#include <linux/gpio.h>
17 18
18struct platform_device; /* don't need the contents */ 19struct platform_device; /* don't need the contents */
19 20
21#include <plat/gpio-cfg.h>
20#include <plat/iic.h> 22#include <plat/iic.h>
21 23
22void s3c_i2c0_cfg_gpio(struct platform_device *dev) 24void s3c_i2c0_cfg_gpio(struct platform_device *dev)
23{ 25{
24 /* Will be populated later */ 26 s3c_gpio_cfgall_range(S5P6442_GPD1(0), 2,
27 S3C_GPIO_SFN(2), S3C_GPIO_PULL_UP);
25} 28}