Lines Matching +full:0 +full:x65

31 #define SC1810C_CMD_F1		0x50617269
32 #define SC1810C_CMD_F2 0x14
39 * device (0), mixer (0x64) and output (0x65)
41 * For mixer (0x64):
44 * * d selects left (0) or right (1) of that pair.
45 * * e 0-> disconnect, 0x01000000-> connect,
46 * 0x0109-> used for stereo-linking channels,
54 * 0 - 7 Mic/Inst/Line (Analog inputs)
60 * 0 -> Main out
66 * For device (0):
73 * in it's 0/1)
75 * For output (0x65):
78 * * e I guess the same as with mixer except 0x0109
94 #define SC1810C_CTL_LINE_SW 0
101 #define SC1810C_SET_STATE_F1 0x64656D73
102 #define SC1810C_SET_STATE_F2 0xF4
138 struct s1810c_ctl_packet pkt = { 0 }; in snd_s1810c_send_ctl_packet()
139 int ret = 0; in snd_s1810c_send_ctl_packet()
149 * Value for settings 0/1 for this in snd_s1810c_send_ctl_packet()
150 * output channel is always 0 (probably because in snd_s1810c_send_ctl_packet()
153 pkt.e = (c == 4) ? 0 : e; in snd_s1810c_send_ctl_packet()
155 ret = snd_usb_ctl_msg(dev, usb_sndctrlpipe(dev, 0), in snd_s1810c_send_ctl_packet()
157 SC1810C_CMD_REQTYPE, 0, 0, &pkt, sizeof(pkt)); in snd_s1810c_send_ctl_packet()
158 if (ret < 0) { in snd_s1810c_send_ctl_packet()
162 return 0; in snd_s1810c_send_ctl_packet()
178 struct s1810c_state_packet pkt_out = { { 0 } }; in snd_sc1810c_get_status_field()
179 struct s1810c_state_packet pkt_in = { { 0 } }; in snd_sc1810c_get_status_field()
180 int ret = 0; in snd_sc1810c_get_status_field()
184 ret = snd_usb_ctl_msg(dev, usb_rcvctrlpipe(dev, 0), in snd_sc1810c_get_status_field()
187 (*seqnum), 0, &pkt_out, sizeof(pkt_out)); in snd_sc1810c_get_status_field()
188 if (ret < 0) { in snd_sc1810c_get_status_field()
193 ret = snd_usb_ctl_msg(dev, usb_rcvctrlpipe(dev, 0), in snd_sc1810c_get_status_field()
196 (*seqnum), 0, &pkt_in, sizeof(pkt_in)); in snd_sc1810c_get_status_field()
197 if (ret < 0) { in snd_sc1810c_get_status_field()
205 return 0; in snd_sc1810c_get_status_field()
220 a = 0x64; in snd_s1810c_init_mixer_maps()
221 e = 0xbc; in snd_s1810c_init_mixer_maps()
222 for (n = 0; n < 2; n++) { in snd_s1810c_init_mixer_maps()
224 for (b = off, c = 0; b < 18 + off; b++) { in snd_s1810c_init_mixer_maps()
226 for (c = 0; c <= 8; c++) { in snd_s1810c_init_mixer_maps()
227 snd_s1810c_send_ctl_packet(dev, a, b, c, 0, e); in snd_s1810c_init_mixer_maps()
231 snd_s1810c_send_ctl_packet(dev, a, b, 0, 0, e); in snd_s1810c_init_mixer_maps()
232 snd_s1810c_send_ctl_packet(dev, a, b, 0, 1, e); in snd_s1810c_init_mixer_maps()
238 e = 0xb53bf0; in snd_s1810c_init_mixer_maps()
242 a = 0x65; in snd_s1810c_init_mixer_maps()
243 e = 0x01000000; in snd_s1810c_init_mixer_maps()
245 snd_s1810c_send_ctl_packet(dev, a, b, 0, 0, e); in snd_s1810c_init_mixer_maps()
246 snd_s1810c_send_ctl_packet(dev, a, b, 0, 1, e); in snd_s1810c_init_mixer_maps()
248 snd_s1810c_send_ctl_packet(dev, a, 0, 0, 0, e); in snd_s1810c_init_mixer_maps()
249 snd_s1810c_send_ctl_packet(dev, a, 0, 0, 1, e); in snd_s1810c_init_mixer_maps()
252 a = 0x64; in snd_s1810c_init_mixer_maps()
253 e = 0xbc; in snd_s1810c_init_mixer_maps()
255 for (n = 0; n < 2; n++) { in snd_s1810c_init_mixer_maps()
258 snd_s1810c_send_ctl_packet(dev, a, b, c, 0, e); in snd_s1810c_init_mixer_maps()
261 e = 0xb53bf0; in snd_s1810c_init_mixer_maps()
265 a = 0x65; in snd_s1810c_init_mixer_maps()
266 e = 0x01000000; in snd_s1810c_init_mixer_maps()
267 snd_s1810c_send_ctl_packet(dev, a, 3, 0, 0, e); in snd_s1810c_init_mixer_maps()
268 snd_s1810c_send_ctl_packet(dev, a, 3, 0, 1, e); in snd_s1810c_init_mixer_maps()
271 a = 0x65; in snd_s1810c_init_mixer_maps()
272 e = 0x01000000; in snd_s1810c_init_mixer_maps()
273 for (b = 0; b < 4; b++) { in snd_s1810c_init_mixer_maps()
274 snd_s1810c_send_ctl_packet(dev, a, b, 0, 0, e); in snd_s1810c_init_mixer_maps()
275 snd_s1810c_send_ctl_packet(dev, a, b, 0, 1, e); in snd_s1810c_init_mixer_maps()
279 a = 0x64; in snd_s1810c_init_mixer_maps()
280 e = 0x01000000; in snd_s1810c_init_mixer_maps()
281 for (c = 0; c < 4; c++) { in snd_s1810c_init_mixer_maps()
282 for (b = 0; b < 36; b++) { in snd_s1810c_init_mixer_maps()
283 if ((c == 0 && b == 18) || /* DAW1/2 -> Main */ in snd_s1810c_init_mixer_maps()
288 snd_s1810c_send_ctl_packet(dev, a, b, c, 0, e); in snd_s1810c_init_mixer_maps()
289 snd_s1810c_send_ctl_packet(dev, a, b, c, 1, 0); in snd_s1810c_init_mixer_maps()
292 snd_s1810c_send_ctl_packet(dev, a, b, c, 0, 0); in snd_s1810c_init_mixer_maps()
296 snd_s1810c_send_ctl_packet(dev, a, b, c, 0, 0); in snd_s1810c_init_mixer_maps()
297 snd_s1810c_send_ctl_packet(dev, a, b, c, 1, 0); in snd_s1810c_init_mixer_maps()
303 a = 0x64; in snd_s1810c_init_mixer_maps()
304 e = 0xbc; in snd_s1810c_init_mixer_maps()
306 for (n = 0; n < 2; n++) { in snd_s1810c_init_mixer_maps()
309 snd_s1810c_send_ctl_packet(dev, a, b, c, 0, e); in snd_s1810c_init_mixer_maps()
312 e = 0xb53bf0; in snd_s1810c_init_mixer_maps()
316 a = 0x65; in snd_s1810c_init_mixer_maps()
317 e = 0x01000000; in snd_s1810c_init_mixer_maps()
318 snd_s1810c_send_ctl_packet(dev, a, 3, 0, 0, e); in snd_s1810c_init_mixer_maps()
319 snd_s1810c_send_ctl_packet(dev, a, 3, 0, 1, e); in snd_s1810c_init_mixer_maps()
322 snd_s1810c_send_ctl_packet(dev, a, 3, 0, 0, e); in snd_s1810c_init_mixer_maps()
323 snd_s1810c_send_ctl_packet(dev, a, 3, 0, 1, e); in snd_s1810c_init_mixer_maps()
325 return 0; in snd_s1810c_init_mixer_maps()
330 * whose index is specified in (kctl->private_value & 0xFF),
339 u32 field = 0; in snd_s1810c_get_switch_state()
340 u32 ctl_idx = (u32) (kctl->private_value & 0xFF); in snd_s1810c_get_switch_state()
341 int ret = 0; in snd_s1810c_get_switch_state()
346 if (ret < 0) in snd_s1810c_get_switch_state()
352 return ret ? ret : 0; in snd_s1810c_get_switch_state()
367 u32 ctl_id = (pval >> 8) & 0xFF; in snd_s1810c_set_switch_state()
368 u32 ctl_val = (pval >> 16) & 0x1; in snd_s1810c_set_switch_state()
369 int ret = 0; in snd_s1810c_set_switch_state()
372 ret = snd_s1810c_send_ctl_packet(chip->dev, 0, 0, 0, ctl_id, ctl_val); in snd_s1810c_set_switch_state()
387 u32 ctl_idx = pval & 0xFF; in snd_s1810c_switch_get()
388 u32 state = 0; in snd_s1810c_switch_get()
389 int ret = 0; in snd_s1810c_switch_get()
393 if (ret < 0) in snd_s1810c_switch_get()
399 ctl_elem->value.enumerated.item[0] = (int)state; in snd_s1810c_switch_get()
402 ctl_elem->value.integer.value[0] = (long)state; in snd_s1810c_switch_get()
407 return (ret < 0) ? ret : 0; in snd_s1810c_switch_get()
418 u32 ctl_idx = pval & 0xFF; in snd_s1810c_switch_set()
419 u32 curval = 0; in snd_s1810c_switch_set()
420 u32 newval = 0; in snd_s1810c_switch_set()
421 int ret = 0; in snd_s1810c_switch_set()
425 if (ret < 0) in snd_s1810c_switch_set()
431 newval = (u32) ctl_elem->value.enumerated.item[0]; in snd_s1810c_switch_set()
434 newval = (u32) ctl_elem->value.integer.value[0]; in snd_s1810c_switch_set()
440 kctl->private_value &= ~(0x1 << 16); in snd_s1810c_switch_set()
441 kctl->private_value |= (unsigned int)(newval & 0x1) << 16; in snd_s1810c_switch_set()
446 return (ret < 0) ? 0 : 1; in snd_s1810c_switch_set()
461 elem->control = 0; in snd_s1810c_switch_init()
462 elem->head.id = 0; in snd_s1810c_switch_init()
548 int ret = 0; in snd_sc1810_init_mixer()
552 return 0; in snd_sc1810_init_mixer()
564 if (ret < 0) in snd_sc1810_init_mixer()
580 if (ret < 0) in snd_sc1810_init_mixer()
584 if (ret < 0) in snd_sc1810_init_mixer()
588 if (ret < 0) in snd_sc1810_init_mixer()
592 if (ret < 0) in snd_sc1810_init_mixer()