Commit c00593f6 authored by Martin Michlmayr's avatar Martin Michlmayr Committed by Linus Torvalds

Thecus N2100: register rtc-rs5c372 i2c device

Use the new i2c framework to load rtc-rs5c372 for the Thecus N2100.
Signed-off-by: default avatarMartin Michlmayr <tbm@cyrius.com>
Tested-by: default avatarVoipio Riku <Riku.Voipio@movial.fi>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Lennert Buytenhek <buytenh@wantstofly.org>
Cc: Jean Delvare <khali@linux-fr.org>
Cc: David Brownell <david-b@pacbell.net>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent d815461c
...@@ -25,6 +25,7 @@ ...@@ -25,6 +25,7 @@
#include <linux/serial_core.h> #include <linux/serial_core.h>
#include <linux/serial_8250.h> #include <linux/serial_8250.h>
#include <linux/mtd/physmap.h> #include <linux/mtd/physmap.h>
#include <linux/i2c.h>
#include <linux/platform_device.h> #include <linux/platform_device.h>
#include <linux/reboot.h> #include <linux/reboot.h>
#include <asm/hardware.h> #include <asm/hardware.h>
...@@ -199,6 +200,12 @@ static struct platform_device n2100_serial_device = { ...@@ -199,6 +200,12 @@ static struct platform_device n2100_serial_device = {
.resource = &n2100_uart_resource, .resource = &n2100_uart_resource,
}; };
static struct i2c_board_info __initdata n2100_i2c_devices[] = {
{
I2C_BOARD_INFO("rtc-rs5c372", 0x32),
.type = "rs5c372b",
},
};
/* /*
* Pull PCA9532 GPIO #8 low to power off the machine. * Pull PCA9532 GPIO #8 low to power off the machine.
...@@ -248,6 +255,9 @@ static void __init n2100_init_machine(void) ...@@ -248,6 +255,9 @@ static void __init n2100_init_machine(void)
platform_device_register(&iop3xx_dma_0_channel); platform_device_register(&iop3xx_dma_0_channel);
platform_device_register(&iop3xx_dma_1_channel); platform_device_register(&iop3xx_dma_1_channel);
i2c_register_board_info(0, n2100_i2c_devices,
ARRAY_SIZE(n2100_i2c_devices));
pm_power_off = n2100_power_off; pm_power_off = n2100_power_off;
init_timer(&power_button_poll_timer); init_timer(&power_button_poll_timer);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment