aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/arm/mach-exynos4/clock.c6
-rw-r--r--arch/arm/mach-exynos4/include/mach/i2c-hdmiphy.h16
-rw-r--r--arch/arm/mach-exynos4/include/mach/irqs.h2
-rw-r--r--arch/arm/mach-exynos4/include/mach/map.h4
-rw-r--r--arch/arm/mach-s5pv210/clock.c6
-rw-r--r--arch/arm/mach-s5pv210/include/mach/i2c-hdmiphy.h16
-rw-r--r--arch/arm/mach-s5pv210/include/mach/irqs.h2
-rw-r--r--arch/arm/mach-s5pv210/include/mach/map.h3
-rw-r--r--arch/arm/plat-s5p/Kconfig5
-rw-r--r--arch/arm/plat-s5p/Makefile1
-rw-r--r--arch/arm/plat-s5p/dev-i2c-hdmiphy.c59
-rw-r--r--arch/arm/plat-samsung/include/plat/devs.h1
-rw-r--r--arch/arm/plat-samsung/include/plat/iic.h1
13 files changed, 121 insertions, 1 deletions
diff --git a/arch/arm/mach-exynos4/clock.c b/arch/arm/mach-exynos4/clock.c
index e85c481ec7a..0e1ba071e76 100644
--- a/arch/arm/mach-exynos4/clock.c
+++ b/arch/arm/mach-exynos4/clock.c
@@ -586,6 +586,12 @@ static struct clk init_clocks_off[] = {
586 .enable = exynos4_clk_ip_peril_ctrl, 586 .enable = exynos4_clk_ip_peril_ctrl,
587 .ctrlbit = (1 << 13), 587 .ctrlbit = (1 << 13),
588 }, { 588 }, {
589 .name = "i2c",
590 .devname = "s3c2440-hdmiphy-i2c",
591 .parent = &clk_aclk_100.clk,
592 .enable = exynos4_clk_ip_peril_ctrl,
593 .ctrlbit = (1 << 14),
594 }, {
589 .name = "SYSMMU_MDMA", 595 .name = "SYSMMU_MDMA",
590 .enable = exynos4_clk_ip_image_ctrl, 596 .enable = exynos4_clk_ip_image_ctrl,
591 .ctrlbit = (1 << 5), 597 .ctrlbit = (1 << 5),
diff --git a/arch/arm/mach-exynos4/include/mach/i2c-hdmiphy.h b/arch/arm/mach-exynos4/include/mach/i2c-hdmiphy.h
new file mode 100644
index 00000000000..9dbe3179ad5
--- /dev/null
+++ b/arch/arm/mach-exynos4/include/mach/i2c-hdmiphy.h
@@ -0,0 +1,16 @@
1/*
2 * Copyright (C) 2011 Samsung Electronics Co., Ltd.
3 *
4 * S5P series i2c hdmiphy helper definitions
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as
8 * published by the Free Software Foundation.
9 */
10
11#ifndef PLAT_S5P_I2C_HDMIPHY_H_
12#define PLAT_S5P_I2C_HDMIPHY_H_
13
14#define S5P_I2C_HDMIPHY_BUS_NUM (8)
15
16#endif
diff --git a/arch/arm/mach-exynos4/include/mach/irqs.h b/arch/arm/mach-exynos4/include/mach/irqs.h
index f8952f8f375..85011c2d983 100644
--- a/arch/arm/mach-exynos4/include/mach/irqs.h
+++ b/arch/arm/mach-exynos4/include/mach/irqs.h
@@ -93,6 +93,8 @@
93#define IRQ_2D IRQ_SPI(89) 93#define IRQ_2D IRQ_SPI(89)
94#define IRQ_PCIE IRQ_SPI(90) 94#define IRQ_PCIE IRQ_SPI(90)
95 95
96#define IRQ_IIC_HDMIPHY IRQ_SPI(93)
97
96#define IRQ_MFC IRQ_SPI(94) 98#define IRQ_MFC IRQ_SPI(94)
97 99
98#define IRQ_AUDIO_SS IRQ_SPI(96) 100#define IRQ_AUDIO_SS IRQ_SPI(96)
diff --git a/arch/arm/mach-exynos4/include/mach/map.h b/arch/arm/mach-exynos4/include/mach/map.h
index d32296dc65e..380feb98150 100644
--- a/arch/arm/mach-exynos4/include/mach/map.h
+++ b/arch/arm/mach-exynos4/include/mach/map.h
@@ -112,6 +112,8 @@
112 112
113#define EXYNOS4_PA_UART 0x13800000 113#define EXYNOS4_PA_UART 0x13800000
114 114
115#define EXYNOS4_PA_IIC_HDMIPHY 0x138E0000
116
115#define EXYNOS4_PA_IIC(x) (0x13860000 + ((x) * 0x10000)) 117#define EXYNOS4_PA_IIC(x) (0x13860000 + ((x) * 0x10000))
116 118
117#define EXYNOS4_PA_ADC 0x13910000 119#define EXYNOS4_PA_ADC 0x13910000
@@ -161,6 +163,8 @@
161#define S5P_PA_TIMER EXYNOS4_PA_TIMER 163#define S5P_PA_TIMER EXYNOS4_PA_TIMER
162#define S5P_PA_EHCI EXYNOS4_PA_EHCI 164#define S5P_PA_EHCI EXYNOS4_PA_EHCI
163 165
166#define S5P_PA_IIC_HDMIPHY EXYNOS4_PA_IIC_HDMIPHY
167
164#define SAMSUNG_PA_KEYPAD EXYNOS4_PA_KEYPAD 168#define SAMSUNG_PA_KEYPAD EXYNOS4_PA_KEYPAD
165 169
166/* UART */ 170/* UART */
diff --git a/arch/arm/mach-s5pv210/clock.c b/arch/arm/mach-s5pv210/clock.c
index e93ce3ed5b9..60cf8226de8 100644
--- a/arch/arm/mach-s5pv210/clock.c
+++ b/arch/arm/mach-s5pv210/clock.c
@@ -412,6 +412,12 @@ static struct clk init_clocks_off[] = {
412 .enable = s5pv210_clk_ip3_ctrl, 412 .enable = s5pv210_clk_ip3_ctrl,
413 .ctrlbit = (1<<9), 413 .ctrlbit = (1<<9),
414 }, { 414 }, {
415 .name = "i2c",
416 .devname = "s3c2440-hdmiphy-i2c",
417 .parent = &clk_pclk_psys.clk,
418 .enable = s5pv210_clk_ip3_ctrl,
419 .ctrlbit = (1 << 11),
420 }, {
415 .name = "spi", 421 .name = "spi",
416 .devname = "s3c64xx-spi.0", 422 .devname = "s3c64xx-spi.0",
417 .parent = &clk_pclk_psys.clk, 423 .parent = &clk_pclk_psys.clk,
diff --git a/arch/arm/mach-s5pv210/include/mach/i2c-hdmiphy.h b/arch/arm/mach-s5pv210/include/mach/i2c-hdmiphy.h
new file mode 100644
index 00000000000..6afa6242c58
--- /dev/null
+++ b/arch/arm/mach-s5pv210/include/mach/i2c-hdmiphy.h
@@ -0,0 +1,16 @@
1/*
2 * Copyright (C) 2011 Samsung Electronics Co., Ltd.
3 *
4 * S5P series i2c hdmiphy helper definitions
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License version 2 as
8 * published by the Free Software Foundation.
9 */
10
11#ifndef PLAT_S5P_I2C_HDMIPHY_H_
12#define PLAT_S5P_I2C_HDMIPHY_H_
13
14#define S5P_I2C_HDMIPHY_BUS_NUM (3)
15
16#endif
diff --git a/arch/arm/mach-s5pv210/include/mach/irqs.h b/arch/arm/mach-s5pv210/include/mach/irqs.h
index b9f9ec33384..c1da0a7fb18 100644
--- a/arch/arm/mach-s5pv210/include/mach/irqs.h
+++ b/arch/arm/mach-s5pv210/include/mach/irqs.h
@@ -56,7 +56,7 @@
56#define IRQ_SPI2 S5P_IRQ_VIC1(17) 56#define IRQ_SPI2 S5P_IRQ_VIC1(17)
57#define IRQ_IRDA S5P_IRQ_VIC1(18) 57#define IRQ_IRDA S5P_IRQ_VIC1(18)
58#define IRQ_IIC2 S5P_IRQ_VIC1(19) 58#define IRQ_IIC2 S5P_IRQ_VIC1(19)
59#define IRQ_IIC3 S5P_IRQ_VIC1(20) 59#define IRQ_IIC_HDMIPHY S5P_IRQ_VIC1(20)
60#define IRQ_HSIRX S5P_IRQ_VIC1(21) 60#define IRQ_HSIRX S5P_IRQ_VIC1(21)
61#define IRQ_HSITX S5P_IRQ_VIC1(22) 61#define IRQ_HSITX S5P_IRQ_VIC1(22)
62#define IRQ_UHOST S5P_IRQ_VIC1(23) 62#define IRQ_UHOST S5P_IRQ_VIC1(23)
diff --git a/arch/arm/mach-s5pv210/include/mach/map.h b/arch/arm/mach-s5pv210/include/mach/map.h
index aac343c180b..a420654c2c7 100644
--- a/arch/arm/mach-s5pv210/include/mach/map.h
+++ b/arch/arm/mach-s5pv210/include/mach/map.h
@@ -90,6 +90,8 @@
90#define S5PV210_PA_FIMC1 0xFB300000 90#define S5PV210_PA_FIMC1 0xFB300000
91#define S5PV210_PA_FIMC2 0xFB400000 91#define S5PV210_PA_FIMC2 0xFB400000
92 92
93#define S5PV210_PA_IIC_HDMIPHY 0xFA900000
94
93/* Compatibiltiy Defines */ 95/* Compatibiltiy Defines */
94 96
95#define S3C_PA_FB S5PV210_PA_FB 97#define S3C_PA_FB S5PV210_PA_FB
@@ -110,6 +112,7 @@
110#define S5P_PA_FIMC2 S5PV210_PA_FIMC2 112#define S5P_PA_FIMC2 S5PV210_PA_FIMC2
111#define S5P_PA_MIPI_CSIS0 S5PV210_PA_MIPI_CSIS 113#define S5P_PA_MIPI_CSIS0 S5PV210_PA_MIPI_CSIS
112#define S5P_PA_MFC S5PV210_PA_MFC 114#define S5P_PA_MFC S5PV210_PA_MFC
115#define S5P_PA_IIC_HDMIPHY S5PV210_PA_IIC_HDMIPHY
113#define S5P_PA_ONENAND S5PC110_PA_ONENAND 116#define S5P_PA_ONENAND S5PC110_PA_ONENAND
114#define S5P_PA_ONENAND_DMA S5PC110_PA_ONENAND_DMA 117#define S5P_PA_ONENAND_DMA S5PC110_PA_ONENAND_DMA
115#define S5P_PA_SDRAM S5PV210_PA_SDRAM 118#define S5P_PA_SDRAM S5PV210_PA_SDRAM
diff --git a/arch/arm/plat-s5p/Kconfig b/arch/arm/plat-s5p/Kconfig
index ac610bee2cb..a554d03b99b 100644
--- a/arch/arm/plat-s5p/Kconfig
+++ b/arch/arm/plat-s5p/Kconfig
@@ -73,6 +73,11 @@ config S5P_DEV_FIMD0
73 help 73 help
74 Compile in platform device definitions for FIMD controller 0 74 Compile in platform device definitions for FIMD controller 0
75 75
76config S5P_DEV_I2C_HDMIPHY
77 bool
78 help
79 Compile in platform device definitions for I2C HDMIPHY controller
80
76config S5P_DEV_MFC 81config S5P_DEV_MFC
77 bool 82 bool
78 help 83 help
diff --git a/arch/arm/plat-s5p/Makefile b/arch/arm/plat-s5p/Makefile
index 4b53e04eeca..1dd10dc91e6 100644
--- a/arch/arm/plat-s5p/Makefile
+++ b/arch/arm/plat-s5p/Makefile
@@ -31,6 +31,7 @@ obj-$(CONFIG_S5P_DEV_FIMC1) += dev-fimc1.o
31obj-$(CONFIG_S5P_DEV_FIMC2) += dev-fimc2.o 31obj-$(CONFIG_S5P_DEV_FIMC2) += dev-fimc2.o
32obj-$(CONFIG_S5P_DEV_FIMC3) += dev-fimc3.o 32obj-$(CONFIG_S5P_DEV_FIMC3) += dev-fimc3.o
33obj-$(CONFIG_S5P_DEV_FIMD0) += dev-fimd0.o 33obj-$(CONFIG_S5P_DEV_FIMD0) += dev-fimd0.o
34obj-$(CONFIG_S5P_DEV_I2C_HDMIPHY) += dev-i2c-hdmiphy.o
34obj-$(CONFIG_S5P_DEV_ONENAND) += dev-onenand.o 35obj-$(CONFIG_S5P_DEV_ONENAND) += dev-onenand.o
35obj-$(CONFIG_S5P_DEV_CSIS0) += dev-csis0.o 36obj-$(CONFIG_S5P_DEV_CSIS0) += dev-csis0.o
36obj-$(CONFIG_S5P_DEV_CSIS1) += dev-csis1.o 37obj-$(CONFIG_S5P_DEV_CSIS1) += dev-csis1.o
diff --git a/arch/arm/plat-s5p/dev-i2c-hdmiphy.c b/arch/arm/plat-s5p/dev-i2c-hdmiphy.c
new file mode 100644
index 00000000000..37343f1999f
--- /dev/null
+++ b/arch/arm/plat-s5p/dev-i2c-hdmiphy.c
@@ -0,0 +1,59 @@
1/*
2 * Copyright (c) 2011 Samsung Electronics Co., Ltd.
3 * http://www.samsung.com/
4 *
5 * S5P series device definition for i2c for hdmiphy device
6 *
7 * Based on plat-samsung/dev-i2c7.c
8 *
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License version 2 as
11 * published by the Free Software Foundation.
12*/
13
14#include <linux/gfp.h>
15#include <linux/kernel.h>
16#include <linux/string.h>
17#include <linux/platform_device.h>
18
19#include <mach/irqs.h>
20#include <mach/map.h>
21#include <mach/i2c-hdmiphy.h>
22
23#include <plat/regs-iic.h>
24#include <plat/devs.h>
25#include <plat/cpu.h>
26#include <plat/iic.h>
27
28static struct resource s5p_i2c_resource[] = {
29 [0] = {
30 .start = S5P_PA_IIC_HDMIPHY,
31 .end = S5P_PA_IIC_HDMIPHY + SZ_4K - 1,
32 .flags = IORESOURCE_MEM,
33 },
34 [1] = {
35 .start = IRQ_IIC_HDMIPHY,
36 .end = IRQ_IIC_HDMIPHY,
37 .flags = IORESOURCE_IRQ,
38 },
39};
40
41struct platform_device s5p_device_i2c_hdmiphy = {
42 .name = "s3c2440-hdmiphy-i2c",
43 .id = -1,
44 .num_resources = ARRAY_SIZE(s5p_i2c_resource),
45 .resource = s5p_i2c_resource,
46};
47
48void __init s5p_i2c_hdmiphy_set_platdata(struct s3c2410_platform_i2c *pd)
49{
50 struct s3c2410_platform_i2c *npd;
51
52 if (!pd) {
53 pd = &default_i2c_data;
54 pd->bus_num = S5P_I2C_HDMIPHY_BUS_NUM;
55 }
56
57 npd = s3c_set_platdata(pd, sizeof(struct s3c2410_platform_i2c),
58 &s5p_device_i2c_hdmiphy);
59}
diff --git a/arch/arm/plat-samsung/include/plat/devs.h b/arch/arm/plat-samsung/include/plat/devs.h
index 24ebb1e1de4..b15805f4de9 100644
--- a/arch/arm/plat-samsung/include/plat/devs.h
+++ b/arch/arm/plat-samsung/include/plat/devs.h
@@ -62,6 +62,7 @@ extern struct platform_device s3c_device_i2c4;
62extern struct platform_device s3c_device_i2c5; 62extern struct platform_device s3c_device_i2c5;
63extern struct platform_device s3c_device_i2c6; 63extern struct platform_device s3c_device_i2c6;
64extern struct platform_device s3c_device_i2c7; 64extern struct platform_device s3c_device_i2c7;
65extern struct platform_device s5p_device_i2c_hdmiphy;
65extern struct platform_device s3c_device_rtc; 66extern struct platform_device s3c_device_rtc;
66extern struct platform_device s3c_device_adc; 67extern struct platform_device s3c_device_adc;
67extern struct platform_device s3c_device_sdi; 68extern struct platform_device s3c_device_sdi;
diff --git a/arch/arm/plat-samsung/include/plat/iic.h b/arch/arm/plat-samsung/include/plat/iic.h
index 56b0059439e..51d52e767a1 100644
--- a/arch/arm/plat-samsung/include/plat/iic.h
+++ b/arch/arm/plat-samsung/include/plat/iic.h
@@ -60,6 +60,7 @@ extern void s3c_i2c4_set_platdata(struct s3c2410_platform_i2c *i2c);
60extern void s3c_i2c5_set_platdata(struct s3c2410_platform_i2c *i2c); 60extern void s3c_i2c5_set_platdata(struct s3c2410_platform_i2c *i2c);
61extern void s3c_i2c6_set_platdata(struct s3c2410_platform_i2c *i2c); 61extern void s3c_i2c6_set_platdata(struct s3c2410_platform_i2c *i2c);
62extern void s3c_i2c7_set_platdata(struct s3c2410_platform_i2c *i2c); 62extern void s3c_i2c7_set_platdata(struct s3c2410_platform_i2c *i2c);
63extern void s5p_i2c_hdmiphy_set_platdata(struct s3c2410_platform_i2c *i2c);
63 64
64/* defined by architecture to configure gpio */ 65/* defined by architecture to configure gpio */
65extern void s3c_i2c0_cfg_gpio(struct platform_device *dev); 66extern void s3c_i2c0_cfg_gpio(struct platform_device *dev);