#ifndef __OV2722_H__
#define __OV2722_H__
#include <linux/kernel.h>
#include <linux/types.h>
#include <linux/i2c.h>
#include <linux/delay.h>
#include <linux/videodev2.h>
#include <linux/spinlock.h>
#include <media/v4l2-subdev.h>
#include <media/v4l2-device.h>
#include <linux/v4l2-mediabus.h>
#include <media/media-entity.h>
#include <media/v4l2-ctrls.h>
#include "../include/linux/atomisp_platform.h"
#define OV2722_POWER_UP_RETRY_NUM …
#define I2C_MSG_LENGTH …
#define I2C_RETRY_COUNT …
#define OV2722_FOCAL_LENGTH_NUM …
#define MAX_FMTS …
#define OV2722_FOCAL_LENGTH_DEFAULT …
#define OV2722_F_NUMBER_DEFAULT …
#define OV2722_F_NUMBER_RANGE …
#define OV2720_ID …
#define OV2722_ID …
#define OV2722_FINE_INTG_TIME_MIN …
#define OV2722_FINE_INTG_TIME_MAX_MARGIN …
#define OV2722_COARSE_INTG_TIME_MIN …
#define OV2722_COARSE_INTG_TIME_MAX_MARGIN …
#define OV2722_SW_SLEEP …
#define OV2722_SW_RESET …
#define OV2722_SW_STREAM …
#define OV2722_SC_CMMN_CHIP_ID_H …
#define OV2722_SC_CMMN_CHIP_ID_L …
#define OV2722_SC_CMMN_SCCB_ID …
#define OV2722_SC_CMMN_SUB_ID …
#define OV2722_SC_CMMN_PAD_OEN0 …
#define OV2722_SC_CMMN_PAD_OEN1 …
#define OV2722_SC_CMMN_PAD_OEN2 …
#define OV2722_SC_CMMN_PAD_OUT0 …
#define OV2722_SC_CMMN_PAD_OUT1 …
#define OV2722_SC_CMMN_PAD_OUT2 …
#define OV2722_SC_CMMN_PAD_SEL0 …
#define OV2722_SC_CMMN_PAD_SEL1 …
#define OV2722_SC_CMMN_PAD_SEL2 …
#define OV2722_SC_CMMN_PAD_PK …
#define OV2722_SC_CMMN_A_PWC_PK_O_13 …
#define OV2722_SC_CMMN_A_PWC_PK_O_14 …
#define OV2722_SC_CMMN_CLKRST0 …
#define OV2722_SC_CMMN_CLKRST1 …
#define OV2722_SC_CMMN_CLKRST2 …
#define OV2722_SC_CMMN_CLKRST3 …
#define OV2722_SC_CMMN_CLKRST4 …
#define OV2722_SC_CMMN_CLKRST5 …
#define OV2722_SC_CMMN_PCLK_DIV_CTRL …
#define OV2722_SC_CMMN_CLOCK_SEL …
#define OV2722_SC_SOC_CLKRST5 …
#define OV2722_SC_CMMN_PLL_CTRL0 …
#define OV2722_SC_CMMN_PLL_CTRL1 …
#define OV2722_SC_CMMN_PLL_CTRL2 …
#define OV2722_SC_CMMN_PLL_CTRL3 …
#define OV2722_SC_CMMN_PLL_MULTIPLIER …
#define OV2722_SC_CMMN_PLL_DEBUG_OPT …
#define OV2722_SC_CMMN_PLLS_CTRL0 …
#define OV2722_SC_CMMN_PLLS_CTRL1 …
#define OV2722_SC_CMMN_PLLS_CTRL2 …
#define OV2722_SC_CMMN_PLLS_CTRL3 …
#define OV2722_SC_CMMN_MIPI_PHY_16 …
#define OV2722_SC_CMMN_MIPI_PHY_17 …
#define OV2722_SC_CMMN_MIPI_SC_CTRL_18 …
#define OV2722_SC_CMMN_MIPI_SC_CTRL_19 …
#define OV2722_SC_CMMN_MIPI_SC_CTRL_21 …
#define OV2722_SC_CMMN_MIPI_SC_CTRL_22 …
#define OV2722_AEC_PK_EXPO_H …
#define OV2722_AEC_PK_EXPO_M …
#define OV2722_AEC_PK_EXPO_L …
#define OV2722_AEC_MANUAL_CTRL …
#define OV2722_AGC_ADJ_H …
#define OV2722_AGC_ADJ_L …
#define OV2722_VTS_DIFF_H …
#define OV2722_VTS_DIFF_L …
#define OV2722_GROUP_ACCESS …
#define OV2722_HTS_H …
#define OV2722_HTS_L …
#define OV2722_VTS_H …
#define OV2722_VTS_L …
#define OV2722_MWB_GAIN_R_H …
#define OV2722_MWB_GAIN_R_L …
#define OV2722_MWB_GAIN_G_H …
#define OV2722_MWB_GAIN_G_L …
#define OV2722_MWB_GAIN_B_H …
#define OV2722_MWB_GAIN_B_L …
#define OV2722_H_CROP_START_H …
#define OV2722_H_CROP_START_L …
#define OV2722_V_CROP_START_H …
#define OV2722_V_CROP_START_L …
#define OV2722_H_CROP_END_H …
#define OV2722_H_CROP_END_L …
#define OV2722_V_CROP_END_H …
#define OV2722_V_CROP_END_L …
#define OV2722_H_OUTSIZE_H …
#define OV2722_H_OUTSIZE_L …
#define OV2722_V_OUTSIZE_H …
#define OV2722_V_OUTSIZE_L …
#define OV2722_START_STREAMING …
#define OV2722_STOP_STREAMING …
struct regval_list { … };
struct ov2722_resolution { … };
struct ov2722_format { … };
struct ov2722_device { … };
enum ov2722_tok_type { … };
struct ov2722_reg { … };
#define to_ov2722_sensor(x) …
#define OV2722_MAX_WRITE_BUF_SIZE …
struct ov2722_write_buffer { … };
struct ov2722_write_ctrl { … };
#if 0
static struct ov2722_reg const ov2722_QVGA_30fps[] = {
{OV2722_8BIT, 0x3718, 0x10},
{OV2722_8BIT, 0x3702, 0x0c},
{OV2722_8BIT, 0x373a, 0x1c},
{OV2722_8BIT, 0x3715, 0x01},
{OV2722_8BIT, 0x3703, 0x0c},
{OV2722_8BIT, 0x3705, 0x06},
{OV2722_8BIT, 0x3730, 0x0e},
{OV2722_8BIT, 0x3704, 0x1c},
{OV2722_8BIT, 0x3f06, 0x00},
{OV2722_8BIT, 0x371c, 0x00},
{OV2722_8BIT, 0x371d, 0x46},
{OV2722_8BIT, 0x371e, 0x00},
{OV2722_8BIT, 0x371f, 0x63},
{OV2722_8BIT, 0x3708, 0x61},
{OV2722_8BIT, 0x3709, 0x12},
{OV2722_8BIT, 0x3800, 0x01},
{OV2722_8BIT, 0x3801, 0x42},
{OV2722_8BIT, 0x3802, 0x00},
{OV2722_8BIT, 0x3803, 0x20},
{OV2722_8BIT, 0x3804, 0x06},
{OV2722_8BIT, 0x3805, 0x95},
{OV2722_8BIT, 0x3806, 0x04},
{OV2722_8BIT, 0x3807, 0x27},
{OV2722_8BIT, 0x3808, 0x01},
{OV2722_8BIT, 0x3809, 0x50},
{OV2722_8BIT, 0x380a, 0x01},
{OV2722_8BIT, 0x380b, 0x00},
{OV2722_8BIT, 0x380c, 0x08},
{OV2722_8BIT, 0x380d, 0x00},
{OV2722_8BIT, 0x380e, 0x04},
{OV2722_8BIT, 0x380f, 0xa0},
{OV2722_8BIT, 0x3810, 0x00},
{OV2722_8BIT, 0x3811, 0x04},
{OV2722_8BIT, 0x3812, 0x00},
{OV2722_8BIT, 0x3813, 0x01},
{OV2722_8BIT, 0x3820, 0xc0},
{OV2722_8BIT, 0x3821, 0x06},
{OV2722_8BIT, 0x3814, 0x71},
{OV2722_8BIT, 0x3815, 0x71},
{OV2722_8BIT, 0x3612, 0x49},
{OV2722_8BIT, 0x3618, 0x00},
{OV2722_8BIT, 0x3a08, 0x01},
{OV2722_8BIT, 0x3a09, 0xc3},
{OV2722_8BIT, 0x3a0a, 0x01},
{OV2722_8BIT, 0x3a0b, 0x77},
{OV2722_8BIT, 0x3a0d, 0x00},
{OV2722_8BIT, 0x3a0e, 0x00},
{OV2722_8BIT, 0x4520, 0x09},
{OV2722_8BIT, 0x4837, 0x1b},
{OV2722_8BIT, 0x3000, 0xff},
{OV2722_8BIT, 0x3001, 0xff},
{OV2722_8BIT, 0x3002, 0xf0},
{OV2722_8BIT, 0x3600, 0x08},
{OV2722_8BIT, 0x3621, 0xc0},
{OV2722_8BIT, 0x3632, 0x53},
{OV2722_8BIT, 0x3633, 0x63},
{OV2722_8BIT, 0x3634, 0x24},
{OV2722_8BIT, 0x3f01, 0x0c},
{OV2722_8BIT, 0x5001, 0xc1},
{OV2722_8BIT, 0x3614, 0xf0},
{OV2722_8BIT, 0x3630, 0x2d},
{OV2722_8BIT, 0x370b, 0x62},
{OV2722_8BIT, 0x3706, 0x61},
{OV2722_8BIT, 0x4000, 0x02},
{OV2722_8BIT, 0x4002, 0xc5},
{OV2722_8BIT, 0x4005, 0x08},
{OV2722_8BIT, 0x404f, 0x84},
{OV2722_8BIT, 0x4051, 0x00},
{OV2722_8BIT, 0x5000, 0xff},
{OV2722_8BIT, 0x3a18, 0x00},
{OV2722_8BIT, 0x3a19, 0x80},
{OV2722_8BIT, 0x4521, 0x00},
{OV2722_8BIT, 0x5183, 0xb0},
{OV2722_8BIT, 0x5184, 0xb0},
{OV2722_8BIT, 0x5185, 0xb0},
{OV2722_8BIT, 0x5180, 0x03},
{OV2722_8BIT, 0x370c, 0x0c},
{OV2722_8BIT, 0x4800, 0x24},
{OV2722_8BIT, 0x3035, 0x00},
{OV2722_8BIT, 0x3036, 0x26},
{OV2722_8BIT, 0x3037, 0xa1},
{OV2722_8BIT, 0x303e, 0x19},
{OV2722_8BIT, 0x3038, 0x06},
{OV2722_8BIT, 0x3018, 0x04},
{OV2722_8BIT, 0x3000, 0x00},
{OV2722_8BIT, 0x3001, 0x00},
{OV2722_8BIT, 0x3002, 0x00},
{OV2722_8BIT, 0x3a0f, 0x40},
{OV2722_8BIT, 0x3a10, 0x38},
{OV2722_8BIT, 0x3a1b, 0x48},
{OV2722_8BIT, 0x3a1e, 0x30},
{OV2722_8BIT, 0x3a11, 0x90},
{OV2722_8BIT, 0x3a1f, 0x10},
{OV2722_8BIT, 0x3011, 0x22},
{OV2722_8BIT, 0x3a00, 0x58},
{OV2722_8BIT, 0x3503, 0x17},
{OV2722_8BIT, 0x3500, 0x00},
{OV2722_8BIT, 0x3501, 0x46},
{OV2722_8BIT, 0x3502, 0x00},
{OV2722_8BIT, 0x3508, 0x00},
{OV2722_8BIT, 0x3509, 0x10},
{OV2722_TOK_TERM, 0, 0},
};
static struct ov2722_reg const ov2722_480P_30fps[] = {
{OV2722_8BIT, 0x3718, 0x10},
{OV2722_8BIT, 0x3702, 0x18},
{OV2722_8BIT, 0x373a, 0x3c},
{OV2722_8BIT, 0x3715, 0x01},
{OV2722_8BIT, 0x3703, 0x1d},
{OV2722_8BIT, 0x3705, 0x12},
{OV2722_8BIT, 0x3730, 0x1f},
{OV2722_8BIT, 0x3704, 0x3f},
{OV2722_8BIT, 0x3f06, 0x1d},
{OV2722_8BIT, 0x371c, 0x00},
{OV2722_8BIT, 0x371d, 0x83},
{OV2722_8BIT, 0x371e, 0x00},
{OV2722_8BIT, 0x371f, 0xbd},
{OV2722_8BIT, 0x3708, 0x63},
{OV2722_8BIT, 0x3709, 0x52},
{OV2722_8BIT, 0x3800, 0x00},
{OV2722_8BIT, 0x3801, 0xf2},
{OV2722_8BIT, 0x3802, 0x00},
{OV2722_8BIT, 0x3803, 0x20},
{OV2722_8BIT, 0x3804, 0x06},
{OV2722_8BIT, 0x3805, 0xBB},
{OV2722_8BIT, 0x3806, 0x04},
{OV2722_8BIT, 0x3807, 0x03},
{OV2722_8BIT, 0x3808, 0x02},
{OV2722_8BIT, 0x3809, 0xE0},
{OV2722_8BIT, 0x380a, 0x01},
{OV2722_8BIT, 0x380b, 0xF0},
{OV2722_8BIT, 0x380c, 0x08},
{OV2722_8BIT, 0x380d, 0x00},
{OV2722_8BIT, 0x380e, 0x04},
{OV2722_8BIT, 0x380f, 0xa0},
{OV2722_8BIT, 0x3810, 0x00},
{OV2722_8BIT, 0x3811, 0x04},
{OV2722_8BIT, 0x3812, 0x00},
{OV2722_8BIT, 0x3813, 0x01},
{OV2722_8BIT, 0x3820, 0x80},
{OV2722_8BIT, 0x3821, 0x06},
{OV2722_8BIT, 0x3814, 0x31},
{OV2722_8BIT, 0x3815, 0x31},
{OV2722_8BIT, 0x3612, 0x4b},
{OV2722_8BIT, 0x3618, 0x04},
{OV2722_8BIT, 0x3a08, 0x02},
{OV2722_8BIT, 0x3a09, 0x67},
{OV2722_8BIT, 0x3a0a, 0x02},
{OV2722_8BIT, 0x3a0b, 0x00},
{OV2722_8BIT, 0x3a0d, 0x00},
{OV2722_8BIT, 0x3a0e, 0x00},
{OV2722_8BIT, 0x4520, 0x0a},
{OV2722_8BIT, 0x4837, 0x1b},
{OV2722_8BIT, 0x3000, 0xff},
{OV2722_8BIT, 0x3001, 0xff},
{OV2722_8BIT, 0x3002, 0xf0},
{OV2722_8BIT, 0x3600, 0x08},
{OV2722_8BIT, 0x3621, 0xc0},
{OV2722_8BIT, 0x3632, 0x53},
{OV2722_8BIT, 0x3633, 0x63},
{OV2722_8BIT, 0x3634, 0x24},
{OV2722_8BIT, 0x3f01, 0x0c},
{OV2722_8BIT, 0x5001, 0xc1},
{OV2722_8BIT, 0x3614, 0xf0},
{OV2722_8BIT, 0x3630, 0x2d},
{OV2722_8BIT, 0x370b, 0x62},
{OV2722_8BIT, 0x3706, 0x61},
{OV2722_8BIT, 0x4000, 0x02},
{OV2722_8BIT, 0x4002, 0xc5},
{OV2722_8BIT, 0x4005, 0x08},
{OV2722_8BIT, 0x404f, 0x84},
{OV2722_8BIT, 0x4051, 0x00},
{OV2722_8BIT, 0x5000, 0xff},
{OV2722_8BIT, 0x3a18, 0x00},
{OV2722_8BIT, 0x3a19, 0x80},
{OV2722_8BIT, 0x4521, 0x00},
{OV2722_8BIT, 0x5183, 0xb0},
{OV2722_8BIT, 0x5184, 0xb0},
{OV2722_8BIT, 0x5185, 0xb0},
{OV2722_8BIT, 0x5180, 0x03},
{OV2722_8BIT, 0x370c, 0x0c},
{OV2722_8BIT, 0x4800, 0x24},
{OV2722_8BIT, 0x3035, 0x00},
{OV2722_8BIT, 0x3036, 0x26},
{OV2722_8BIT, 0x3037, 0xa1},
{OV2722_8BIT, 0x303e, 0x19},
{OV2722_8BIT, 0x3038, 0x06},
{OV2722_8BIT, 0x3018, 0x04},
{OV2722_8BIT, 0x3000, 0x00},
{OV2722_8BIT, 0x3001, 0x00},
{OV2722_8BIT, 0x3002, 0x00},
{OV2722_8BIT, 0x3a0f, 0x40},
{OV2722_8BIT, 0x3a10, 0x38},
{OV2722_8BIT, 0x3a1b, 0x48},
{OV2722_8BIT, 0x3a1e, 0x30},
{OV2722_8BIT, 0x3a11, 0x90},
{OV2722_8BIT, 0x3a1f, 0x10},
{OV2722_8BIT, 0x3011, 0x22},
{OV2722_8BIT, 0x3a00, 0x58},
{OV2722_8BIT, 0x3503, 0x17},
{OV2722_8BIT, 0x3500, 0x00},
{OV2722_8BIT, 0x3501, 0x46},
{OV2722_8BIT, 0x3502, 0x00},
{OV2722_8BIT, 0x3508, 0x00},
{OV2722_8BIT, 0x3509, 0x10},
{OV2722_TOK_TERM, 0, 0},
};
static struct ov2722_reg const ov2722_VGA_30fps[] = {
{OV2722_8BIT, 0x3718, 0x10},
{OV2722_8BIT, 0x3702, 0x18},
{OV2722_8BIT, 0x373a, 0x3c},
{OV2722_8BIT, 0x3715, 0x01},
{OV2722_8BIT, 0x3703, 0x1d},
{OV2722_8BIT, 0x3705, 0x12},
{OV2722_8BIT, 0x3730, 0x1f},
{OV2722_8BIT, 0x3704, 0x3f},
{OV2722_8BIT, 0x3f06, 0x1d},
{OV2722_8BIT, 0x371c, 0x00},
{OV2722_8BIT, 0x371d, 0x83},
{OV2722_8BIT, 0x371e, 0x00},
{OV2722_8BIT, 0x371f, 0xbd},
{OV2722_8BIT, 0x3708, 0x63},
{OV2722_8BIT, 0x3709, 0x52},
{OV2722_8BIT, 0x3800, 0x01},
{OV2722_8BIT, 0x3801, 0x42},
{OV2722_8BIT, 0x3802, 0x00},
{OV2722_8BIT, 0x3803, 0x20},
{OV2722_8BIT, 0x3804, 0x06},
{OV2722_8BIT, 0x3805, 0x6B},
{OV2722_8BIT, 0x3806, 0x04},
{OV2722_8BIT, 0x3807, 0x03},
{OV2722_8BIT, 0x3808, 0x02},
{OV2722_8BIT, 0x3809, 0x90},
{OV2722_8BIT, 0x380a, 0x01},
{OV2722_8BIT, 0x380b, 0xF0},
{OV2722_8BIT, 0x380c, 0x08},
{OV2722_8BIT, 0x380d, 0x00},
{OV2722_8BIT, 0x380e, 0x04},
{OV2722_8BIT, 0x380f, 0xa0},
{OV2722_8BIT, 0x3810, 0x00},
{OV2722_8BIT, 0x3811, 0x04},
{OV2722_8BIT, 0x3812, 0x00},
{OV2722_8BIT, 0x3813, 0x01},
{OV2722_8BIT, 0x3820, 0x80},
{OV2722_8BIT, 0x3821, 0x06},
{OV2722_8BIT, 0x3814, 0x31},
{OV2722_8BIT, 0x3815, 0x31},
{OV2722_8BIT, 0x3612, 0x4b},
{OV2722_8BIT, 0x3618, 0x04},
{OV2722_8BIT, 0x3a08, 0x02},
{OV2722_8BIT, 0x3a09, 0x67},
{OV2722_8BIT, 0x3a0a, 0x02},
{OV2722_8BIT, 0x3a0b, 0x00},
{OV2722_8BIT, 0x3a0d, 0x00},
{OV2722_8BIT, 0x3a0e, 0x00},
{OV2722_8BIT, 0x4520, 0x0a},
{OV2722_8BIT, 0x4837, 0x29},
{OV2722_8BIT, 0x3000, 0xff},
{OV2722_8BIT, 0x3001, 0xff},
{OV2722_8BIT, 0x3002, 0xf0},
{OV2722_8BIT, 0x3600, 0x08},
{OV2722_8BIT, 0x3621, 0xc0},
{OV2722_8BIT, 0x3632, 0x53},
{OV2722_8BIT, 0x3633, 0x63},
{OV2722_8BIT, 0x3634, 0x24},
{OV2722_8BIT, 0x3f01, 0x0c},
{OV2722_8BIT, 0x5001, 0xc1},
{OV2722_8BIT, 0x3614, 0xf0},
{OV2722_8BIT, 0x3630, 0x2d},
{OV2722_8BIT, 0x370b, 0x62},
{OV2722_8BIT, 0x3706, 0x61},
{OV2722_8BIT, 0x4000, 0x02},
{OV2722_8BIT, 0x4002, 0xc5},
{OV2722_8BIT, 0x4005, 0x08},
{OV2722_8BIT, 0x404f, 0x84},
{OV2722_8BIT, 0x4051, 0x00},
{OV2722_8BIT, 0x5000, 0xff},
{OV2722_8BIT, 0x3a18, 0x00},
{OV2722_8BIT, 0x3a19, 0x80},
{OV2722_8BIT, 0x4521, 0x00},
{OV2722_8BIT, 0x5183, 0xb0},
{OV2722_8BIT, 0x5184, 0xb0},
{OV2722_8BIT, 0x5185, 0xb0},
{OV2722_8BIT, 0x5180, 0x03},
{OV2722_8BIT, 0x370c, 0x0c},
{OV2722_8BIT, 0x4800, 0x24},
{OV2722_8BIT, 0x3035, 0x00},
{OV2722_8BIT, 0x3036, 0x26},
{OV2722_8BIT, 0x3037, 0xa1},
{OV2722_8BIT, 0x303e, 0x19},
{OV2722_8BIT, 0x3038, 0x06},
{OV2722_8BIT, 0x3018, 0x04},
{OV2722_8BIT, 0x3000, 0x00},
{OV2722_8BIT, 0x3001, 0x00},
{OV2722_8BIT, 0x3002, 0x00},
{OV2722_8BIT, 0x3a0f, 0x40},
{OV2722_8BIT, 0x3a10, 0x38},
{OV2722_8BIT, 0x3a1b, 0x48},
{OV2722_8BIT, 0x3a1e, 0x30},
{OV2722_8BIT, 0x3a11, 0x90},
{OV2722_8BIT, 0x3a1f, 0x10},
{OV2722_8BIT, 0x3011, 0x22},
{OV2722_8BIT, 0x3a00, 0x58},
{OV2722_8BIT, 0x3503, 0x17},
{OV2722_8BIT, 0x3500, 0x00},
{OV2722_8BIT, 0x3501, 0x46},
{OV2722_8BIT, 0x3502, 0x00},
{OV2722_8BIT, 0x3508, 0x00},
{OV2722_8BIT, 0x3509, 0x10},
{OV2722_TOK_TERM, 0, 0},
};
#endif
static struct ov2722_reg const ov2722_1632_1092_30fps[] = …;
static struct ov2722_reg const ov2722_1452_1092_30fps[] = …;
#if 0
static struct ov2722_reg const ov2722_1M3_30fps[] = {
{OV2722_8BIT, 0x3718, 0x10},
{OV2722_8BIT, 0x3702, 0x24},
{OV2722_8BIT, 0x373a, 0x60},
{OV2722_8BIT, 0x3715, 0x01},
{OV2722_8BIT, 0x3703, 0x2e},
{OV2722_8BIT, 0x3705, 0x10},
{OV2722_8BIT, 0x3730, 0x30},
{OV2722_8BIT, 0x3704, 0x62},
{OV2722_8BIT, 0x3f06, 0x3a},
{OV2722_8BIT, 0x371c, 0x00},
{OV2722_8BIT, 0x371d, 0xc4},
{OV2722_8BIT, 0x371e, 0x01},
{OV2722_8BIT, 0x371f, 0x0d},
{OV2722_8BIT, 0x3708, 0x61},
{OV2722_8BIT, 0x3709, 0x12},
{OV2722_8BIT, 0x3800, 0x01},
{OV2722_8BIT, 0x3801, 0x4a},
{OV2722_8BIT, 0x3802, 0x00},
{OV2722_8BIT, 0x3803, 0x03},
{OV2722_8BIT, 0x3804, 0x06},
{OV2722_8BIT, 0x3805, 0xe1},
{OV2722_8BIT, 0x3806, 0x04},
{OV2722_8BIT, 0x3807, 0x47},
{OV2722_8BIT, 0x3808, 0x05},
{OV2722_8BIT, 0x3809, 0x88},
{OV2722_8BIT, 0x380a, 0x04},
{OV2722_8BIT, 0x380b, 0x0a},
{OV2722_8BIT, 0x380c, 0x08},
{OV2722_8BIT, 0x380d, 0x00},
{OV2722_8BIT, 0x380e, 0x04},
{OV2722_8BIT, 0x380f, 0xa0},
{OV2722_8BIT, 0x3810, 0x00},
{OV2722_8BIT, 0x3811, 0x05},
{OV2722_8BIT, 0x3812, 0x00},
{OV2722_8BIT, 0x3813, 0x02},
{OV2722_8BIT, 0x3820, 0x80},
{OV2722_8BIT, 0x3821, 0x06},
{OV2722_8BIT, 0x3814, 0x11},
{OV2722_8BIT, 0x3815, 0x11},
{OV2722_8BIT, 0x3612, 0x0b},
{OV2722_8BIT, 0x3618, 0x04},
{OV2722_8BIT, 0x3a08, 0x01},
{OV2722_8BIT, 0x3a09, 0x50},
{OV2722_8BIT, 0x3a0a, 0x01},
{OV2722_8BIT, 0x3a0b, 0x18},
{OV2722_8BIT, 0x3a0d, 0x03},
{OV2722_8BIT, 0x3a0e, 0x03},
{OV2722_8BIT, 0x4520, 0x00},
{OV2722_8BIT, 0x4837, 0x1b},
{OV2722_8BIT, 0x3000, 0xff},
{OV2722_8BIT, 0x3001, 0xff},
{OV2722_8BIT, 0x3002, 0xf0},
{OV2722_8BIT, 0x3600, 0x08},
{OV2722_8BIT, 0x3621, 0xc0},
{OV2722_8BIT, 0x3632, 0xd2},
{OV2722_8BIT, 0x3633, 0x23},
{OV2722_8BIT, 0x3634, 0x54},
{OV2722_8BIT, 0x3f01, 0x0c},
{OV2722_8BIT, 0x5001, 0xc1},
{OV2722_8BIT, 0x3614, 0xf0},
{OV2722_8BIT, 0x3630, 0x2d},
{OV2722_8BIT, 0x370b, 0x62},
{OV2722_8BIT, 0x3706, 0x61},
{OV2722_8BIT, 0x4000, 0x02},
{OV2722_8BIT, 0x4002, 0xc5},
{OV2722_8BIT, 0x4005, 0x08},
{OV2722_8BIT, 0x404f, 0x84},
{OV2722_8BIT, 0x4051, 0x00},
{OV2722_8BIT, 0x5000, 0xcf},
{OV2722_8BIT, 0x3a18, 0x00},
{OV2722_8BIT, 0x3a19, 0x80},
{OV2722_8BIT, 0x4521, 0x00},
{OV2722_8BIT, 0x5183, 0xb0},
{OV2722_8BIT, 0x5184, 0xb0},
{OV2722_8BIT, 0x5185, 0xb0},
{OV2722_8BIT, 0x5180, 0x03},
{OV2722_8BIT, 0x370c, 0x0c},
{OV2722_8BIT, 0x4800, 0x24},
{OV2722_8BIT, 0x3035, 0x00},
{OV2722_8BIT, 0x3036, 0x26},
{OV2722_8BIT, 0x3037, 0xa1},
{OV2722_8BIT, 0x303e, 0x19},
{OV2722_8BIT, 0x3038, 0x06},
{OV2722_8BIT, 0x3018, 0x04},
{OV2722_8BIT, 0x3000, 0x00},
{OV2722_8BIT, 0x3001, 0x00},
{OV2722_8BIT, 0x3002, 0x00},
{OV2722_8BIT, 0x3a0f, 0x40},
{OV2722_8BIT, 0x3a10, 0x38},
{OV2722_8BIT, 0x3a1b, 0x48},
{OV2722_8BIT, 0x3a1e, 0x30},
{OV2722_8BIT, 0x3a11, 0x90},
{OV2722_8BIT, 0x3a1f, 0x10},
{OV2722_8BIT, 0x3503, 0x17},
{OV2722_8BIT, 0x3500, 0x00},
{OV2722_8BIT, 0x3501, 0x46},
{OV2722_8BIT, 0x3502, 0x00},
{OV2722_8BIT, 0x3508, 0x00},
{OV2722_8BIT, 0x3509, 0x10},
{OV2722_TOK_TERM, 0, 0},
};
#endif
static struct ov2722_reg const ov2722_1080p_30fps[] = …;
#if 0
static struct ov2722_reg const ov2722_720p_30fps[] = {
{OV2722_8BIT, 0x3021, 0x03},
{OV2722_8BIT, 0x3718, 0x10},
{OV2722_8BIT, 0x3702, 0x24},
{OV2722_8BIT, 0x373a, 0x60},
{OV2722_8BIT, 0x3715, 0x01},
{OV2722_8BIT, 0x3703, 0x2e},
{OV2722_8BIT, 0x3705, 0x10},
{OV2722_8BIT, 0x3730, 0x30},
{OV2722_8BIT, 0x3704, 0x62},
{OV2722_8BIT, 0x3f06, 0x3a},
{OV2722_8BIT, 0x371c, 0x00},
{OV2722_8BIT, 0x371d, 0xc4},
{OV2722_8BIT, 0x371e, 0x01},
{OV2722_8BIT, 0x371f, 0x0d},
{OV2722_8BIT, 0x3708, 0x61},
{OV2722_8BIT, 0x3709, 0x12},
{OV2722_8BIT, 0x3800, 0x01},
{OV2722_8BIT, 0x3801, 0x40},
{OV2722_8BIT, 0x3802, 0x00},
{OV2722_8BIT, 0x3803, 0xb1},
{OV2722_8BIT, 0x3804, 0x06},
{OV2722_8BIT, 0x3805, 0x55},
{OV2722_8BIT, 0x3806, 0x03},
{OV2722_8BIT, 0x3807, 0x95},
{OV2722_8BIT, 0x3808, 0x05},
{OV2722_8BIT, 0x3809, 0x10},
{OV2722_8BIT, 0x380a, 0x02},
{OV2722_8BIT, 0x380b, 0xe0},
{OV2722_8BIT, 0x380c, 0x08},
{OV2722_8BIT, 0x380d, 0x00},
{OV2722_8BIT, 0x380e, 0x04},
{OV2722_8BIT, 0x380f, 0xa3},
{OV2722_8BIT, 0x3810, 0x00},
{OV2722_8BIT, 0x3811, 0x03},
{OV2722_8BIT, 0x3812, 0x00},
{OV2722_8BIT, 0x3813, 0x02},
{OV2722_8BIT, 0x3820, 0x80},
{OV2722_8BIT, 0x3821, 0x06},
{OV2722_8BIT, 0x3814, 0x11},
{OV2722_8BIT, 0x3815, 0x11},
{OV2722_8BIT, 0x3612, 0x0b},
{OV2722_8BIT, 0x3618, 0x04},
{OV2722_8BIT, 0x3a08, 0x01},
{OV2722_8BIT, 0x3a09, 0x50},
{OV2722_8BIT, 0x3a0a, 0x01},
{OV2722_8BIT, 0x3a0b, 0x18},
{OV2722_8BIT, 0x3a0d, 0x03},
{OV2722_8BIT, 0x3a0e, 0x03},
{OV2722_8BIT, 0x4520, 0x00},
{OV2722_8BIT, 0x4837, 0x1b},
{OV2722_8BIT, 0x3600, 0x08},
{OV2722_8BIT, 0x3621, 0xc0},
{OV2722_8BIT, 0x3632, 0xd2},
{OV2722_8BIT, 0x3633, 0x23},
{OV2722_8BIT, 0x3634, 0x54},
{OV2722_8BIT, 0x3f01, 0x0c},
{OV2722_8BIT, 0x5001, 0xc1},
{OV2722_8BIT, 0x3614, 0xf0},
{OV2722_8BIT, 0x3630, 0x2d},
{OV2722_8BIT, 0x370b, 0x62},
{OV2722_8BIT, 0x3706, 0x61},
{OV2722_8BIT, 0x4000, 0x02},
{OV2722_8BIT, 0x4002, 0xc5},
{OV2722_8BIT, 0x4005, 0x08},
{OV2722_8BIT, 0x404f, 0x84},
{OV2722_8BIT, 0x4051, 0x00},
{OV2722_8BIT, 0x5000, 0xcf},
{OV2722_8BIT, 0x301d, 0xf0},
{OV2722_8BIT, 0x3a18, 0x00},
{OV2722_8BIT, 0x3a19, 0x80},
{OV2722_8BIT, 0x4521, 0x00},
{OV2722_8BIT, 0x5183, 0xb0},
{OV2722_8BIT, 0x5184, 0xb0},
{OV2722_8BIT, 0x5185, 0xb0},
{OV2722_8BIT, 0x370c, 0x0c},
{OV2722_8BIT, 0x3035, 0x00},
{OV2722_8BIT, 0x3036, 0x26},
{OV2722_8BIT, 0x3037, 0xa1},
{OV2722_8BIT, 0x303e, 0x19},
{OV2722_8BIT, 0x3038, 0x06},
{OV2722_8BIT, 0x3018, 0x04},
{OV2722_8BIT, 0x3000, 0x00},
{OV2722_8BIT, 0x3001, 0x00},
{OV2722_8BIT, 0x3002, 0x00},
{OV2722_8BIT, 0x3a0f, 0x40},
{OV2722_8BIT, 0x3a10, 0x38},
{OV2722_8BIT, 0x3a1b, 0x48},
{OV2722_8BIT, 0x3a1e, 0x30},
{OV2722_8BIT, 0x3a11, 0x90},
{OV2722_8BIT, 0x3a1f, 0x10},
{OV2722_8BIT, 0x3503, 0x17},
{OV2722_8BIT, 0x3500, 0x00},
{OV2722_8BIT, 0x3501, 0x3F},
{OV2722_8BIT, 0x3502, 0x00},
{OV2722_8BIT, 0x3508, 0x00},
{OV2722_8BIT, 0x3509, 0x00},
{OV2722_TOK_TERM, 0, 0},
};
#endif
static struct ov2722_resolution ov2722_res_preview[] = …;
#define N_RES_PREVIEW …
#if 0
struct ov2722_resolution ov2722_res_still[] = {
{
.desc = "ov2722_480P_30fps",
.width = 1632,
.height = 1092,
.fps = 30,
.pix_clk_freq = 85,
.used = 0,
.pixels_per_line = 2260,
.lines_per_frame = 1244,
.skip_frames = 3,
.regs = ov2722_1632_1092_30fps,
.mipi_freq = 422400,
},
{
.desc = "ov2722_1452_1092_30fps",
.width = 1452,
.height = 1092,
.fps = 30,
.pix_clk_freq = 85,
.used = 0,
.pixels_per_line = 2260,
.lines_per_frame = 1244,
.skip_frames = 3,
.regs = ov2722_1452_1092_30fps,
.mipi_freq = 422400,
},
{
.desc = "ov2722_1080P_30fps",
.width = 1932,
.height = 1092,
.pix_clk_freq = 69,
.fps = 30,
.used = 0,
.pixels_per_line = 2068,
.lines_per_frame = 1114,
.skip_frames = 3,
.regs = ov2722_1080p_30fps,
.mipi_freq = 345600,
},
};
#define N_RES_STILL …
struct ov2722_resolution ov2722_res_video[] = {
{
.desc = "ov2722_QVGA_30fps",
.width = 336,
.height = 256,
.fps = 30,
.pix_clk_freq = 73,
.used = 0,
.pixels_per_line = 2048,
.lines_per_frame = 1184,
.skip_frames = 3,
.regs = ov2722_QVGA_30fps,
.mipi_freq = 364800,
},
{
.desc = "ov2722_480P_30fps",
.width = 736,
.height = 496,
.fps = 30,
.pix_clk_freq = 73,
.used = 0,
.pixels_per_line = 2048,
.lines_per_frame = 1184,
.skip_frames = 3,
.regs = ov2722_480P_30fps,
},
{
.desc = "ov2722_1080P_30fps",
.width = 1932,
.height = 1092,
.pix_clk_freq = 69,
.fps = 30,
.used = 0,
.pixels_per_line = 2068,
.lines_per_frame = 1114,
.skip_frames = 3,
.regs = ov2722_1080p_30fps,
.mipi_freq = 345600,
},
};
#define N_RES_VIDEO …
#endif
static struct ov2722_resolution *ov2722_res = …;
static unsigned long N_RES = …;
#endif