Add SDA and SCL pin numbers to i2c platform data
authorPhilby John <pjohn@in.mvista.com>
Mon, 11 Jan 2010 10:23:31 +0000 (15:53 +0530)
committerKevin Hilman <khilman@deeprootsystems.com>
Thu, 4 Feb 2010 21:30:06 +0000 (13:30 -0800)
Patch adds SDA and SCL pin numbers to the i2c platform data
structure for Davinci DM355 and DM6446. This at present is
used for i2c bus recovery.
TODO: Add SDA and SCL pin number information to include all
Davinci platforms such as dm355-leopard, dm365, dm646x, da8xx etc.

Signed-off-by: Philby John <pjohn@in.mvista.com>
Signed-off-by: Kevin Hilman <khilman@deeprootsystems.com>
arch/arm/mach-davinci/board-dm355-evm.c
arch/arm/mach-davinci/board-dm644x-evm.c
arch/arm/mach-davinci/include/mach/i2c.h

index 077ecf4fecda9fb21dc98e002f4f236a8488fed9..aa48e3f69715b2163f6d4175e8264cf022dca4ac 100644 (file)
@@ -111,6 +111,8 @@ static struct platform_device davinci_nand_device = {
 static struct davinci_i2c_platform_data i2c_pdata = {
        .bus_freq       = 400   /* kHz */,
        .bus_delay      = 0     /* usec */,
+       .sda_pin        = 15,
+       .scl_pin        = 14,
 };
 
 static struct snd_platform_data dm355_evm_snd_data;
index e9612cf727b7cc9c6bb19a570ed0bc0b6d92ad52..976e11b7fa4a3655c2bfa012fcc7681f79efbc89 100644 (file)
@@ -629,6 +629,8 @@ static struct i2c_board_info __initdata i2c_info[] =  {
 static struct davinci_i2c_platform_data i2c_pdata = {
        .bus_freq       = 20 /* kHz */,
        .bus_delay      = 100 /* usec */,
+       .sda_pin        = 44,
+       .scl_pin        = 43,
 };
 
 static void __init evm_init_i2c(void)
index c248e9b7e82517c619b0fe74db18c4d3e88a2797..39fdceac8414202a6dfa3327bc2f5fd535d3f0bb 100644 (file)
@@ -16,6 +16,8 @@
 struct davinci_i2c_platform_data {
        unsigned int    bus_freq;       /* standard bus frequency (kHz) */
        unsigned int    bus_delay;      /* post-transaction delay (usec) */
+       unsigned int    sda_pin;        /* GPIO pin ID to use for SDA */
+       unsigned int    scl_pin;        /* GPIO pin ID to use for SCL */
 };
 
 /* for board setup code */