ret = snd_soc_usb_update_offload_route(sysdev,
CARD_IDX(kcontrol->private_value),
PCM_IDX(kcontrol->private_value),
SNDRV_PCM_STREAM_PLAYBACK,
SND_SOC_USB_KCTL_PCM_ROUTE,
ucontrol->value.integer.value); if (ret < 0) {
ucontrol->value.integer.value[0] = -1;
ucontrol->value.integer.value[1] = -1;
}
return 0;
}
staticint snd_usb_offload_pcm_route_info(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_info *uinfo)
{
uinfo->type = SNDRV_CTL_ELEM_TYPE_INTEGER;
uinfo->count = 1;
uinfo->value.integer.min = -1; /* Arbitrary max value, as there is no 'limit' on number of PCM devices */
uinfo->value.integer.max = 0xff;
/** * snd_usb_offload_create_ctl() - Add USB offload bounded mixer * @chip: USB SND chip device * @bedev: Reference to USB backend DAI device * * Creates a sound control for a USB audio device, so that applications can * query for if there is an available USB audio offload path, and which * card is managing it.
*/ int snd_usb_offload_create_ctl(struct snd_usb_audio *chip, struct device *bedev)
{ struct snd_kcontrol_new *chip_kctl; struct snd_usb_substream *subs; struct snd_usb_stream *as; char ctl_name[48]; int ret;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.