Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0-only */
0002 /*
0003  * s3c24xx/s3c64xx SoC series Camera Interface (CAMIF) driver
0004  *
0005  * Copyright (C) 2012 Sylwester Nawrocki <sylvester.nawrocki@gmail.com>
0006 */
0007 
0008 #ifndef MEDIA_S3C_CAMIF_
0009 #define MEDIA_S3C_CAMIF_
0010 
0011 #include <linux/i2c.h>
0012 #include <media/v4l2-mediabus.h>
0013 
0014 /**
0015  * struct s3c_camif_sensor_info - an image sensor description
0016  * @i2c_board_info: pointer to an I2C sensor subdevice board info
0017  * @clock_frequency: frequency of the clock the host provides to a sensor
0018  * @mbus_type: media bus type
0019  * @i2c_bus_num: i2c control bus id the sensor is attached to
0020  * @flags: the parallel bus flags defining signals polarity (V4L2_MBUS_*)
0021  * @use_field: 1 if parallel bus FIELD signal is used (only s3c64xx)
0022  */
0023 struct s3c_camif_sensor_info {
0024     struct i2c_board_info i2c_board_info;
0025     unsigned long clock_frequency;
0026     enum v4l2_mbus_type mbus_type;
0027     u16 i2c_bus_num;
0028     u16 flags;
0029     u8 use_field;
0030 };
0031 
0032 struct s3c_camif_plat_data {
0033     struct s3c_camif_sensor_info sensor;
0034     int (*gpio_get)(void);
0035     int (*gpio_put)(void);
0036 };
0037 
0038 #endif /* MEDIA_S3C_CAMIF_ */