• Takashi Iwai's avatar
    ALSA: usb - Fix Oops after usb-midi disconnection · 29aac005
    Takashi Iwai authored
    usb-midi causes sometimes Oops at snd_usbmidi_output_drain() after
    disconnection.  This is due to the access to the endpoints which have
    been already released at disconnection while the files are still alive.
    
    This patch fixes the problem by checking disconnection state at
    snd_usbmidi_output_drain() and by releasing urbs but keeping the
    endpoint instances until really all freed.
    Tested-by: default avatarTvrtko Ursulin <tvrtko@ursulin.net>
    Cc: <stable@kernel.org>
    Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
    29aac005
usbmidi.c 58.2 KB