summaryrefslogtreecommitdiffstats
path: root/sound/usb/endpoint.h
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2020-11-23 09:53:11 +0100
committerTakashi Iwai <tiwai@suse.de>2020-11-23 15:11:56 +0100
commitc7474d09777c3d321f9f7f6a416f276204926c54 (patch)
treeb9785328f98b046dcdf5c214e513e60fd106e64d /sound/usb/endpoint.h
parent2e43aae2bf5a4ede98cbe0c85ad104dd7ba5dfd2 (diff)
downloadlinux-c7474d09777c3d321f9f7f6a416f276204926c54.tar.bz2
ALSA: usb-audio: Add snd_usb_get_endpoint() helper
Factor out the code to obtain snd_usb_endpoint object matching with the given endpoint. It'll be used in the later patch to add the implicit feedback hw-constraint. No functional change by this patch itself. Tested-by: Keith Milner <kamilner@superlative.org> Tested-by: Dylan Robinson <dylan_robinson@motu.com> Link: https://lore.kernel.org/r/20201123085347.19667-6-tiwai@suse.de Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/usb/endpoint.h')
-rw-r--r--sound/usb/endpoint.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/sound/usb/endpoint.h b/sound/usb/endpoint.h
index d23fa0a8c11b..61487095a766 100644
--- a/sound/usb/endpoint.h
+++ b/sound/usb/endpoint.h
@@ -5,6 +5,10 @@
#define SND_USB_ENDPOINT_TYPE_DATA 0
#define SND_USB_ENDPOINT_TYPE_SYNC 1
+struct snd_usb_endpoint *snd_usb_get_endpoint(struct snd_usb_audio *chip,
+ int ep_num, int iface,
+ int altsetting);
+
struct snd_usb_endpoint *snd_usb_add_endpoint(struct snd_usb_audio *chip,
struct usb_host_interface *alts,
int ep_num, int direction, int type);