Commit 26de5d0a authored by Eldad Zack's avatar Eldad Zack Committed by Takashi Iwai
Browse files

ALSA: usb-audio: remove deactivate_endpoints()

The only call site for deactivate_endpoints() at snd_usb_hw_free().
The return value is not checked there, as it is irrelevant if it
fails on hw_free.
This patch moves the deactivation of the endpoints directly into
Signed-off-by: default avatarEldad Zack <>
Signed-off-by: default avatarTakashi Iwai <>
parent 93721039
......@@ -282,22 +282,6 @@ static void stop_endpoints(struct snd_usb_substream *subs, bool wait)
static int deactivate_endpoints(struct snd_usb_substream *subs)
int reta, retb;
reta = snd_usb_endpoint_deactivate(subs->sync_endpoint);
retb = snd_usb_endpoint_deactivate(subs->data_endpoint);
if (reta < 0)
return reta;
if (retb < 0)
return retb;
return 0;
static int search_roland_implicit_fb(struct usb_device *dev, int ifnum,
unsigned int altsetting,
struct usb_host_interface **alts,
......@@ -736,7 +720,8 @@ static int snd_usb_hw_free(struct snd_pcm_substream *substream)
if (!subs->stream->chip->shutdown) {
stop_endpoints(subs, true);
return snd_pcm_lib_free_vmalloc_buffer(substream);
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment