diff options
author | Marek Vasut <marek.vasut@gmail.com> | 2010-08-11 19:30:39 -0400 |
---|---|---|
committer | Eric Miao <eric.y.miao@gmail.com> | 2010-12-20 10:07:41 -0500 |
commit | 072e1ae73c65496355279505de378b33c916e364 (patch) | |
tree | dd5ba8799f23b20c9f7d82c4b3cd02fdb7c6c9ad /arch | |
parent | 9b6956f45132f9bf696e9f6c2e457bdfa8e08721 (diff) |
ARM: pxa: Add M41T00 RTC support into Colibri evalboard
Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Acked-by: Daniel Mack <daniel@caiaq.de>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/arm/mach-pxa/colibri-pxa270-evalboard.c | 23 | ||||
-rw-r--r-- | arch/arm/mach-pxa/colibri-pxa270.c | 4 | ||||
-rw-r--r-- | arch/arm/mach-pxa/colibri-pxa300.c | 4 | ||||
-rw-r--r-- | arch/arm/mach-pxa/colibri-pxa320.c | 4 |
4 files changed, 35 insertions, 0 deletions
diff --git a/arch/arm/mach-pxa/colibri-pxa270-evalboard.c b/arch/arm/mach-pxa/colibri-pxa270-evalboard.c index e1a2b52a9d21..7f27aecc7e0f 100644 --- a/arch/arm/mach-pxa/colibri-pxa270-evalboard.c +++ b/arch/arm/mach-pxa/colibri-pxa270-evalboard.c | |||
@@ -19,6 +19,7 @@ | |||
19 | #include <asm/mach-types.h> | 19 | #include <asm/mach-types.h> |
20 | #include <mach/hardware.h> | 20 | #include <mach/hardware.h> |
21 | #include <asm/mach/arch.h> | 21 | #include <asm/mach/arch.h> |
22 | #include <linux/i2c.h> | ||
22 | 23 | ||
23 | #include <mach/pxa27x.h> | 24 | #include <mach/pxa27x.h> |
24 | #include <mach/colibri.h> | 25 | #include <mach/colibri.h> |
@@ -26,6 +27,8 @@ | |||
26 | #include <mach/ohci.h> | 27 | #include <mach/ohci.h> |
27 | #include <mach/pxa27x-udc.h> | 28 | #include <mach/pxa27x-udc.h> |
28 | 29 | ||
30 | #include <plat/i2c.h> | ||
31 | |||
29 | #include "generic.h" | 32 | #include "generic.h" |
30 | #include "devices.h" | 33 | #include "devices.h" |
31 | 34 | ||
@@ -87,6 +90,25 @@ static void __init colibri_pxa270_uhc_init(void) | |||
87 | static inline void colibri_pxa270_uhc_init(void) {} | 90 | static inline void colibri_pxa270_uhc_init(void) {} |
88 | #endif | 91 | #endif |
89 | 92 | ||
93 | /****************************************************************************** | ||
94 | * I2C RTC | ||
95 | ******************************************************************************/ | ||
96 | #if defined(CONFIG_RTC_DRV_DS1307) || defined(CONFIG_RTC_DRV_DS1307_MODULE) | ||
97 | static struct i2c_board_info __initdata colibri_pxa270_i2c_devs[] = { | ||
98 | { | ||
99 | I2C_BOARD_INFO("m41t00", 0x68), | ||
100 | }, | ||
101 | }; | ||
102 | |||
103 | static void __init colibri_pxa270_rtc_init(void) | ||
104 | { | ||
105 | pxa_set_i2c_info(NULL); | ||
106 | i2c_register_board_info(0, ARRAY_AND_SIZE(colibri_pxa270_i2c_devs)); | ||
107 | } | ||
108 | #else | ||
109 | static inline void colibri_pxa270_rtc_init(void) {} | ||
110 | #endif | ||
111 | |||
90 | void __init colibri_pxa270_evalboard_init(void) | 112 | void __init colibri_pxa270_evalboard_init(void) |
91 | { | 113 | { |
92 | pxa_set_ffuart_info(NULL); | 114 | pxa_set_ffuart_info(NULL); |
@@ -95,4 +117,5 @@ void __init colibri_pxa270_evalboard_init(void) | |||
95 | 117 | ||
96 | colibri_pxa270_mmc_init(); | 118 | colibri_pxa270_mmc_init(); |
97 | colibri_pxa270_uhc_init(); | 119 | colibri_pxa270_uhc_init(); |
120 | colibri_pxa270_rtc_init(); | ||
98 | } | 121 | } |
diff --git a/arch/arm/mach-pxa/colibri-pxa270.c b/arch/arm/mach-pxa/colibri-pxa270.c index e940004eac16..eecbb8bc4533 100644 --- a/arch/arm/mach-pxa/colibri-pxa270.c +++ b/arch/arm/mach-pxa/colibri-pxa270.c | |||
@@ -73,6 +73,10 @@ static mfp_cfg_t colibri_pxa270_evalboard_pin_config[] __initdata = { | |||
73 | GPIO1_GPIO, /* READY */ | 73 | GPIO1_GPIO, /* READY */ |
74 | GPIO84_GPIO, /* DETECT */ | 74 | GPIO84_GPIO, /* DETECT */ |
75 | GPIO107_GPIO, /* PPEN */ | 75 | GPIO107_GPIO, /* PPEN */ |
76 | |||
77 | /* I2C */ | ||
78 | GPIO117_I2C_SCL, | ||
79 | GPIO118_I2C_SDA, | ||
76 | }; | 80 | }; |
77 | #else | 81 | #else |
78 | static mfp_cfg_t colibri_pxa270_evalboard_pin_config[] __initdata = {}; | 82 | static mfp_cfg_t colibri_pxa270_evalboard_pin_config[] __initdata = {}; |
diff --git a/arch/arm/mach-pxa/colibri-pxa300.c b/arch/arm/mach-pxa/colibri-pxa300.c index 649c83c427c9..9b8d72de294c 100644 --- a/arch/arm/mach-pxa/colibri-pxa300.c +++ b/arch/arm/mach-pxa/colibri-pxa300.c | |||
@@ -46,6 +46,10 @@ static mfp_cfg_t colibri_pxa300_evalboard_pin_config[] __initdata = { | |||
46 | /* UHC */ | 46 | /* UHC */ |
47 | GPIO0_2_USBH_PEN, | 47 | GPIO0_2_USBH_PEN, |
48 | GPIO1_2_USBH_PWR, | 48 | GPIO1_2_USBH_PWR, |
49 | |||
50 | /* I2C */ | ||
51 | GPIO21_I2C_SCL, | ||
52 | GPIO22_I2C_SDA, | ||
49 | }; | 53 | }; |
50 | #else | 54 | #else |
51 | static mfp_cfg_t colibri_pxa300_evalboard_pin_config[] __initdata = {}; | 55 | static mfp_cfg_t colibri_pxa300_evalboard_pin_config[] __initdata = {}; |
diff --git a/arch/arm/mach-pxa/colibri-pxa320.c b/arch/arm/mach-pxa/colibri-pxa320.c index 6f15f2acf0c6..0d8faf85a508 100644 --- a/arch/arm/mach-pxa/colibri-pxa320.c +++ b/arch/arm/mach-pxa/colibri-pxa320.c | |||
@@ -69,6 +69,10 @@ static mfp_cfg_t colibri_pxa320_evalboard_pin_config[] __initdata = { | |||
69 | /* UHC */ | 69 | /* UHC */ |
70 | GPIO2_2_USBH_PEN, | 70 | GPIO2_2_USBH_PEN, |
71 | GPIO3_2_USBH_PWR, | 71 | GPIO3_2_USBH_PWR, |
72 | |||
73 | /* I2C */ | ||
74 | GPIO32_I2C_SCL, | ||
75 | GPIO33_I2C_SDA, | ||
72 | }; | 76 | }; |
73 | #else | 77 | #else |
74 | static mfp_cfg_t colibri_pxa320_evalboard_pin_config[] __initdata = {}; | 78 | static mfp_cfg_t colibri_pxa320_evalboard_pin_config[] __initdata = {}; |