[PATCH] Add all baudrates supported by Linux
Kevin Buettner
kevinb@redhat.com
Sat Sep 26 18:19:11 GMT 2020
On Fri, 25 Sep 2020 22:06:37 -0500
"Sid Spry" <sid@aeam.us> wrote:
> From 5324872818e550e572c361bb60d9098cfc8e8d87 Mon Sep 17 00:00:00 2001
> From: Sid Spry <sid@aeam.us>
> Date: Fri, 25 Sep 2020 21:43:25 -0500
> Subject: [PATCH] Add all baudrates supported by Linux
>
> I recently started work with a device lacking the documentation to change the
> platform serial port. It may be worth automating this to keep it up to date, and/or
> implementing the termios mechanism by which you specify a bitrate directly.
>
> rg '#define \s+B[1-9]+[0-9]+\s+' /usr/src/linux 2>/dev/null \
> | awk '{ print length($2), $2; }' \
> | sort | uniq \
> | perl -ne '/.*?\sB(.*)/ && print "#ifdef B$1\n {\n $1, B$1\n }\n ,\n#endif\n"'
>
> It compiles and works for baud 1500000, the others are confirmed visible.
It needs a ChangeLog entry, but looks good otherwise.
Kevin
More information about the Gdb-patches
mailing list