Commit cfebcd53 authored by Amireddy mallikarjuna reddy's avatar Amireddy mallikarjuna reddy Committed by Johan Hovold

USB: serial: ftdi_sio: add support for HP and HA devices

Add the product IDs for the USB-to-Serial devices FT2233HP, FT2232HP,
FT4233HP, FT4232HP, FT233HP, FT232HP, and FT4232HA.
Also include BCD values so that the chip type can be determined.
Signed-off-by: default avatarAmireddy mallikarjuna reddy <mallikarjuna.reddy@ftdichip.com>
Link: https://lore.kernel.org/r/ac28f2c5eba23a645b3b9299c224f2755a233eef.1658385786.git.mallikarjuna.reddy@ftdichip.com
[ johan: rebase on type-handling rework, drop "Q" from automotive type
         name ]
Signed-off-by: default avatarJohan Hovold <johan@kernel.org>
parent 1a039891
......@@ -56,6 +56,13 @@ enum ftdi_chip_type {
FT232H,
FT2232H,
FT4232H,
FT4232HA,
FT232HP,
FT233HP,
FT2232HP,
FT2233HP,
FT4232HP,
FT4233HP,
FTX,
};
......@@ -189,6 +196,13 @@ static const struct usb_device_id id_table_combined[] = {
{ USB_DEVICE(FTDI_VID, FTDI_4232H_PID) },
{ USB_DEVICE(FTDI_VID, FTDI_232H_PID) },
{ USB_DEVICE(FTDI_VID, FTDI_FTX_PID) },
{ USB_DEVICE(FTDI_VID, FTDI_FT2233HP_PID) },
{ USB_DEVICE(FTDI_VID, FTDI_FT4233HP_PID) },
{ USB_DEVICE(FTDI_VID, FTDI_FT2232HP_PID) },
{ USB_DEVICE(FTDI_VID, FTDI_FT4232HP_PID) },
{ USB_DEVICE(FTDI_VID, FTDI_FT233HP_PID) },
{ USB_DEVICE(FTDI_VID, FTDI_FT232HP_PID) },
{ USB_DEVICE(FTDI_VID, FTDI_FT4232HA_PID) },
{ USB_DEVICE(FTDI_VID, FTDI_MICRO_CHAMELEON_PID) },
{ USB_DEVICE(FTDI_VID, FTDI_RELAIS_PID) },
{ USB_DEVICE(FTDI_VID, FTDI_OPENDCC_PID) },
......@@ -1078,6 +1092,13 @@ static const char *ftdi_chip_name[] = {
[FT232H] = "FT232H",
[FT2232H] = "FT2232H",
[FT4232H] = "FT4232H",
[FT4232HA] = "FT4232HA",
[FT232HP] = "FT232HP",
[FT233HP] = "FT233HP",
[FT2232HP] = "FT2232HP",
[FT2233HP] = "FT2233HP",
[FT4232HP] = "FT4232HP",
[FT4233HP] = "FT4233HP",
[FTX] = "FT-X",
};
......@@ -1595,6 +1616,27 @@ static int ftdi_determine_type(struct usb_serial_port *port)
priv->chip_type = FTX;
priv->baud_base = 48000000 / 2;
break;
case 0x2800:
priv->chip_type = FT2233HP;
break;
case 0x2900:
priv->chip_type = FT4233HP;
break;
case 0x3000:
priv->chip_type = FT2232HP;
break;
case 0x3100:
priv->chip_type = FT4232HP;
break;
case 0x3200:
priv->chip_type = FT233HP;
break;
case 0x3300:
priv->chip_type = FT232HP;
break;
case 0x3600:
priv->chip_type = FT4232HA;
break;
default:
if (version < 0x200) {
priv->chip_type = SIO;
......
......@@ -25,6 +25,13 @@
#define FTDI_4232H_PID 0x6011 /* Quad channel hi-speed device */
#define FTDI_232H_PID 0x6014 /* Single channel hi-speed device */
#define FTDI_FTX_PID 0x6015 /* FT-X series (FT201X, FT230X, FT231X, etc) */
#define FTDI_FT2233HP_PID 0x6040 /* Dual channel hi-speed device with PD */
#define FTDI_FT4233HP_PID 0x6041 /* Quad channel hi-speed device with PD */
#define FTDI_FT2232HP_PID 0x6042 /* Dual channel hi-speed device with PD */
#define FTDI_FT4232HP_PID 0x6043 /* Quad channel hi-speed device with PD */
#define FTDI_FT233HP_PID 0x6044 /* Dual channel hi-speed device with PD */
#define FTDI_FT232HP_PID 0x6045 /* Dual channel hi-speed device with PD */
#define FTDI_FT4232HA_PID 0x6048 /* Quad channel automotive grade hi-speed device */
#define FTDI_SIO_PID 0x8372 /* Product Id SIO application of 8U100AX */
#define FTDI_232RL_PID 0xFBFA /* Product ID for FT232RL */
......
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