USB: serial: mos7720: clean up mcs7715 port setup
authorJohan Hovold <johan@kernel.org>
Thu, 16 Mar 2017 16:13:45 +0000 (17:13 +0100)
committerJohan Hovold <johan@kernel.org>
Tue, 28 Mar 2017 09:00:11 +0000 (11:00 +0200)
commitd760557d38ba62a8fe91dec5e32acb4fdf52d9d4
treebb576dacfa7a01e08b49d0b036c4db1ac45c0ef4
parent772b2c5d6c929d9d35e9c915dea8df8c6a799aed
USB: serial: mos7720: clean up mcs7715 port setup

Clean up the mcs7715 port setup by using the new endpoint-remap
functionality provided by core. Instead of poking around in internal
port-structure fields, simply swap the endpoint descriptors of the two
ports in calc_num_ports before the port structures are even allocated.

Note that we still need to override the default interrupt completion
handler.

Signed-off-by: Johan Hovold <johan@kernel.org>
drivers/usb/serial/mos7720.c