diff options
author | Marek Vasut <marek.vasut@gmail.com> | 2010-03-26 00:38:10 -0400 |
---|---|---|
committer | Eric Miao <eric.y.miao@gmail.com> | 2010-05-11 11:25:03 -0400 |
commit | 83a4a1022654cbb9dd55fcf7c28807a634db54bc (patch) | |
tree | 70755fc7e4ebe3a5286ad8e26a110cb13fa8a349 /arch/arm/mach-pxa | |
parent | 1a8fb70e484589105a77f44bcd11e531c5fbe789 (diff) |
[ARM] pxa/vpac270: Add DS1339 RTC support
Signed-off-by: Marek Vasut <marek.vasut@gmail.com>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
Diffstat (limited to 'arch/arm/mach-pxa')
-rw-r--r-- | arch/arm/mach-pxa/vpac270.c | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/arch/arm/mach-pxa/vpac270.c b/arch/arm/mach-pxa/vpac270.c index fa428ca54902..0a9647b1916d 100644 --- a/arch/arm/mach-pxa/vpac270.c +++ b/arch/arm/mach-pxa/vpac270.c | |||
@@ -36,6 +36,8 @@ | |||
36 | #include <mach/pxa27x-udc.h> | 36 | #include <mach/pxa27x-udc.h> |
37 | #include <mach/udc.h> | 37 | #include <mach/udc.h> |
38 | 38 | ||
39 | #include <plat/i2c.h> | ||
40 | |||
39 | #include "generic.h" | 41 | #include "generic.h" |
40 | #include "devices.h" | 42 | #include "devices.h" |
41 | 43 | ||
@@ -132,6 +134,10 @@ static unsigned long vpac270_pin_config[] __initdata = { | |||
132 | GPIO95_AC97_nRESET, | 134 | GPIO95_AC97_nRESET, |
133 | GPIO98_AC97_SYSCLK, | 135 | GPIO98_AC97_SYSCLK, |
134 | GPIO113_GPIO, /* TS IRQ */ | 136 | GPIO113_GPIO, /* TS IRQ */ |
137 | |||
138 | /* I2C */ | ||
139 | GPIO117_I2C_SCL, | ||
140 | GPIO118_I2C_SDA, | ||
135 | }; | 141 | }; |
136 | 142 | ||
137 | /****************************************************************************** | 143 | /****************************************************************************** |
@@ -398,6 +404,25 @@ static inline void vpac270_ts_init(void) {} | |||
398 | #endif | 404 | #endif |
399 | 405 | ||
400 | /****************************************************************************** | 406 | /****************************************************************************** |
407 | * RTC | ||
408 | ******************************************************************************/ | ||
409 | #if defined(CONFIG_RTC_DRV_DS1307) || defined(CONFIG_RTC_DRV_DS1307_MODULE) | ||
410 | static struct i2c_board_info __initdata vpac270_i2c_devs[] = { | ||
411 | { | ||
412 | I2C_BOARD_INFO("ds1339", 0x68), | ||
413 | }, | ||
414 | }; | ||
415 | |||
416 | static void __init vpac270_rtc_init(void) | ||
417 | { | ||
418 | pxa_set_i2c_info(NULL); | ||
419 | i2c_register_board_info(0, ARRAY_AND_SIZE(vpac270_i2c_devs)); | ||
420 | } | ||
421 | #else | ||
422 | static inline void vpac270_rtc_init(void) {} | ||
423 | #endif | ||
424 | |||
425 | /****************************************************************************** | ||
401 | * Framebuffer | 426 | * Framebuffer |
402 | ******************************************************************************/ | 427 | ******************************************************************************/ |
403 | #if defined(CONFIG_FB_PXA) || defined(CONFIG_FB_PXA_MODULE) | 428 | #if defined(CONFIG_FB_PXA) || defined(CONFIG_FB_PXA_MODULE) |
@@ -481,6 +506,7 @@ static void __init vpac270_init(void) | |||
481 | vpac270_udc_init(); | 506 | vpac270_udc_init(); |
482 | vpac270_eth_init(); | 507 | vpac270_eth_init(); |
483 | vpac270_ts_init(); | 508 | vpac270_ts_init(); |
509 | vpac270_rtc_init(); | ||
484 | } | 510 | } |
485 | 511 | ||
486 | MACHINE_START(VPAC270, "Voipac PXA270") | 512 | MACHINE_START(VPAC270, "Voipac PXA270") |