Home
last modified time | relevance | path

Searched hist:ee0309b4 (Results 1 – 1 of 1) sorted by relevance

/openbmc/linux/drivers/usb/serial/
H A Df81534.cee0309b4 Thu Jan 11 00:47:16 CST 2018 Ji-Ze Hong (Peter Hong) <hpeter@gmail.com> USB: serial: f81534: add auto RTS direction support

The F81532/534 had auto RTS direction support for RS485 mode.
We'll read it from internal Flash with address 0x2f01~0x2f04 for 4 ports.
There are 4 conditions below:
0: F81534_PORT_CONF_RS232.
1: F81534_PORT_CONF_RS485.
2: value error, default to F81534_PORT_CONF_RS232.
3: F81534_PORT_CONF_RS485_INVERT.

F81532/534 Clock register (offset +08h)

Bit0: UART Enable (always on)
Bit2-1: Clock source selector
00: 1.846MHz.
01: 18.46MHz.
10: 24MHz.
11: 14.77MHz.
Bit4: Auto direction(RTS) control (RTS pin Low when TX)
Bit5: Invert direction(RTS) when Bit4 enabled (RTS pin high when TX)

Signed-off-by: Ji-Ze Hong (Peter Hong) <hpeter+linux_kernel@gmail.com>
[ johan: rename mode-mask define, and only use GENMASK() for masks ]
Signed-off-by: Johan Hovold <johan@kernel.org>
ee0309b4 Thu Jan 11 00:47:16 CST 2018 Ji-Ze Hong (Peter Hong) <hpeter@gmail.com> USB: serial: f81534: add auto RTS direction support

The F81532/534 had auto RTS direction support for RS485 mode.
We'll read it from internal Flash with address 0x2f01~0x2f04 for 4 ports.
There are 4 conditions below:
0: F81534_PORT_CONF_RS232.
1: F81534_PORT_CONF_RS485.
2: value error, default to F81534_PORT_CONF_RS232.
3: F81534_PORT_CONF_RS485_INVERT.

F81532/534 Clock register (offset +08h)

Bit0: UART Enable (always on)
Bit2-1: Clock source selector
00: 1.846MHz.
01: 18.46MHz.
10: 24MHz.
11: 14.77MHz.
Bit4: Auto direction(RTS) control (RTS pin Low when TX)
Bit5: Invert direction(RTS) when Bit4 enabled (RTS pin high when TX)

Signed-off-by: Ji-Ze Hong (Peter Hong) <hpeter+linux_kernel@gmail.com>
[ johan: rename mode-mask define, and only use GENMASK() for masks ]
Signed-off-by: Johan Hovold <johan@kernel.org>