mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 03:15:31 +09:00
FROMLIST: USB: gadget: f_midi: setup SuperSpeed Plus descriptors
Needed for SuperSpeed Plus support for f_midi. Bug: 170925797 Link: https://lore.kernel.org/r/20201126180937.255892-4-gregkh@linuxfoundation.org Signed-off-by: Will McVicker <willmcvicker@google.com> Change-Id: Ie16ddcb97555f4e7ef762b719ea3f7c2a251eb43 (cherry picked from commit 2746f5ffbf7a1d4ce6a933b75cf1eb4fdf7744c0) Signed-off-by: Will McVicker <willmcvicker@google.com> Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
cac70628fb
commit
743b92ddc1
@@ -1048,6 +1048,11 @@ static int f_midi_bind(struct usb_configuration *c, struct usb_function *f)
|
||||
f->ss_descriptors = usb_copy_descriptors(midi_function);
|
||||
if (!f->ss_descriptors)
|
||||
goto fail_f_midi;
|
||||
if (gadget_is_superspeed_plus(c->cdev->gadget)) {
|
||||
f->ssp_descriptors = usb_copy_descriptors(midi_function);
|
||||
if (!f->ssp_descriptors)
|
||||
goto fail_f_midi;
|
||||
}
|
||||
}
|
||||
|
||||
kfree(midi_function);
|
||||
|
||||
Reference in New Issue
Block a user