diff options
author | Erik Andrén <erik.andren@gmail.com> | 2008-11-27 11:55:07 -0500 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2008-12-30 06:39:58 -0500 |
commit | 83fdea270ca5a648185525f61d27c9068355215c (patch) | |
tree | 5a75e8aacf34390c352ae0007e50d88bb402a9cc /drivers/media/video/gspca | |
parent | 6b9c0a2aad5a64ee7eb605e35bc761d901782d25 (diff) |
V4L/DVB (10028): mt5602: Remove the s5k83a specific read_sensor function
Signed-off-by: Erik Andrén <erik.andren@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/gspca')
-rw-r--r-- | drivers/media/video/gspca/m5602/m5602_s5k83a.c | 37 | ||||
-rw-r--r-- | drivers/media/video/gspca/m5602/m5602_s5k83a.h | 3 |
2 files changed, 0 insertions, 40 deletions
diff --git a/drivers/media/video/gspca/m5602/m5602_s5k83a.c b/drivers/media/video/gspca/m5602/m5602_s5k83a.c index 811766b32693..af3f2dc2c702 100644 --- a/drivers/media/video/gspca/m5602/m5602_s5k83a.c +++ b/drivers/media/video/gspca/m5602/m5602_s5k83a.c | |||
@@ -70,43 +70,6 @@ sensor_found: | |||
70 | return 0; | 70 | return 0; |
71 | } | 71 | } |
72 | 72 | ||
73 | int s5k83a_read_sensor(struct sd *sd, const u8 address, | ||
74 | u8 *i2c_data, const u8 len) | ||
75 | { | ||
76 | int err, i; | ||
77 | |||
78 | do { | ||
79 | err = m5602_read_bridge(sd, M5602_XB_I2C_STATUS, i2c_data); | ||
80 | } while ((*i2c_data & I2C_BUSY) && !err); | ||
81 | if (err < 0) | ||
82 | goto out; | ||
83 | |||
84 | err = m5602_write_bridge(sd, M5602_XB_I2C_DEV_ADDR, | ||
85 | sd->sensor->i2c_slave_id); | ||
86 | if (err < 0) | ||
87 | goto out; | ||
88 | |||
89 | err = m5602_write_bridge(sd, M5602_XB_I2C_REG_ADDR, address); | ||
90 | if (err < 0) | ||
91 | goto out; | ||
92 | |||
93 | err = m5602_write_bridge(sd, M5602_XB_I2C_CTRL, 0x18 + len); | ||
94 | |||
95 | do { | ||
96 | err = m5602_read_bridge(sd, M5602_XB_I2C_STATUS, i2c_data); | ||
97 | } while ((*i2c_data & I2C_BUSY) && !err); | ||
98 | |||
99 | for (i = 0; i < len && !len; i++) { | ||
100 | err = m5602_read_bridge(sd, M5602_XB_I2C_DATA, &(i2c_data[i])); | ||
101 | |||
102 | PDEBUG(D_CONF, "Reading sensor register " | ||
103 | "0x%x containing 0x%x ", address, *i2c_data); | ||
104 | } | ||
105 | |||
106 | out: | ||
107 | return err; | ||
108 | } | ||
109 | |||
110 | int s5k83a_init(struct sd *sd) | 73 | int s5k83a_init(struct sd *sd) |
111 | { | 74 | { |
112 | int i, err = 0; | 75 | int i, err = 0; |
diff --git a/drivers/media/video/gspca/m5602/m5602_s5k83a.h b/drivers/media/video/gspca/m5602/m5602_s5k83a.h index 735701127965..05ccb5b57a88 100644 --- a/drivers/media/video/gspca/m5602/m5602_s5k83a.h +++ b/drivers/media/video/gspca/m5602/m5602_s5k83a.h | |||
@@ -46,9 +46,6 @@ int s5k83a_probe(struct sd *sd); | |||
46 | int s5k83a_init(struct sd *sd); | 46 | int s5k83a_init(struct sd *sd); |
47 | int s5k83a_power_down(struct sd *sd); | 47 | int s5k83a_power_down(struct sd *sd); |
48 | 48 | ||
49 | int s5k83a_read_sensor(struct sd *sd, const u8 address, | ||
50 | u8 *i2c_data, const u8 len); | ||
51 | |||
52 | int s5k83a_set_brightness(struct gspca_dev *gspca_dev, __s32 val); | 49 | int s5k83a_set_brightness(struct gspca_dev *gspca_dev, __s32 val); |
53 | int s5k83a_get_brightness(struct gspca_dev *gspca_dev, __s32 *val); | 50 | int s5k83a_get_brightness(struct gspca_dev *gspca_dev, __s32 *val); |
54 | int s5k83a_set_whiteness(struct gspca_dev *gspca_dev, __s32 val); | 51 | int s5k83a_set_whiteness(struct gspca_dev *gspca_dev, __s32 val); |