| 1.1 |
| 24-Oct-2025 |
brad | A driver for the NXP SC16IS7xx family of UART chips. This family is mostly a 16C450 with features from the 16C550, 16C650 and 16C750 and makes use of src/sys/dev/ic/com.c for much of the heavy lifting.
A BIG difference is that the chip family is attached via a I2C or SPI bus and is in no way, shape or form, attached to the computer via a computer bus.
Since spin locks are not allowed to be held while calling to the I2C or SPI framework com.c grew a new hw feature flag where it could be run at something other than a hard IP level and doesn't hold spin lock (for very long). In particular, IPL_SOFTSERIAL. This method is enabled via a hw feature flag and should not effect any other use of com.c. Other changes with this new method of use include the use of workqueues and such.
A further feature added to com.c was the abilty to take advantage of the MCR prescaler that is present in the SC16IS7xx family and likely present in the 16C650. This prescaler is tried if the baud rate requested can not be met with the frequency oscillator that the chip is built with.
The chip family does not use any particular frequency oscillator for the baud rate generator. In order to deal with this the frequency can be set via sysctl, a kernel option or with a FDT overlay if that is supported.
Most of the features of the chip family are supported including the gpio pins via gpiobus(4) that are present with some of the family members.
The chip can attach via I2C or SPI and can make sure of FDT if that is present in the system.
This chip family has been around for quite some time and there are a number of breakout boards on Amazon. It is also reasonably priced and you can roll your own board if you can perform simple SMD soldering as very few additional components are required.
|