[mach-tegra/whistler] Mux i2c bus i2c2
Tom Cherry [Tue, 1 Feb 2011 01:10:51 +0000 (17:10 -0800)]
Mux i2c bus i2c2 into dcc bus and gen2 bus

Bug 786162

Original-Change-Id: Id163459afa8d9f27564a051f6bf239c13d3cd8b6
Reviewed-on: http://git-master/r/17806
Tested-by: Thomas Cherry <tcherry@nvidia.com>
Reviewed-by: Sachin Nikam <snikam@nvidia.com>
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>

Rebase-Id: R269679ca60b740aba650fcdb06adec043d81baad

arch/arm/mach-tegra/board-whistler.c

index 90072cc..5b1177d 100644 (file)
@@ -145,10 +145,22 @@ static struct tegra_i2c_platform_data whistler_i2c1_platform_data = {
        .bus_clk_rate   = { 400000, 0 },
 };
 
+static const struct tegra_pingroup_config i2c2_ddc = {
+       .pingroup       = TEGRA_PINGROUP_DDC,
+       .func           = TEGRA_MUX_I2C2,
+};
+
+static const struct tegra_pingroup_config i2c2_gen2 = {
+       .pingroup       = TEGRA_PINGROUP_PTA,
+       .func           = TEGRA_MUX_I2C2,
+};
+
 static struct tegra_i2c_platform_data whistler_i2c2_platform_data = {
        .adapter_nr     = 1,
-       .bus_count      = 1,
-       .bus_clk_rate   = { 400000, 0 },
+       .bus_count      = 2,
+       .bus_clk_rate   = { 400000, 100000 },
+       .bus_mux        = { &i2c2_ddc, &i2c2_gen2 },
+       .bus_mux_len    = { 1, 1 },
 };
 
 static struct tegra_i2c_platform_data whistler_i2c3_platform_data = {