media: imx415: use RAW10 GRBG mode on BPI-M8

This commit is contained in:
Qubot 2026-06-14 23:53:55 +08:00
parent e49ff5bdd9
commit bcc122d2ac

View File

@ -56,8 +56,8 @@ MODULE_LICENSE("GPL");
static struct regval_list sensor_default_regs[] = {
};
static struct regval_list sensor_12bit_30fps_regs[] = {
/* All pixel - 891Mbps - 74.25MHz external INCK */
static struct regval_list sensor_10bit_30fps_7425_regs[] = {
/* All pixel - 720Mbps RAW10 - 74.25MHz external INCK */
{0x3000, 0x01},/* stanby */
{0x3001, 0x00},
{0x3002, 0x01},/* XMSTA start */
@ -79,8 +79,8 @@ static struct regval_list sensor_12bit_30fps_regs[] = {
{0x302C, 0x00},/* DOL mode 0:normal 1:dol */
{0x302D, 0x00},/* wdsel 0:normal exposure 1:dol_2 2:dol_3 3:multiple exposure 4frame */
{0x3030, 0x00},/* */
{0x3031, 0x01},/* adbit 0:10bit ,1 :12bit */
{0x3032, 0x01},/* mdbit 0:10bit 1:12bit */
{0x3031, 0x00},/* adbit 0:10bit ,1 :12bit */
{0x3032, 0x00},/* mdbit 0:10bit 1:12bit */
{0x3033, 0x05},
{0x3040, 0x00},/* window cropping */
{0x3041, 0x00},
@ -148,7 +148,7 @@ static struct regval_list sensor_12bit_30fps_regs[] = {
{0x36D8, 0x71},
{0x36DA, 0x8C},
{0x36DB, 0x00},
{0x3701, 0x03},/* ADBIT 00h:10bit 03h:12bit */
{0x3701, 0x00},/* ADBIT 00h:10bit 03h:12bit */
{0x3724, 0x02},
{0x3726, 0x02},
{0x3732, 0x02},
@ -985,7 +985,7 @@ static long sensor_ioctl(struct v4l2_subdev *sd, unsigned int cmd, void *arg)
static struct sensor_format_struct sensor_formats[] = {
{
.desc = "Raw RGB Bayer",
.mbus_code = MEDIA_BUS_FMT_SGBRG12_1X12,
.mbus_code = MEDIA_BUS_FMT_SGRBG10_1X10,
.regs = sensor_fmt_raw,
.regs_size = ARRAY_SIZE(sensor_fmt_raw),
.bpp = 1
@ -1021,7 +1021,7 @@ static struct sensor_win_size sensor_win_sizes[] = {
},
*/
#if 1
{ /* 30fps 12bit */
{ /* 30fps 10bit, 74.25MHz external INCK */
.width = 3840,
.height = 2160,
.hoffset = 0,
@ -1029,15 +1029,15 @@ static struct sensor_win_size sensor_win_sizes[] = {
.hts = 1100,
.vts = 2250,
.pclk = 74 * 1000 * 1000,
.mipi_bps = 891 * 1000 * 1000,
.mipi_bps = 720 * 1000 * 1000,
.fps_fixed = 30,
.bin_factor = 1,
.intg_min = 8<<4,
.intg_max = (2250 - 4) << 4,
.gain_min = 1<<4,
.gain_max = 5631<<4,
.regs = sensor_12bit_30fps_regs,
.regs_size = ARRAY_SIZE(sensor_12bit_30fps_regs),
.regs = sensor_10bit_30fps_7425_regs,
.regs_size = ARRAY_SIZE(sensor_10bit_30fps_7425_regs),
.set_size = NULL,
},