Attention is currently required from: laforge.
3 comments:
File include/osmocom/core/soft_uart.h:
Patch Set #3, Line 38: OSMO_SUART_F_BREAK = (1 << 2),
So far there was no need to do anything else with those flags other than setting/unsetting and checking them. In the original Harald's code it was actually as you suggested (0, 1, 2), but the code was using them incorrectly, as if they were the actual flags (i.e. without doing 1 << N). So I fixed the problem this way.
Anyway, just saying, if FOO_FIVE == 0x10, it's not so trivial to calculate that back to a 5.)
In the worst case one can use the libc's `ffs()` function.
But well, even you cannot remember the actual use case for doing this math :P
Patch Set #3, Line 52: stop bots
a stop bot, is that a traffic light? =)
Haha! Nice one :D Fixed in this patch:
https://gerrit.osmocom.org/c/libosmocore/+/35122
File src/core/soft_uart.c:
Patch Set #3, Line 4: * (C) 2022 by Harald Welte <laforge@gnumonks.org>
2022-2023? […]
This patch is mostly Harald's original code from 2022 (https://cgit.osmocom.org/libosmocore/commit/?h=laforge/libosmoisdn&id=c776de6a83b78b39c183467acc768f8663721605) with a small number of cosmetic edits from my side, plus the `OSMO_SUART_F_` fix that I squashed into this patch. The code is further improved and completed in subsequent patches (one of them adding Sysmocom to this header).
To view, visit change 30763. To unsubscribe, or for help writing mail filters, visit settings.