diff options
author | Sylvain Munaut <tnt@246tNt.com> | 2010-04-21 19:27:21 +0200 |
---|---|---|
committer | Sylvain Munaut <tnt@246tNt.com> | 2010-04-21 19:27:21 +0200 |
commit | 80ad05830d41fd387b681788a15ddb942947d898 (patch) | |
tree | 8e6898b84789914cd96541c191db085fdc3b78fc /src/host/osmocon/osmocon.c | |
parent | 9b7dbede26d58e80ec920e2d550e2d862a8d706d (diff) |
osmocom: Fix serial init (CSIZE field)
Since we clear the whole CSIZE, we need to set CS8 _after_ the clearing
or it'll just get erased ...
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
Diffstat (limited to 'src/host/osmocon/osmocon.c')
-rw-r--r-- | src/host/osmocon/osmocon.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/host/osmocon/osmocon.c b/src/host/osmocon/osmocon.c index 850e928c..b823b5b8 100644 --- a/src/host/osmocon/osmocon.c +++ b/src/host/osmocon/osmocon.c @@ -202,8 +202,8 @@ static int serial_init(const char *serial_port) } cfsetispeed(&tio, MODEM_BAUDRATE); cfsetospeed(&tio, MODEM_BAUDRATE); - tio.c_cflag |= (CREAD | CLOCAL | CS8); tio.c_cflag &= ~(PARENB | CSTOPB | CSIZE | CRTSCTS); + tio.c_cflag |= (CREAD | CLOCAL | CS8); tio.c_lflag &= ~(ICANON | ECHO | ECHOE | ISIG); tio.c_iflag |= (INPCK | ISTRIP); tio.c_iflag &= ~(ISTRIP | IXON | IXOFF | IGNBRK | INLCR | ICRNL | IGNCR); |