Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@xxxxxx> --- For review __ONLY__ for now - will re-submit after I have pushed 1/8 arch/arm/mach-mx3/pcm037.c | 26 ++++++++++++++++++-------- 1 files changed, 18 insertions(+), 8 deletions(-) diff --git a/arch/arm/mach-mx3/pcm037.c b/arch/arm/mach-mx3/pcm037.c index bfa814d..af49f03 100644 --- a/arch/arm/mach-mx3/pcm037.c +++ b/arch/arm/mach-mx3/pcm037.c @@ -293,9 +293,18 @@ static int pcm037_camera_power(struct device *dev, int on) return 0; } +static struct i2c_board_info pcm037_i2c_2_devices[] = { + { + I2C_BOARD_INFO("mt9t031", 0x5d), + }, +}; + static struct soc_camera_link iclink = { - .bus_id = 0, /* Must match with the camera ID */ - .power = pcm037_camera_power, + .bus_id = 0, /* Must match with the camera ID */ + .power = pcm037_camera_power, + .board_info = &pcm037_i2c_2_devices[0], + .i2c_adapter_id = 2, + .module_name = "mt9t031", }; static struct i2c_board_info pcm037_i2c_devices[] = { @@ -308,9 +317,10 @@ static struct i2c_board_info pcm037_i2c_devices[] = { } }; -static struct i2c_board_info pcm037_i2c_2_devices[] = { - { - I2C_BOARD_INFO("mt9t031", 0x5d), +static struct platform_device pcm037_camera = { + .name = "soc-camera-pdrv", + .id = 0, + .dev = { .platform_data = &iclink, }, }; @@ -390,6 +400,9 @@ static struct platform_device *devices[] __initdata = { &pcm037_flash, &pcm037_eth, &pcm037_sram_device, +#if defined(CONFIG_I2C_IMX) || defined(CONFIG_I2C_IMX_MODULE) + &pcm037_camera, +#endif }; static struct ipu_platform_data mx3_ipu_data = { @@ -447,9 +460,6 @@ static void __init mxc_board_init(void) i2c_register_board_info(1, pcm037_i2c_devices, ARRAY_SIZE(pcm037_i2c_devices)); - i2c_register_board_info(2, pcm037_i2c_2_devices, - ARRAY_SIZE(pcm037_i2c_2_devices)); - mxc_register_device(&mxc_i2c_device1, &pcm037_i2c_1_data); mxc_register_device(&mxc_i2c_device2, &pcm037_i2c_2_data); #endif -- 1.6.2.4 -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html