mirror of
https://github.com/torvalds/linux.git
synced 2024-11-17 09:31:50 +00:00
f6581c0e5d
Instead of parsing and evaluating the sync endpoint and the implicit feedback mode at each time the audio stream is opened, let's parse it once at the probe time, as the all needed information can be obtained statically from the descriptor or from the quirk. This patch extends audioformat struct to record the sync endpoint, interface and altsetting as well as the implicit feedback flag, which are filled at parsing the streams. Then, set_sync_endpoint() is much simplified just to follow the already parsed data. Tested-by: Keith Milner <kamilner@superlative.org> Tested-by: Dylan Robinson <dylan_robinson@motu.com> Link: https://lore.kernel.org/r/20201123085347.19667-9-tiwai@suse.de Signed-off-by: Takashi Iwai <tiwai@suse.de>
21 lines
684 B
C
21 lines
684 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#ifndef __USBAUDIO_PCM_H
|
|
#define __USBAUDIO_PCM_H
|
|
|
|
snd_pcm_uframes_t snd_usb_pcm_delay(struct snd_usb_substream *subs,
|
|
unsigned int rate);
|
|
|
|
void snd_usb_set_pcm_ops(struct snd_pcm *pcm, int stream);
|
|
int snd_usb_pcm_suspend(struct snd_usb_stream *as);
|
|
int snd_usb_pcm_resume(struct snd_usb_stream *as);
|
|
|
|
int snd_usb_init_pitch(struct snd_usb_audio *chip, int iface,
|
|
struct usb_host_interface *alts,
|
|
struct audioformat *fmt);
|
|
void snd_usb_preallocate_buffer(struct snd_usb_substream *subs);
|
|
|
|
int snd_usb_audioformat_set_sync_ep(struct snd_usb_audio *chip,
|
|
struct audioformat *fmt);
|
|
|
|
#endif /* __USBAUDIO_PCM_H */
|