Advertisement
pej02

Untitled

Oct 16th, 2012
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.20 KB | None | 0 0
  1. #if defined(CONFIG_VIDEO_OMAP3) || defined(CONFIG_VIDEO_OMAP3_MODULE)
  2.  
  3. #include <media/mt9t001.h>
  4. #include "devices.h"
  5. #include "../../../drivers/media/video/omap3isp/isp.h"
  6.  
  7. #define MT9T001_I2C_ADDR 0x5D
  8. #define MT9T001_I2C_BUS_NUM 3
  9. #define MT9T001_XCLK ISP_XCLK_A
  10.  
  11. static struct mt9t001_platform_data mt9t001_platform_data = {
  12. .clk_pol = 1,
  13. // .ext_clk = 48000000,
  14. };
  15.  
  16. static struct i2c_board_info mt9t001_i2c_device = {
  17. I2C_BOARD_INFO("mt9t001", MT9T001_I2C_ADDR),
  18. .platform_data = &mt9t001_platform_data,
  19. };
  20.  
  21. static struct isp_subdev_i2c_board_info mt9t001_subdevs[] = {
  22. {
  23. .board_info = &mt9t001_i2c_device,
  24. .i2c_adapter_id = MT9T001_I2C_BUS_NUM,
  25. },
  26. { NULL, 0, },
  27. };
  28.  
  29. static struct isp_v4l2_subdevs_group overo_camera_subdevs[] = {
  30. {
  31. .subdevs = mt9t001_subdevs,
  32. .interface = ISP_INTERFACE_PARALLEL,
  33. .bus = {
  34. .parallel = {
  35. .clk_pol = 1,
  36. }
  37. },
  38. },
  39. { NULL, 0, },
  40. };
  41.  
  42. static struct isp_platform_data overo_isp_platform_data = {
  43. .subdevs = overo_camera_subdevs,
  44. };
  45.  
  46. static int __init overo_camera_init(void)
  47. {
  48. return omap3_init_camera(&overo_isp_platform_data);
  49. }
  50.  
  51. #else
  52. static inline void overo_camera_init(void) { return; }
  53. #endif
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement