s3c_camif.h 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. /* SPDX-License-Identifier: GPL-2.0-only */
  2. /*
  3. * s3c24xx/s3c64xx SoC series Camera Interface (CAMIF) driver
  4. *
  5. * Copyright (C) 2012 Sylwester Nawrocki <[email protected]>
  6. */
  7. #ifndef MEDIA_S3C_CAMIF_
  8. #define MEDIA_S3C_CAMIF_
  9. #include <linux/i2c.h>
  10. #include <media/v4l2-mediabus.h>
  11. /**
  12. * struct s3c_camif_sensor_info - an image sensor description
  13. * @i2c_board_info: pointer to an I2C sensor subdevice board info
  14. * @clock_frequency: frequency of the clock the host provides to a sensor
  15. * @mbus_type: media bus type
  16. * @i2c_bus_num: i2c control bus id the sensor is attached to
  17. * @flags: the parallel bus flags defining signals polarity (V4L2_MBUS_*)
  18. * @use_field: 1 if parallel bus FIELD signal is used (only s3c64xx)
  19. */
  20. struct s3c_camif_sensor_info {
  21. struct i2c_board_info i2c_board_info;
  22. unsigned long clock_frequency;
  23. enum v4l2_mbus_type mbus_type;
  24. u16 i2c_bus_num;
  25. u16 flags;
  26. u8 use_field;
  27. };
  28. struct s3c_camif_plat_data {
  29. struct s3c_camif_sensor_info sensor;
  30. int (*gpio_get)(void);
  31. int (*gpio_put)(void);
  32. };
  33. #endif /* MEDIA_S3C_CAMIF_ */