aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/sn9c102/sn9c102_tas5130d1b.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/video/sn9c102/sn9c102_tas5130d1b.c')
-rw-r--r--drivers/media/video/sn9c102/sn9c102_tas5130d1b.c19
1 files changed, 6 insertions, 13 deletions
diff --git a/drivers/media/video/sn9c102/sn9c102_tas5130d1b.c b/drivers/media/video/sn9c102/sn9c102_tas5130d1b.c
index cb1b318bc1ff..50406503fc40 100644
--- a/drivers/media/video/sn9c102/sn9c102_tas5130d1b.c
+++ b/drivers/media/video/sn9c102/sn9c102_tas5130d1b.c
@@ -22,21 +22,14 @@
22#include "sn9c102_sensor.h" 22#include "sn9c102_sensor.h"
23 23
24 24
25static struct sn9c102_sensor tas5130d1b;
26
27
28static int tas5130d1b_init(struct sn9c102_device* cam) 25static int tas5130d1b_init(struct sn9c102_device* cam)
29{ 26{
30 int err = 0; 27 int err;
31 28
32 err += sn9c102_write_reg(cam, 0x01, 0x01); 29 err = sn9c102_write_const_regs(cam, {0x01, 0x01}, {0x20, 0x17},
33 err += sn9c102_write_reg(cam, 0x20, 0x17); 30 {0x04, 0x01}, {0x01, 0x10},
34 err += sn9c102_write_reg(cam, 0x04, 0x01); 31 {0x00, 0x11}, {0x00, 0x14},
35 err += sn9c102_write_reg(cam, 0x01, 0x10); 32 {0x60, 0x17}, {0x07, 0x18});
36 err += sn9c102_write_reg(cam, 0x00, 0x11);
37 err += sn9c102_write_reg(cam, 0x00, 0x14);
38 err += sn9c102_write_reg(cam, 0x60, 0x17);
39 err += sn9c102_write_reg(cam, 0x07, 0x18);
40 33
41 return err; 34 return err;
42} 35}
@@ -99,7 +92,7 @@ static int tas5130d1b_set_pix_format(struct sn9c102_device* cam,
99static struct sn9c102_sensor tas5130d1b = { 92static struct sn9c102_sensor tas5130d1b = {
100 .name = "TAS5130D1B", 93 .name = "TAS5130D1B",
101 .maintainer = "Luca Risolia <luca.risolia@studio.unibo.it>", 94 .maintainer = "Luca Risolia <luca.risolia@studio.unibo.it>",
102 .supported_bridge = BRIDGE_SN9C101 | BRIDGE_SN9C102 | BRIDGE_SN9C103, 95 .supported_bridge = BRIDGE_SN9C101 | BRIDGE_SN9C102,
103 .sysfs_ops = SN9C102_I2C_WRITE, 96 .sysfs_ops = SN9C102_I2C_WRITE,
104 .frequency = SN9C102_I2C_100KHZ, 97 .frequency = SN9C102_I2C_100KHZ,
105 .interface = SN9C102_I2C_3WIRES, 98 .interface = SN9C102_I2C_3WIRES,