From: David Daney Date: Thu, 7 Jan 2010 19:54:21 +0000 (-0800) Subject: MIPS: Octeon: Register some devices on the I2C bus. X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=d95770544604299402e481771a964b0f10d46978;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git MIPS: Octeon: Register some devices on the I2C bus. Signed-off-by: David Daney To: linux-mips@linux-mips.org To: linux-i2c@vger.kernel.org To: ben-linux@fluff.org To: khali@linux-fr.org Cc: Rade Bozic Patchwork: http://patchwork.linux-mips.org/patch/845/ Signed-off-by: Ralf Baechle --- diff --git a/arch/mips/cavium-octeon/octeon-platform.c b/arch/mips/cavium-octeon/octeon-platform.c index 784c1c874018..62ac30eef5e8 100644 --- a/arch/mips/cavium-octeon/octeon-platform.c +++ b/arch/mips/cavium-octeon/octeon-platform.c @@ -9,6 +9,7 @@ #include #include +#include #include #include @@ -159,6 +160,18 @@ out: } device_initcall(octeon_rng_device_init); +static struct i2c_board_info __initdata octeon_i2c_devices[] = { + { + I2C_BOARD_INFO("ds1337", 0x68), + }, +}; + +static int __init octeon_i2c_devices_init(void) +{ + return i2c_register_board_info(0, octeon_i2c_devices, + ARRAY_SIZE(octeon_i2c_devices)); +} +arch_initcall(octeon_i2c_devices_init); #define OCTEON_I2C_IO_BASE 0x1180000001000ull #define OCTEON_I2C_IO_UNIT_OFFSET 0x200