Searched refs:a3d (Results 1 - 6 of 6) sorted by relevance

/linux-4.1.27/drivers/input/joystick/
H A Da3d.c54 struct a3d { struct
113 static void a3d_read(struct a3d *a3d, unsigned char *data) a3d_read() argument
115 struct input_dev *dev = a3d->dev; a3d_read()
117 switch (a3d->mode) { a3d_read()
132 a3d->axes[0] = ((signed char)((data[11] << 6) | (data[12] << 3) | (data[13]))) + 128; a3d_read()
133 a3d->axes[1] = ((signed char)((data[14] << 6) | (data[15] << 3) | (data[16]))) + 128; a3d_read()
134 a3d->axes[2] = ((signed char)((data[17] << 6) | (data[18] << 3) | (data[19]))) + 128; a3d_read()
135 a3d->axes[3] = ((signed char)((data[20] << 6) | (data[21] << 3) | (data[22]))) + 128; a3d_read()
137 a3d->buttons = ((data[3] << 3) | data[4]) & 0xf; a3d_read()
180 struct a3d *a3d = gameport_get_drvdata(gameport); a3d_poll() local
183 a3d->reads++; a3d_poll()
184 if (a3d_read_packet(a3d->gameport, a3d->length, data) != a3d->length || a3d_poll()
185 data[0] != a3d->mode || a3d_csum(data, a3d->length)) a3d_poll()
186 a3d->bads++; a3d_poll()
188 a3d_read(a3d, data); a3d_poll()
199 struct a3d *a3d = gameport->port_data; a3d_adc_cooked_read() local
203 axes[i] = (a3d->axes[i] < 254) ? a3d->axes[i] : -1; a3d_adc_cooked_read()
204 *buttons = a3d->buttons; a3d_adc_cooked_read()
215 struct a3d *a3d = gameport->port_data; a3d_adc_open() local
220 gameport_start_polling(a3d->gameport); a3d_adc_open()
230 struct a3d *a3d = gameport->port_data; a3d_adc_close() local
232 gameport_stop_polling(a3d->gameport); a3d_adc_close()
241 struct a3d *a3d = input_get_drvdata(dev); a3d_open() local
243 gameport_start_polling(a3d->gameport); a3d_open()
253 struct a3d *a3d = input_get_drvdata(dev); a3d_close() local
255 gameport_stop_polling(a3d->gameport); a3d_close()
264 struct a3d *a3d; a3d_connect() local
271 a3d = kzalloc(sizeof(struct a3d), GFP_KERNEL); a3d_connect()
273 if (!a3d || !input_dev) { a3d_connect()
278 a3d->dev = input_dev; a3d_connect()
279 a3d->gameport = gameport; a3d_connect()
281 gameport_set_drvdata(gameport, a3d); a3d_connect()
294 a3d->mode = data[0]; a3d_connect()
296 if (!a3d->mode || a3d->mode > 5) { a3d_connect()
297 printk(KERN_WARNING "a3d.c: Unknown A3D device detected " a3d_connect()
298 "(%s, id=%d), contact <vojtech@ucw.cz>\n", gameport->phys, a3d->mode); a3d_connect()
306 snprintf(a3d->phys, sizeof(a3d->phys), "%s/input0", gameport->phys); a3d_connect()
308 input_dev->name = a3d_names[a3d->mode]; a3d_connect()
309 input_dev->phys = a3d->phys; a3d_connect()
312 input_dev->id.product = a3d->mode; a3d_connect()
318 input_set_drvdata(input_dev, a3d); a3d_connect()
320 if (a3d->mode == A3D_MODE_PXL) { a3d_connect()
324 a3d->length = 33; a3d_connect()
340 a3d_read(a3d, data); a3d_connect()
352 a3d->length = 29; a3d_connect()
359 a3d_read(a3d, data); a3d_connect()
361 if (!(a3d->adc = adc = gameport_allocate_port())) a3d_connect()
362 printk(KERN_ERR "a3d: Not enough memory for ADC port\n"); a3d_connect()
364 adc->port_data = a3d; a3d_connect()
370 gameport_set_name(adc, a3d_names[a3d->mode]); a3d_connect()
378 err = input_register_device(a3d->dev); a3d_connect()
384 fail3: if (a3d->adc) a3d_connect()
385 gameport_unregister_port(a3d->adc); a3d_connect()
389 kfree(a3d); a3d_connect()
395 struct a3d *a3d = gameport_get_drvdata(gameport); a3d_disconnect() local
397 input_unregister_device(a3d->dev); a3d_disconnect()
398 if (a3d->adc) a3d_disconnect()
399 gameport_unregister_port(a3d->adc); a3d_disconnect()
402 kfree(a3d); a3d_disconnect()
/linux-4.1.27/sound/pci/au88x0/
H A Dau88x0_a3d.h102 /* There are 4 slices, 4 a3d each = 16 a3d sources. */
H A Dau88x0_a3d.c556 a3dsrc_t *a3dsrc = &(v->a3d[source + (slice * 4)]); vortex_A3dSourceHw_Initialize()
557 //a3dsrc_t *a3dsrc = &(v->a3d[source + (slice*4)]); vortex_A3dSourceHw_Initialize()
605 a3dsrc_ZeroStateA3D(&v->a3d[0], v); vortex_Vort3D_enable()
784 /* Translate orientation coordinates to a3d params. */ snd_vortex_a3d_hrtf_put()
801 /* Translate orientation coordinates to a3d params. */ snd_vortex_a3d_itd_put()
837 /* Translate generic filter params to a3d filter params. */ snd_vortex_a3d_filter_put()
866 snd_ctl_new1(&vortex_a3d_kcontrol, &vortex->a3d[i])) == NULL) vortex_a3d_register_controls()
877 snd_ctl_new1(&vortex_a3d_kcontrol, &vortex->a3d[i])) == NULL) vortex_a3d_register_controls()
888 snd_ctl_new1(&vortex_a3d_kcontrol, &vortex->a3d[i])) == NULL) vortex_a3d_register_controls()
899 snd_ctl_new1(&vortex_a3d_kcontrol, &vortex->a3d[i])) == NULL) vortex_a3d_register_controls()
H A Dau88x0.h127 int type; /* Output type (ac97, a3d, spdif, i2s, dsp) */
164 s8 mixa3d[2]; /* mixers which collect all a3d streams. */
173 a3dsrc_t a3d[NR_A3D]; member in struct:snd_vortex
H A Dau88x0_pcm.c465 "a3d",
H A Dau88x0_core.c2145 int a3d = 0; vortex_adb_allocroute() local
2173 if ((a3d = vortex_adb_allocroute()
2185 vortex_Vort3D_InitializeSource(&vortex->a3d[a3d], en, vortex_adb_allocroute()
2227 vortex_route(vortex, en, 0x11, ADB_SRCOUT(src[i]), ADB_A3DIN(a3d)); vortex_adb_allocroute()

Completed in 143 milliseconds