Commit c2d405aa authored by Manivannan Sadhasivam's avatar Manivannan Sadhasivam Committed by Johan Hovold

USB: serial: add MaxLinear/Exar USB to Serial driver

Add support for MaxLinear/Exar USB to Serial converters. This driver
only supports XR21V141X series but it can be extended to other series
from Exar as well in future.

This driver is inspired from the initial one submitted by Patong Yang:

https://lore.kernel.org/r/20180404070634.nhspvmxcjwfgjkcv@advantechmxl-desktop

While the initial driver was a custom tty USB driver exposing whole
new serial interface ttyXRUSBn, this version is completely based on USB
serial core thus exposing the interfaces as ttyUSBn. This will avoid
the overhead of exposing a new USB serial interface which the userspace
tools are unaware of.

The Exar XR21V141X can be used in either ACM mode using the cdc-acm
driver or in "custom driver" mode in which further features such as
hardware and software flow control, GPIO control and in-band line-status
reporting are available.

In ACM mode the device always enables RTS/CTS flow control, something
which could prevent transmission in case the CTS input isn't wired up
corrently.

A follow-on patch will prevent cdc_acm from binding whenever this driver
is enabled.
Signed-off-by: default avatarManivannan Sadhasivam <mani@kernel.org>
Link: https://lore.kernel.org/r/20201122170822.21715-2-mani@kernel.org
[ johan: fix some style nits, group related functions, drop unused
	 callbacks, and amend commit message; a few remaining
	 non-trivial issues will be fixed separately ]
Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
parent cfb0fde7
...@@ -633,6 +633,15 @@ config USB_SERIAL_UPD78F0730 ...@@ -633,6 +633,15 @@ config USB_SERIAL_UPD78F0730
To compile this driver as a module, choose M here: the To compile this driver as a module, choose M here: the
module will be called upd78f0730. module will be called upd78f0730.
config USB_SERIAL_XR
tristate "USB MaxLinear/Exar USB to Serial driver"
help
Say Y here if you want to use MaxLinear/Exar USB to Serial converter
devices.
To compile this driver as a module, choose M here: the
module will be called xr_serial.
config USB_SERIAL_DEBUG config USB_SERIAL_DEBUG
tristate "USB Debugging Device" tristate "USB Debugging Device"
help help
......
...@@ -61,4 +61,5 @@ obj-$(CONFIG_USB_SERIAL_UPD78F0730) += upd78f0730.o ...@@ -61,4 +61,5 @@ obj-$(CONFIG_USB_SERIAL_UPD78F0730) += upd78f0730.o
obj-$(CONFIG_USB_SERIAL_VISOR) += visor.o obj-$(CONFIG_USB_SERIAL_VISOR) += visor.o
obj-$(CONFIG_USB_SERIAL_WISHBONE) += wishbone-serial.o obj-$(CONFIG_USB_SERIAL_WISHBONE) += wishbone-serial.o
obj-$(CONFIG_USB_SERIAL_WHITEHEAT) += whiteheat.o obj-$(CONFIG_USB_SERIAL_WHITEHEAT) += whiteheat.o
obj-$(CONFIG_USB_SERIAL_XR) += xr_serial.o
obj-$(CONFIG_USB_SERIAL_XSENS_MT) += xsens_mt.o obj-$(CONFIG_USB_SERIAL_XSENS_MT) += xsens_mt.o
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment