enum ftdi_chip_type {
SIO,
- FT8U232AM,
- FT232BM,
+ FT232A,
+ FT232B,
FT2232C,
- FT232RL,
+ FT232R,
+ FT232H,
FT2232H,
FT4232H,
- FT232H,
FTX,
};
MODULE_DEVICE_TABLE(usb, id_table_combined);
static const char *ftdi_chip_name[] = {
- [SIO] = "SIO", /* the serial part of FT8U100AX */
- [FT8U232AM] = "FT8U232AM",
- [FT232BM] = "FT232BM",
- [FT2232C] = "FT2232C",
- [FT232RL] = "FT232RL",
- [FT2232H] = "FT2232H",
- [FT4232H] = "FT4232H",
- [FT232H] = "FT232H",
- [FTX] = "FT-X"
+ [SIO] = "SIO", /* the serial part of FT8U100AX */
+ [FT232A] = "FT232A",
+ [FT232B] = "FT232B",
+ [FT2232C] = "FT2232C",
+ [FT232R] = "FT232R",
+ [FT232H] = "FT232H",
+ [FT2232H] = "FT2232H",
+ [FT4232H] = "FT4232H",
+ [FTX] = "FT-X",
};
div_okay = 0;
}
break;
- case FT8U232AM:
+ case FT232A:
if (baud <= 3000000) {
div_value = ftdi_232am_baud_to_divisor(baud);
} else {
div_okay = 0;
}
break;
- case FT232BM:
+ case FT232B:
case FT2232C:
- case FT232RL:
+ case FT232R:
case FTX:
if (baud <= 3000000) {
u16 product_id = le16_to_cpu(
int rv;
int l = priv->latency;
- if (priv->chip_type == SIO || priv->chip_type == FT8U232AM)
+ if (priv->chip_type == SIO || priv->chip_type == FT232A)
return -EINVAL;
if (priv->flags & ASYNC_LOW_LATENCY)
struct ftdi_private *priv = usb_get_serial_port_data(port);
int rv;
- if (priv->chip_type == SIO || priv->chip_type == FT8U232AM)
+ if (priv->chip_type == SIO || priv->chip_type == FT232A)
return -EINVAL;
rv = _read_latency_timer(port);
priv->baud_base = 12000000 / 16;
} else if (version < 0x400) {
/* Assume it's an FT8U232AM (or FT8U245AM) */
- priv->chip_type = FT8U232AM;
+ priv->chip_type = FT232A;
/*
* It might be a BM type because of the iSerialNumber bug.
* If iSerialNumber==0 and the latency timer is readable,
dev_dbg(&port->dev,
"%s: has latency timer so not an AM type\n",
__func__);
- priv->chip_type = FT232BM;
+ priv->chip_type = FT232B;
}
} else if (version < 0x600) {
/* Assume it's an FT232BM (or FT245BM) */
- priv->chip_type = FT232BM;
+ priv->chip_type = FT232B;
} else if (version < 0x900) {
/* Assume it's an FT232RL */
- priv->chip_type = FT232RL;
+ priv->chip_type = FT232R;
} else if (version < 0x1000) {
/* Assume it's an FT232H */
priv->chip_type = FT232H;
dev_dbg(&port->dev, "sysfs attributes for %s\n", ftdi_chip_name[priv->chip_type]);
retval = device_create_file(&port->dev, &dev_attr_event_char);
if ((!retval) &&
- (priv->chip_type == FT232BM ||
+ (priv->chip_type == FT232B ||
priv->chip_type == FT2232C ||
- priv->chip_type == FT232RL ||
+ priv->chip_type == FT232R ||
priv->chip_type == FT2232H ||
priv->chip_type == FT4232H ||
priv->chip_type == FT232H ||
/* XXX see create_sysfs_attrs */
if (priv->chip_type != SIO) {
device_remove_file(&port->dev, &dev_attr_event_char);
- if (priv->chip_type == FT232BM ||
+ if (priv->chip_type == FT232B ||
priv->chip_type == FT2232C ||
- priv->chip_type == FT232RL ||
+ priv->chip_type == FT232R ||
priv->chip_type == FT2232H ||
priv->chip_type == FT4232H ||
priv->chip_type == FT232H ||
case FT232H:
result = ftdi_gpio_init_ft232h(port);
break;
- case FT232RL:
+ case FT232R:
result = ftdi_gpio_init_ft232r(port);
break;
case FTX:
case SIO:
len = 1;
break;
- case FT8U232AM:
- case FT232BM:
+ case FT232A:
+ case FT232B:
case FT2232C:
- case FT232RL:
+ case FT232R:
case FT2232H:
case FT4232H:
case FT232H: