Home
last modified time | relevance | path

Searched refs:sd (Results 1 – 25 of 481) sorted by relevance

12345678910>>...20

/drivers/media/usb/gspca/
Dov519.c50 struct sd { struct
1989 static void reg_w(struct sd *sd, u16 index, u16 value) in reg_w() argument
1991 struct gspca_dev *gspca_dev = (struct gspca_dev *)sd; in reg_w()
1994 if (sd->gspca_dev.usb_err < 0) in reg_w()
2000 switch (sd->bridge) { in reg_w()
2011 ret = usb_control_msg(sd->gspca_dev.dev, in reg_w()
2012 usb_sndctrlpipe(sd->gspca_dev.dev, 0), in reg_w()
2023 sd->gspca_dev.usb_buf[0] = value; in reg_w()
2024 ret = usb_control_msg(sd->gspca_dev.dev, in reg_w()
2025 usb_sndctrlpipe(sd->gspca_dev.dev, 0), in reg_w()
[all …]
Dw996Xcf.c24 #define Y_QUANTABLE (&sd->jpeg_hdr[JPEG_QT0_OFFSET])
25 #define UV_QUANTABLE (&sd->jpeg_hdr[JPEG_QT1_OFFSET])
50 static void reg_w(struct sd *sd, u16 index, u16 value);
56 static void w9968cf_write_fsb(struct sd *sd, u16* data) in w9968cf_write_fsb() argument
58 struct usb_device *udev = sd->gspca_dev.dev; in w9968cf_write_fsb()
62 if (sd->gspca_dev.usb_err < 0) in w9968cf_write_fsb()
66 memcpy(sd->gspca_dev.usb_buf, data, 6); in w9968cf_write_fsb()
72 value, 0x06, sd->gspca_dev.usb_buf, 6, 500); in w9968cf_write_fsb()
75 sd->gspca_dev.usb_err = ret; in w9968cf_write_fsb()
83 static void w9968cf_write_sb(struct sd *sd, u16 value) in w9968cf_write_sb() argument
[all …]
Dcpia1.c214 #define FIRMWARE_VERSION(x, y) (sd->params.version.firmwareVersion == (x) && \
215 sd->params.version.firmwareRevision == (y))
353 struct sd { struct
441 struct sd *sd = (struct sd *) gspca_dev; in do_command() local
479 sd->params.version.firmwareVersion = gspca_dev->usb_buf[0]; in do_command()
480 sd->params.version.firmwareRevision = gspca_dev->usb_buf[1]; in do_command()
481 sd->params.version.vcVersion = gspca_dev->usb_buf[2]; in do_command()
482 sd->params.version.vcRevision = gspca_dev->usb_buf[3]; in do_command()
485 sd->params.pnpID.vendor = in do_command()
487 sd->params.pnpID.product = in do_command()
[all …]
Dsn9c20x.c55 struct sd { struct
979 struct sd *sd = (struct sd *) gspca_dev; in i2c_w1() local
986 row[0] = sd->i2c_intf | (2 << 4); in i2c_w1()
987 row[1] = sd->i2c_addr; in i2c_w1()
1009 struct sd *sd = (struct sd *) gspca_dev; in i2c_w2() local
1016 row[0] = sd->i2c_intf | (3 << 4); in i2c_w2()
1017 row[1] = sd->i2c_addr; in i2c_w2()
1039 struct sd *sd = (struct sd *) gspca_dev; in i2c_r1() local
1042 row[0] = sd->i2c_intf | (1 << 4); in i2c_r1()
1043 row[1] = sd->i2c_addr; in i2c_r1()
[all …]
/drivers/media/i2c/
Dadv7842.c90 struct v4l2_subdev sd; member
247 static inline struct adv7842_state *to_state(struct v4l2_subdev *sd) in to_state() argument
249 return container_of(sd, struct adv7842_state, sd); in to_state()
254 return &container_of(ctrl->handler, struct adv7842_state, hdl)->sd; in to_sd()
362 static inline int io_read(struct v4l2_subdev *sd, u8 reg) in io_read() argument
364 struct i2c_client *client = v4l2_get_subdevdata(sd); in io_read()
369 static inline int io_write(struct v4l2_subdev *sd, u8 reg, u8 val) in io_write() argument
371 struct i2c_client *client = v4l2_get_subdevdata(sd); in io_write()
376 static inline int io_write_and_or(struct v4l2_subdev *sd, u8 reg, u8 mask, u8 val) in io_write_and_or() argument
378 return io_write(sd, reg, (io_read(sd, reg) & mask) | val); in io_write_and_or()
[all …]
Dad9389b.c69 struct v4l2_subdev sd; member
92 static void ad9389b_check_monitor_present_status(struct v4l2_subdev *sd);
93 static bool ad9389b_check_edid_status(struct v4l2_subdev *sd);
94 static void ad9389b_setup(struct v4l2_subdev *sd);
95 static int ad9389b_s_i2s_clock_freq(struct v4l2_subdev *sd, u32 freq);
96 static int ad9389b_s_clock_freq(struct v4l2_subdev *sd, u32 freq);
98 static inline struct ad9389b_state *get_ad9389b_state(struct v4l2_subdev *sd) in get_ad9389b_state() argument
100 return container_of(sd, struct ad9389b_state, sd); in get_ad9389b_state()
105 return &container_of(ctrl->handler, struct ad9389b_state, hdl)->sd; in to_sd()
110 static int ad9389b_rd(struct v4l2_subdev *sd, u8 reg) in ad9389b_rd() argument
[all …]
Dtc358743.c73 struct v4l2_subdev sd; member
102 static void tc358743_enable_interrupts(struct v4l2_subdev *sd,
104 static int tc358743_s_ctrl_detect_tx_5v(struct v4l2_subdev *sd);
106 static inline struct tc358743_state *to_state(struct v4l2_subdev *sd) in to_state() argument
108 return container_of(sd, struct tc358743_state, sd); in to_state()
113 static void i2c_rd(struct v4l2_subdev *sd, u16 reg, u8 *values, u32 n) in i2c_rd() argument
115 struct tc358743_state *state = to_state(sd); in i2c_rd()
136 v4l2_err(sd, "%s: reading register 0x%x from 0x%x failed\n", in i2c_rd()
141 static void i2c_wr(struct v4l2_subdev *sd, u16 reg, u8 *values, u32 n) in i2c_wr() argument
143 struct tc358743_state *state = to_state(sd); in i2c_wr()
[all …]
Dadv7511-v4l2.c84 struct v4l2_subdev sd; member
127 static void adv7511_check_monitor_present_status(struct v4l2_subdev *sd);
128 static bool adv7511_check_edid_status(struct v4l2_subdev *sd);
129 static void adv7511_setup(struct v4l2_subdev *sd);
130 static int adv7511_s_i2s_clock_freq(struct v4l2_subdev *sd, u32 freq);
131 static int adv7511_s_clock_freq(struct v4l2_subdev *sd, u32 freq);
146 static inline struct adv7511_state *get_adv7511_state(struct v4l2_subdev *sd) in get_adv7511_state() argument
148 return container_of(sd, struct adv7511_state, sd); in get_adv7511_state()
153 return &container_of(ctrl->handler, struct adv7511_state, hdl)->sd; in to_sd()
188 static int adv7511_rd(struct v4l2_subdev *sd, u8 reg) in adv7511_rd() argument
[all …]
Dadv7183.c25 struct v4l2_subdev sd; member
63 static inline struct adv7183 *to_adv7183(struct v4l2_subdev *sd) in to_adv7183() argument
65 return container_of(sd, struct adv7183, sd); in to_adv7183()
69 return &container_of(ctrl->handler, struct adv7183, hdl)->sd; in to_sd()
72 static inline int adv7183_read(struct v4l2_subdev *sd, unsigned char reg) in adv7183_read() argument
74 struct i2c_client *client = v4l2_get_subdevdata(sd); in adv7183_read()
79 static inline int adv7183_write(struct v4l2_subdev *sd, unsigned char reg, in adv7183_write() argument
82 struct i2c_client *client = v4l2_get_subdevdata(sd); in adv7183_write()
87 static int adv7183_writeregs(struct v4l2_subdev *sd, in adv7183_writeregs() argument
94 v4l2_err(sd, "invalid regs array\n"); in adv7183_writeregs()
[all …]
Dths8200.c41 struct v4l2_subdev sd; member
56 static inline struct ths8200_state *to_state(struct v4l2_subdev *sd) in to_state() argument
58 return container_of(sd, struct ths8200_state, sd); in to_state()
71 static int ths8200_read(struct v4l2_subdev *sd, u8 reg) in ths8200_read() argument
73 struct i2c_client *client = v4l2_get_subdevdata(sd); in ths8200_read()
78 static int ths8200_write(struct v4l2_subdev *sd, u8 reg, u8 val) in ths8200_write() argument
80 struct i2c_client *client = v4l2_get_subdevdata(sd); in ths8200_write()
89 v4l2_err(sd, "I2C Write Problem\n"); in ths8200_write()
97 ths8200_write_and_or(struct v4l2_subdev *sd, u8 reg, in ths8200_write_and_or() argument
100 ths8200_write(sd, reg, (ths8200_read(sd, reg) & clr_mask) | val_mask); in ths8200_write_and_or()
[all …]
Dadv7604.c126 void (*set_termination)(struct v4l2_subdev *sd, bool enable);
127 void (*setup_irqs)(struct v4l2_subdev *sd);
128 unsigned int (*read_hdmi_pixelclock)(struct v4l2_subdev *sd);
129 unsigned int (*read_cable_det)(struct v4l2_subdev *sd);
167 struct v4l2_subdev sd; member
320 static inline struct adv76xx_state *to_state(struct v4l2_subdev *sd) in to_state() argument
322 return container_of(sd, struct adv76xx_state, sd); in to_state()
374 static inline int io_read(struct v4l2_subdev *sd, u8 reg) in io_read() argument
376 struct adv76xx_state *state = to_state(sd); in io_read()
381 static inline int io_write(struct v4l2_subdev *sd, u8 reg, u8 val) in io_write() argument
[all …]
Dsaa7110.c42 struct v4l2_subdev sd; member
53 static inline struct saa7110 *to_saa7110(struct v4l2_subdev *sd) in to_saa7110() argument
55 return container_of(sd, struct saa7110, sd); in to_saa7110()
60 return &container_of(ctrl->handler, struct saa7110, hdl)->sd; in to_sd()
67 static int saa7110_write(struct v4l2_subdev *sd, u8 reg, u8 value) in saa7110_write() argument
69 struct i2c_client *client = v4l2_get_subdevdata(sd); in saa7110_write()
70 struct saa7110 *decoder = to_saa7110(sd); in saa7110_write()
76 static int saa7110_write_block(struct v4l2_subdev *sd, const u8 *data, unsigned int len) in saa7110_write_block() argument
78 struct i2c_client *client = v4l2_get_subdevdata(sd); in saa7110_write_block()
79 struct saa7110 *decoder = to_saa7110(sd); in saa7110_write_block()
[all …]
Dks0127.c187 struct v4l2_subdev sd; member
192 static inline struct ks0127 *to_ks0127(struct v4l2_subdev *sd) in to_ks0127() argument
194 return container_of(sd, struct ks0127, sd); in to_ks0127()
302 static u8 ks0127_read(struct v4l2_subdev *sd, u8 reg) in ks0127_read() argument
304 struct i2c_client *client = v4l2_get_subdevdata(sd); in ks0127_read()
323 v4l2_dbg(1, debug, sd, "read error\n"); in ks0127_read()
329 static void ks0127_write(struct v4l2_subdev *sd, u8 reg, u8 val) in ks0127_write() argument
331 struct i2c_client *client = v4l2_get_subdevdata(sd); in ks0127_write()
332 struct ks0127 *ks = to_ks0127(sd); in ks0127_write()
336 v4l2_dbg(1, debug, sd, "write error\n"); in ks0127_write()
[all …]
Dadv7175.c38 struct v4l2_subdev sd; member
43 static inline struct adv7175 *to_adv7175(struct v4l2_subdev *sd) in to_adv7175() argument
45 return container_of(sd, struct adv7175, sd); in to_adv7175()
57 static inline int adv7175_write(struct v4l2_subdev *sd, u8 reg, u8 value) in adv7175_write() argument
59 struct i2c_client *client = v4l2_get_subdevdata(sd); in adv7175_write()
64 static inline int adv7175_read(struct v4l2_subdev *sd, u8 reg) in adv7175_read() argument
66 struct i2c_client *client = v4l2_get_subdevdata(sd); in adv7175_read()
71 static int adv7175_write_block(struct v4l2_subdev *sd, in adv7175_write_block() argument
74 struct i2c_client *client = v4l2_get_subdevdata(sd); in adv7175_write_block()
102 ret = adv7175_write(sd, reg, *data++); in adv7175_write_block()
[all …]
Dsaa717x.c44 struct v4l2_subdev sd; member
63 static inline struct saa717x_state *to_state(struct v4l2_subdev *sd) in to_state() argument
65 return container_of(sd, struct saa717x_state, sd); in to_state()
70 return &container_of(ctrl->handler, struct saa717x_state, hdl)->sd; in to_sd()
86 static int saa717x_write(struct v4l2_subdev *sd, u32 reg, u32 value) in saa717x_write() argument
88 struct i2c_client *client = v4l2_get_subdevdata(sd); in saa717x_write()
108 v4l2_dbg(2, debug, sd, "wrote: reg 0x%03x=%08x\n", reg, value); in saa717x_write()
112 static void saa717x_write_regs(struct v4l2_subdev *sd, u32 *data) in saa717x_write_regs() argument
115 saa717x_write(sd, data[0], data[1]); in saa717x_write_regs()
120 static u32 saa717x_read(struct v4l2_subdev *sd, u32 reg) in saa717x_read() argument
[all …]
/drivers/scsi/aic7xxx/
Daic7xxx_93cx6.c95 #define CLOCK_PULSE(sd, rdy) \ argument
96 while ((SEEPROM_STATUS_INB(sd) & rdy) == 0) { \
99 (void)SEEPROM_INB(sd); /* Clear clock */
105 send_seeprom_cmd(struct seeprom_descriptor *sd, const struct seeprom_cmd *cmd) in send_seeprom_cmd() argument
111 temp = sd->sd_MS ^ sd->sd_CS; in send_seeprom_cmd()
112 SEEPROM_OUTB(sd, temp ^ sd->sd_CK); in send_seeprom_cmd()
113 CLOCK_PULSE(sd, sd->sd_RDY); in send_seeprom_cmd()
117 temp ^= sd->sd_DO; in send_seeprom_cmd()
118 SEEPROM_OUTB(sd, temp); in send_seeprom_cmd()
119 CLOCK_PULSE(sd, sd->sd_RDY); in send_seeprom_cmd()
[all …]
/drivers/media/platform/davinci/
Dvpbe_venc.c53 struct v4l2_subdev sd; member
65 static inline struct venc_state *to_state(struct v4l2_subdev *sd) in to_state() argument
67 return container_of(sd, struct venc_state, sd); in to_state()
70 static inline u32 venc_read(struct v4l2_subdev *sd, u32 offset) in venc_read() argument
72 struct venc_state *venc = to_state(sd); in venc_read()
77 static inline u32 venc_write(struct v4l2_subdev *sd, u32 offset, u32 val) in venc_write() argument
79 struct venc_state *venc = to_state(sd); in venc_write()
86 static inline u32 venc_modify(struct v4l2_subdev *sd, u32 offset, in venc_modify() argument
89 u32 new_val = (venc_read(sd, offset) & ~mask) | (val & mask); in venc_modify()
91 venc_write(sd, offset, new_val); in venc_modify()
[all …]
Dvpbe_osd.c48 static inline u32 osd_read(struct osd_state *sd, u32 offset) in osd_read() argument
50 struct osd_state *osd = sd; in osd_read()
55 static inline u32 osd_write(struct osd_state *sd, u32 val, u32 offset) in osd_write() argument
57 struct osd_state *osd = sd; in osd_write()
64 static inline u32 osd_set(struct osd_state *sd, u32 mask, u32 offset) in osd_set() argument
66 struct osd_state *osd = sd; in osd_set()
76 static inline u32 osd_clear(struct osd_state *sd, u32 mask, u32 offset) in osd_clear() argument
78 struct osd_state *osd = sd; in osd_clear()
88 static inline u32 osd_modify(struct osd_state *sd, u32 mask, u32 val, in osd_modify() argument
91 struct osd_state *osd = sd; in osd_modify()
[all …]
/drivers/media/usb/gspca/m5602/
Dm5602_core.c52 int m5602_read_bridge(struct sd *sd, const u8 address, u8 *i2c_data) in m5602_read_bridge() argument
55 struct gspca_dev *gspca_dev = (struct gspca_dev *) sd; in m5602_read_bridge()
56 struct usb_device *udev = sd->gspca_dev.dev; in m5602_read_bridge()
57 __u8 *buf = sd->gspca_dev.usb_buf; in m5602_read_bridge()
74 int m5602_write_bridge(struct sd *sd, const u8 address, const u8 i2c_data) in m5602_write_bridge() argument
77 struct gspca_dev *gspca_dev = (struct gspca_dev *) sd; in m5602_write_bridge()
78 struct usb_device *udev = sd->gspca_dev.dev; in m5602_write_bridge()
79 __u8 *buf = sd->gspca_dev.usb_buf; in m5602_write_bridge()
99 static int m5602_wait_for_i2c(struct sd *sd) in m5602_wait_for_i2c() argument
105 err = m5602_read_bridge(sd, M5602_XB_I2C_STATUS, &data); in m5602_wait_for_i2c()
[all …]
Dm5602_po1030.c20 static void po1030_dump_registers(struct sd *sd);
155 int po1030_probe(struct sd *sd) in po1030_probe() argument
159 struct gspca_dev *gspca_dev = (struct gspca_dev *)sd; in po1030_probe()
177 err = m5602_write_sensor(sd, preinit_po1030[i][1], in po1030_probe()
180 err = m5602_write_bridge(sd, preinit_po1030[i][1], in po1030_probe()
186 if (m5602_read_sensor(sd, PO1030_DEVID_H, &dev_id_h, 1)) in po1030_probe()
196 sd->gspca_dev.cam.cam_mode = po1030_modes; in po1030_probe()
197 sd->gspca_dev.cam.nmodes = ARRAY_SIZE(po1030_modes); in po1030_probe()
202 int po1030_init(struct sd *sd) in po1030_init() argument
212 err = m5602_write_bridge(sd, in po1030_init()
[all …]
Dm5602_s5k83a.c164 static void s5k83a_dump_registers(struct sd *sd);
165 static int s5k83a_get_rotation(struct sd *sd, u8 *reg_data);
166 static int s5k83a_set_led_indication(struct sd *sd, u8 val);
170 int s5k83a_probe(struct sd *sd) in s5k83a_probe() argument
174 struct gspca_dev *gspca_dev = (struct gspca_dev *)sd; in s5k83a_probe()
192 err = m5602_write_sensor(sd, preinit_s5k83a[i][1], in s5k83a_probe()
195 err = m5602_write_bridge(sd, preinit_s5k83a[i][1], in s5k83a_probe()
202 if (m5602_read_sensor(sd, 0x00, &prod_id, 1)) in s5k83a_probe()
205 if (m5602_read_sensor(sd, 0x01, &ver_id, 1)) in s5k83a_probe()
214 sd->gspca_dev.cam.cam_mode = s5k83a_modes; in s5k83a_probe()
[all …]
/drivers/media/usb/gspca/stv06xx/
Dstv06xx_pb0100.c79 struct sd *sd = (struct sd *)gspca_dev; in pb0100_s_ctrl() local
80 struct pb0100_ctrls *ctrls = sd->sensor_priv; in pb0100_s_ctrl()
106 static int pb0100_init_controls(struct sd *sd) in pb0100_init_controls() argument
108 struct v4l2_ctrl_handler *hdl = &sd->gspca_dev.ctrl_handler; in pb0100_init_controls()
150 sd->sensor_priv = ctrls; in pb0100_init_controls()
155 static int pb0100_probe(struct sd *sd) in pb0100_probe() argument
160 err = stv06xx_read_sensor(sd, PB_IDENT, &sensor); in pb0100_probe()
169 sd->gspca_dev.cam.cam_mode = pb0100_mode; in pb0100_probe()
170 sd->gspca_dev.cam.nmodes = ARRAY_SIZE(pb0100_mode); in pb0100_probe()
175 static int pb0100_start(struct sd *sd) in pb0100_start() argument
[all …]
Dstv06xx.c29 int stv06xx_write_bridge(struct sd *sd, u16 address, u16 i2c_data) in stv06xx_write_bridge() argument
32 struct gspca_dev *gspca_dev = (struct gspca_dev *)sd; in stv06xx_write_bridge()
33 struct usb_device *udev = sd->gspca_dev.dev; in stv06xx_write_bridge()
34 __u8 *buf = sd->gspca_dev.usb_buf; in stv06xx_write_bridge()
51 int stv06xx_read_bridge(struct sd *sd, u16 address, u8 *i2c_data) in stv06xx_read_bridge() argument
54 struct gspca_dev *gspca_dev = (struct gspca_dev *)sd; in stv06xx_read_bridge()
55 struct usb_device *udev = sd->gspca_dev.dev; in stv06xx_read_bridge()
56 __u8 *buf = sd->gspca_dev.usb_buf; in stv06xx_read_bridge()
72 int stv06xx_write_sensor(struct sd *sd, u8 address, u16 value) in stv06xx_write_sensor() argument
74 if (sd->sensor->i2c_len == 2) { in stv06xx_write_sensor()
[all …]
Dstv06xx_st6422.c49 static int setbrightness(struct sd *sd, s32 val);
50 static int setcontrast(struct sd *sd, s32 val);
51 static int setgain(struct sd *sd, u8 gain);
52 static int setexposure(struct sd *sd, s16 expo);
58 struct sd *sd = (struct sd *)gspca_dev; in st6422_s_ctrl() local
63 err = setbrightness(sd, ctrl->val); in st6422_s_ctrl()
66 err = setcontrast(sd, ctrl->val); in st6422_s_ctrl()
69 err = setgain(sd, ctrl->val); in st6422_s_ctrl()
72 err = setexposure(sd, ctrl->val); in st6422_s_ctrl()
78 err = stv06xx_write_bridge(sd, 0x143f, 0x01); in st6422_s_ctrl()
[all …]
/drivers/media/usb/gspca/gl860/
Dgl860-ov2640.c173 struct sd *sd = (struct sd *) gspca_dev; in ov2640_init_settings() local
175 sd->vcur.backlight = 32; in ov2640_init_settings()
176 sd->vcur.brightness = 0; in ov2640_init_settings()
177 sd->vcur.sharpness = 6; in ov2640_init_settings()
178 sd->vcur.contrast = 0; in ov2640_init_settings()
179 sd->vcur.gamma = 32; in ov2640_init_settings()
180 sd->vcur.hue = 0; in ov2640_init_settings()
181 sd->vcur.saturation = 128; in ov2640_init_settings()
182 sd->vcur.whitebal = 64; in ov2640_init_settings()
183 sd->vcur.mirror = 0; in ov2640_init_settings()
[all …]

12345678910>>...20