From 2923759d8c77418582fa5980acb2d5d8ce03a60f Mon Sep 17 00:00:00 2001 From: jsg Date: Mon, 10 Apr 2023 12:11:22 +0000 Subject: [PATCH] fix setting parity bits ok mglocker@ --- sys/dev/usb/umcs.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/dev/usb/umcs.c b/sys/dev/usb/umcs.c index 163625257cd..1929f9e50ed 100644 --- a/sys/dev/usb/umcs.c +++ b/sys/dev/usb/umcs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: umcs.c,v 1.10 2022/04/09 20:07:44 naddy Exp $ */ +/* $OpenBSD: umcs.c,v 1.11 2023/04/10 12:11:22 jsg Exp $ */ /* $NetBSD: umcs.c,v 1.8 2014/08/23 21:37:56 martin Exp $ */ /* $FreeBSD: head/sys/dev/usb/serial/umcs.c 260559 2014-01-12 11:44:28Z hselasky $ */ @@ -542,9 +542,9 @@ umcs_param(void *self, int portno, struct termios *t) if (t->c_cflag & PARENB) { lcr |= UMCS_LCR_PARITYON; if (t->c_cflag & PARODD) { - lcr = UMCS_LCR_PARITYODD; + lcr |= UMCS_LCR_PARITYODD; } else { - lcr = UMCS_LCR_PARITYEVEN; + lcr |= UMCS_LCR_PARITYEVEN; } } else { lcr &= ~UMCS_LCR_PARITYON; -- 2.20.1