mxs-auart: redefine AUART_LINECTRL_WLEN to accept bits count
authorJiri Slaby <jslaby@suse.cz>
Thu, 10 Jun 2021 09:02:45 +0000 (11:02 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 15 Jun 2021 12:03:26 +0000 (14:03 +0200)
commit8ea43acc690ca2fe88500356f25c431d25f8a0bb
treee766f0b3b8adfe1dd61941ec2c8a14ba4e042c82
parent654ee49b7e0883e660be6e6e20876fc4cbdaadd1
mxs-auart: redefine AUART_LINECTRL_WLEN to accept bits count

It's a bit illogical to take magic constants in AUART_LINECTRL_WLEN.
Like in auart_console_get_options(), 2 means 7 bits. Switch
AUART_LINECTRL_WLEN to accept bit length, i.e. let it subtract 5 from
the parameter before doing the logic.

This will ease conversion from CSIZE to bits in mxs_auart_settermios()
in the next patch.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Link: https://lore.kernel.org/r/20210610090247.2593-2-jslaby@suse.cz
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/mxs-auart.c