USB: serial: allow subdrivers to modify port-endpoint mapping
authorJohan Hovold <johan@kernel.org>
Thu, 16 Mar 2017 16:13:30 +0000 (17:13 +0100)
committerJohan Hovold <johan@kernel.org>
Tue, 28 Mar 2017 08:54:39 +0000 (10:54 +0200)
commit07814246dd5530860ef758fd9b2b5f2e26472aa2
treee27c9ae087d22c49b063e365df2c7f2ba479c253
parent2ac8fc51ddf152fdd2344c6d286976803183d59c
USB: serial: allow subdrivers to modify port-endpoint mapping

Allow subdrivers to modify the port-endpoint mapping by passing the
endpoint descriptors to calc_num_ports.

The callback can now also be used to verify that the required endpoints
exists and abort probing otherwise.

This will allow us to get rid of a few hacks in subdrivers that are
already modifying the port-endpoint mapping (or aborting probe due to
missing endpoints), but only after the port structures have been setup.

Signed-off-by: Johan Hovold <johan@kernel.org>
drivers/usb/serial/f81534.c
drivers/usb/serial/ipaq.c
drivers/usb/serial/mos7720.c
drivers/usb/serial/mos7840.c
drivers/usb/serial/mxuport.c
drivers/usb/serial/quatech2.c
drivers/usb/serial/sierra.c
drivers/usb/serial/usb-serial.c
drivers/usb/serial/visor.c
include/linux/usb/serial.h