diff options
author | Guennadi Liakhovetski <g.liakhovetski@gmx.de> | 2009-04-24 12:40:27 -0400 |
---|---|---|
committer | Eric Miao <eric.y.miao@gmail.com> | 2009-09-10 06:49:32 -0400 |
commit | a48c24a696f0d93c49f913b7818e9819612b1f4e (patch) | |
tree | d233c0d99dd7040d40e83c8241b425e36231753c /arch/arm/mach-pxa/mioa701.c | |
parent | 4a3d3abe91963d7b3e562e70fc6c5c9d3f76fb30 (diff) |
[ARM] pxa/mioa701: convert mioa701 to the new platform-device soc-camera interface
Signed-off-by: Guennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
Diffstat (limited to 'arch/arm/mach-pxa/mioa701.c')
-rw-r--r-- | arch/arm/mach-pxa/mioa701.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/arch/arm/mach-pxa/mioa701.c b/arch/arm/mach-pxa/mioa701.c index a8122ecd2a3a..3cab452e5567 100644 --- a/arch/arm/mach-pxa/mioa701.c +++ b/arch/arm/mach-pxa/mioa701.c | |||
@@ -708,19 +708,20 @@ static struct i2c_board_info __initdata mioa701_pi2c_devices[] = { | |||
708 | }, | 708 | }, |
709 | }; | 709 | }; |
710 | 710 | ||
711 | static struct soc_camera_link iclink = { | ||
712 | .bus_id = 0, /* Must match id in pxa27x_device_camera in device.c */ | ||
713 | }; | ||
714 | |||
715 | /* Board I2C devices. */ | 711 | /* Board I2C devices. */ |
716 | static struct i2c_board_info __initdata mioa701_i2c_devices[] = { | 712 | static struct i2c_board_info __initdata mioa701_i2c_devices[] = { |
717 | { | 713 | { |
718 | /* Must initialize before the camera(s) */ | ||
719 | I2C_BOARD_INFO("mt9m111", 0x5d), | 714 | I2C_BOARD_INFO("mt9m111", 0x5d), |
720 | .platform_data = &iclink, | ||
721 | }, | 715 | }, |
722 | }; | 716 | }; |
723 | 717 | ||
718 | static struct soc_camera_link iclink = { | ||
719 | .bus_id = 0, /* Match id in pxa27x_device_camera in device.c */ | ||
720 | .board_info = &mioa701_i2c_devices[0], | ||
721 | .i2c_adapter_id = 0, | ||
722 | .module_name = "mt9m111", | ||
723 | }; | ||
724 | |||
724 | struct i2c_pxa_platform_data i2c_pdata = { | 725 | struct i2c_pxa_platform_data i2c_pdata = { |
725 | .fast_mode = 1, | 726 | .fast_mode = 1, |
726 | }; | 727 | }; |
@@ -754,6 +755,7 @@ MIO_SIMPLE_DEV(pxa2xx_pcm, "pxa2xx-pcm", NULL) | |||
754 | MIO_SIMPLE_DEV(mioa701_sound, "mioa701-wm9713", NULL) | 755 | MIO_SIMPLE_DEV(mioa701_sound, "mioa701-wm9713", NULL) |
755 | MIO_SIMPLE_DEV(mioa701_board, "mioa701-board", NULL) | 756 | MIO_SIMPLE_DEV(mioa701_board, "mioa701-board", NULL) |
756 | MIO_SIMPLE_DEV(gpio_vbus, "gpio-vbus", &gpio_vbus_data); | 757 | MIO_SIMPLE_DEV(gpio_vbus, "gpio-vbus", &gpio_vbus_data); |
758 | MIO_SIMPLE_DEV(mioa701_camera, "soc-camera-pdrv",&iclink); | ||
757 | 759 | ||
758 | static struct platform_device *devices[] __initdata = { | 760 | static struct platform_device *devices[] __initdata = { |
759 | &mioa701_gpio_keys, | 761 | &mioa701_gpio_keys, |
@@ -764,6 +766,7 @@ static struct platform_device *devices[] __initdata = { | |||
764 | &power_dev, | 766 | &power_dev, |
765 | &strataflash, | 767 | &strataflash, |
766 | &gpio_vbus, | 768 | &gpio_vbus, |
769 | &mioa701_camera, | ||
767 | &mioa701_board, | 770 | &mioa701_board, |
768 | }; | 771 | }; |
769 | 772 | ||
@@ -813,7 +816,6 @@ static void __init mioa701_machine_init(void) | |||
813 | pxa_set_i2c_info(&i2c_pdata); | 816 | pxa_set_i2c_info(&i2c_pdata); |
814 | pxa27x_set_i2c_power_info(NULL); | 817 | pxa27x_set_i2c_power_info(NULL); |
815 | pxa_set_camera_info(&mioa701_pxacamera_platform_data); | 818 | pxa_set_camera_info(&mioa701_pxacamera_platform_data); |
816 | i2c_register_board_info(0, ARRAY_AND_SIZE(mioa701_i2c_devices)); | ||
817 | } | 819 | } |
818 | 820 | ||
819 | static void mioa701_machine_exit(void) | 821 | static void mioa701_machine_exit(void) |