USB: serial: add calc_num_ports callback to generic driver
authorJohan Hovold <johan@kernel.org>
Thu, 16 Mar 2017 16:13:32 +0000 (17:13 +0100)
committerJohan Hovold <johan@kernel.org>
Tue, 28 Mar 2017 08:54:39 +0000 (10:54 +0200)
commita794499b261b8487a984783ccc864975e1bcc7bf
tree57dfa404104d6fd86e756c1c10dd5d1ff3e9143b
parent415d7b3a5407d91fdf47a07fd31d63e4b548651f
USB: serial: add calc_num_ports callback to generic driver

Add a calc_num_ports callback to the generic driver and verify that the
device has the required endpoints there instead of in core.

Note that the generic driver num_ports field was never used.

Signed-off-by: Johan Hovold <johan@kernel.org>
drivers/usb/serial/generic.c
drivers/usb/serial/usb-serial.c
include/linux/usb/serial.h