#ifndef S5C73M3_H_
#define S5C73M3_H_
#include <linux/clk.h>
#include <linux/kernel.h>
#include <linux/regulator/consumer.h>
#include <linux/gpio/consumer.h>
#include <media/v4l2-common.h>
#include <media/v4l2-ctrls.h>
#include <media/v4l2-subdev.h>
#define DRIVER_NAME …
#define S5C73M3_ISP_FMT …
#define S5C73M3_JPEG_FMT …
enum s5c73m3_pads { … };
enum s5c73m3_oif_pads { … };
#define S5C73M3_SENSOR_FW_LEN …
#define S5C73M3_SENSOR_TYPE_LEN …
#define S5C73M3_REG(_addrh, _addrl) …
#define AHB_MSB_ADDR_PTR …
#define REG_CMDWR_ADDRH …
#define REG_CMDWR_ADDRL …
#define REG_CMDRD_ADDRH …
#define REG_CMDRD_ADDRL …
#define REG_CMDBUF_ADDR …
#define REG_I2C_SEQ_STATUS …
#define SEQ_END_PLL …
#define SEQ_END_SENSOR …
#define SEQ_END_GPIO …
#define SEQ_END_FROM …
#define SEQ_END_STABLE_AE_AWB …
#define SEQ_END_READY_I2C_CMD …
#define REG_I2C_STATUS …
#define I2C_STATUS_CIS_I2C …
#define I2C_STATUS_AF_INIT …
#define I2C_STATUS_CAL_DATA …
#define I2C_STATUS_FRAME_COUNT …
#define I2C_STATUS_FROM_INIT …
#define I2C_STATUS_I2C_CIS_STREAM_OFF …
#define I2C_STATUS_I2C_N_CMD_OVER …
#define I2C_STATUS_I2C_N_CMD_MISMATCH …
#define I2C_STATUS_CHECK_BIN_CRC …
#define I2C_STATUS_EXCEPTION …
#define I2C_STATUS_INIF_INIT_STATE …
#define REG_STATUS …
#define REG_STATUS_BOOT_SUB_MAIN_ENTER …
#define REG_STATUS_BOOT_SRAM_TIMING_OK …
#define REG_STATUS_BOOT_INTERRUPTS_EN …
#define REG_STATUS_BOOT_R_PLL_DONE …
#define REG_STATUS_BOOT_R_PLL_LOCKTIME_DONE …
#define REG_STATUS_BOOT_DELAY_COUNT_DONE …
#define REG_STATUS_BOOT_I_PLL_DONE …
#define REG_STATUS_BOOT_I_PLL_LOCKTIME_DONE …
#define REG_STATUS_BOOT_PLL_INIT_OK …
#define REG_STATUS_BOOT_SENSOR_INIT_OK …
#define REG_STATUS_BOOT_GPIO_SETTING_OK …
#define REG_STATUS_BOOT_READ_CAL_DATA_OK …
#define REG_STATUS_BOOT_STABLE_AE_AWB_OK …
#define REG_STATUS_ISP_COMMAND_COMPLETED …
#define REG_STATUS_EXCEPTION_OCCURED …
#define COMM_RESULT_OFFSET …
#define COMM_IMG_OUTPUT …
#define COMM_IMG_OUTPUT_HDR …
#define COMM_IMG_OUTPUT_YUV …
#define COMM_IMG_OUTPUT_INTERLEAVED …
#define COMM_STILL_PRE_FLASH …
#define COMM_STILL_PRE_FLASH_FIRE …
#define COMM_STILL_PRE_FLASH_NON_FIRED …
#define COMM_STILL_PRE_FLASH_FIRED …
#define COMM_STILL_MAIN_FLASH …
#define COMM_STILL_MAIN_FLASH_CANCEL …
#define COMM_STILL_MAIN_FLASH_FIRE …
#define COMM_ZOOM_STEP …
#define COMM_IMAGE_EFFECT …
#define COMM_IMAGE_EFFECT_NONE …
#define COMM_IMAGE_EFFECT_NEGATIVE …
#define COMM_IMAGE_EFFECT_AQUA …
#define COMM_IMAGE_EFFECT_SEPIA …
#define COMM_IMAGE_EFFECT_MONO …
#define COMM_IMAGE_QUALITY …
#define COMM_IMAGE_QUALITY_SUPERFINE …
#define COMM_IMAGE_QUALITY_FINE …
#define COMM_IMAGE_QUALITY_NORMAL …
#define COMM_FLASH_MODE …
#define COMM_FLASH_MODE_OFF …
#define COMM_FLASH_MODE_ON …
#define COMM_FLASH_MODE_AUTO …
#define COMM_FLASH_STATUS …
#define COMM_FLASH_STATUS_OFF …
#define COMM_FLASH_STATUS_ON …
#define COMM_FLASH_STATUS_AUTO …
#define COMM_FLASH_TORCH …
#define COMM_FLASH_TORCH_OFF …
#define COMM_FLASH_TORCH_ON …
#define COMM_AE_NEEDS_FLASH …
#define COMM_AE_NEEDS_FLASH_OFF …
#define COMM_AE_NEEDS_FLASH_ON …
#define COMM_CHG_MODE …
#define COMM_CHG_MODE_NEW …
#define COMM_CHG_MODE_SUBSAMPLING_HALF …
#define COMM_CHG_MODE_SUBSAMPLING_QUARTER …
#define COMM_CHG_MODE_YUV_320_240 …
#define COMM_CHG_MODE_YUV_640_480 …
#define COMM_CHG_MODE_YUV_880_720 …
#define COMM_CHG_MODE_YUV_960_720 …
#define COMM_CHG_MODE_YUV_1184_666 …
#define COMM_CHG_MODE_YUV_1280_720 …
#define COMM_CHG_MODE_YUV_1536_864 …
#define COMM_CHG_MODE_YUV_1600_1200 …
#define COMM_CHG_MODE_YUV_1632_1224 …
#define COMM_CHG_MODE_YUV_1920_1080 …
#define COMM_CHG_MODE_YUV_1920_1440 …
#define COMM_CHG_MODE_YUV_2304_1296 …
#define COMM_CHG_MODE_YUV_3264_2448 …
#define COMM_CHG_MODE_YUV_352_288 …
#define COMM_CHG_MODE_YUV_1008_672 …
#define COMM_CHG_MODE_JPEG_640_480 …
#define COMM_CHG_MODE_JPEG_800_450 …
#define COMM_CHG_MODE_JPEG_800_600 …
#define COMM_CHG_MODE_JPEG_1280_720 …
#define COMM_CHG_MODE_JPEG_1280_960 …
#define COMM_CHG_MODE_JPEG_1600_900 …
#define COMM_CHG_MODE_JPEG_1600_1200 …
#define COMM_CHG_MODE_JPEG_2048_1152 …
#define COMM_CHG_MODE_JPEG_2048_1536 …
#define COMM_CHG_MODE_JPEG_2560_1440 …
#define COMM_CHG_MODE_JPEG_2560_1920 …
#define COMM_CHG_MODE_JPEG_3264_2176 …
#define COMM_CHG_MODE_JPEG_1024_768 …
#define COMM_CHG_MODE_JPEG_3264_1836 …
#define COMM_CHG_MODE_JPEG_3264_2448 …
#define COMM_AF_CON …
#define COMM_AF_CON_STOP …
#define COMM_AF_CON_SCAN …
#define COMM_AF_CON_START …
#define COMM_AF_CAL …
#define COMM_AF_TOUCH_AF …
#define REG_AF_STATUS …
#define REG_CAF_STATUS_FIND_SEARCH_DIR …
#define REG_CAF_STATUS_FOCUSING …
#define REG_CAF_STATUS_FOCUSED …
#define REG_CAF_STATUS_UNFOCUSED …
#define REG_AF_STATUS_INVALID …
#define REG_AF_STATUS_FOCUSING …
#define REG_AF_STATUS_FOCUSED …
#define REG_AF_STATUS_UNFOCUSED …
#define REG_AF_TOUCH_POSITION …
#define COMM_AF_FACE_ZOOM …
#define COMM_AF_MODE …
#define COMM_AF_MODE_NORMAL …
#define COMM_AF_MODE_MACRO …
#define COMM_AF_MODE_MOVIE_CAF_START …
#define COMM_AF_MODE_MOVIE_CAF_STOP …
#define COMM_AF_MODE_PREVIEW_CAF_START …
#define COMM_AF_MODE_PREVIEW_CAF_STOP …
#define COMM_AF_SOFTLANDING …
#define COMM_AF_SOFTLANDING_ON …
#define COMM_AF_SOFTLANDING_RES_COMPLETE …
#define COMM_FACE_DET …
#define COMM_FACE_DET_OFF …
#define COMM_FACE_DET_ON …
#define COMM_FACE_DET_OSD …
#define COMM_FACE_DET_OSD_OFF …
#define COMM_FACE_DET_OSD_ON …
#define COMM_AE_CON …
#define COMM_AE_STOP …
#define COMM_AE_START …
#define COMM_ISO …
#define COMM_ISO_AUTO …
#define COMM_ISO_100 …
#define COMM_ISO_200 …
#define COMM_ISO_400 …
#define COMM_ISO_800 …
#define COMM_ISO_SPORTS …
#define COMM_ISO_NIGHT …
#define COMM_ISO_INDOOR …
#define COMM_EV …
#define COMM_METERING …
#define COMM_METERING_CENTER …
#define COMM_METERING_SPOT …
#define COMM_METERING_AVERAGE …
#define COMM_METERING_SMART …
#define COMM_WDR …
#define COMM_WDR_OFF …
#define COMM_WDR_ON …
#define COMM_FLICKER_MODE …
#define COMM_FLICKER_NONE …
#define COMM_FLICKER_MANUAL_50HZ …
#define COMM_FLICKER_MANUAL_60HZ …
#define COMM_FLICKER_AUTO …
#define COMM_FLICKER_AUTO_50HZ …
#define COMM_FLICKER_AUTO_60HZ …
#define COMM_FRAME_RATE …
#define COMM_FRAME_RATE_AUTO_SET …
#define COMM_FRAME_RATE_FIXED_30FPS …
#define COMM_FRAME_RATE_FIXED_20FPS …
#define COMM_FRAME_RATE_FIXED_15FPS …
#define COMM_FRAME_RATE_FIXED_60FPS …
#define COMM_FRAME_RATE_FIXED_120FPS …
#define COMM_FRAME_RATE_FIXED_7FPS …
#define COMM_FRAME_RATE_FIXED_10FPS …
#define COMM_FRAME_RATE_FIXED_90FPS …
#define COMM_FRAME_RATE_ANTI_SHAKE …
#define COMM_SHARPNESS …
#define COMM_SATURATION …
#define COMM_CONTRAST …
#define COMM_SCENE_MODE …
#define COMM_SCENE_MODE_NONE …
#define COMM_SCENE_MODE_PORTRAIT …
#define COMM_SCENE_MODE_LANDSCAPE …
#define COMM_SCENE_MODE_SPORTS …
#define COMM_SCENE_MODE_INDOOR …
#define COMM_SCENE_MODE_BEACH …
#define COMM_SCENE_MODE_SUNSET …
#define COMM_SCENE_MODE_DAWN …
#define COMM_SCENE_MODE_FALL …
#define COMM_SCENE_MODE_NIGHT …
#define COMM_SCENE_MODE_AGAINST_LIGHT …
#define COMM_SCENE_MODE_FIRE …
#define COMM_SCENE_MODE_TEXT …
#define COMM_SCENE_MODE_CANDLE …
#define COMM_AE_AUTO_BRACKET …
#define COMM_AE_AUTO_BRAKET_EV05 …
#define COMM_AE_AUTO_BRAKET_EV10 …
#define COMM_AE_AUTO_BRAKET_EV15 …
#define COMM_AE_AUTO_BRAKET_EV20 …
#define COMM_SENSOR_STREAMING …
#define COMM_SENSOR_STREAMING_OFF …
#define COMM_SENSOR_STREAMING_ON …
#define COMM_AWB_MODE …
#define COMM_AWB_MODE_INCANDESCENT …
#define COMM_AWB_MODE_FLUORESCENT1 …
#define COMM_AWB_MODE_FLUORESCENT2 …
#define COMM_AWB_MODE_DAYLIGHT …
#define COMM_AWB_MODE_CLOUDY …
#define COMM_AWB_MODE_AUTO …
#define COMM_AWB_CON …
#define COMM_AWB_STOP …
#define COMM_AWB_START …
#define COMM_FW_UPDATE …
#define COMM_FW_UPDATE_NOT_READY …
#define COMM_FW_UPDATE_SUCCESS …
#define COMM_FW_UPDATE_FAIL …
#define COMM_FW_UPDATE_BUSY …
#define S5C73M3_MAX_SUPPLIES …
#define S5C73M3_DEFAULT_MCLK_FREQ …
struct s5c73m3_ctrls { … };
enum s5c73m3_resolution_types { … };
struct s5c73m3_interval { … };
struct s5c73m3 { … };
struct s5c73m3_frame_size { … };
extern int s5c73m3_dbg;
int s5c73m3_register_spi_driver(struct s5c73m3 *state);
void s5c73m3_unregister_spi_driver(struct s5c73m3 *state);
int s5c73m3_spi_write(struct s5c73m3 *state, const void *addr,
const unsigned int len, const unsigned int tx_size);
int s5c73m3_spi_read(struct s5c73m3 *state, void *addr,
const unsigned int len, const unsigned int tx_size);
int s5c73m3_read(struct s5c73m3 *state, u32 addr, u16 *data);
int s5c73m3_write(struct s5c73m3 *state, u32 addr, u16 data);
int s5c73m3_isp_command(struct s5c73m3 *state, u16 command, u16 data);
int s5c73m3_init_controls(struct s5c73m3 *state);
static inline struct v4l2_subdev *ctrl_to_sensor_sd(struct v4l2_ctrl *ctrl)
{ … }
static inline struct s5c73m3 *sensor_sd_to_s5c73m3(struct v4l2_subdev *sd)
{ … }
static inline struct s5c73m3 *oif_sd_to_s5c73m3(struct v4l2_subdev *sd)
{ … }
#endif