Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 25 Jun 2018 08:53:30 +0000 (UTC)
From:      Andriy Gapon <avg@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r335623 - stable/10/sys/dev/usb/serial
Message-ID:  <201806250853.w5P8rU2c046021@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: avg
Date: Mon Jun 25 08:53:30 2018
New Revision: 335623
URL: https://svnweb.freebsd.org/changeset/base/335623

Log:
  MFC r334000: uchcom: reject parity and double stop bits as unsupported

Modified:
  stable/10/sys/dev/usb/serial/uchcom.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/dev/usb/serial/uchcom.c
==============================================================================
--- stable/10/sys/dev/usb/serial/uchcom.c	Mon Jun 25 08:52:48 2018	(r335622)
+++ stable/10/sys/dev/usb/serial/uchcom.c	Mon Jun 25 08:53:30 2018	(r335623)
@@ -686,6 +686,10 @@ uchcom_pre_param(struct ucom_softc *ucom, struct termi
 	default:
 		return (EIO);
 	}
+	if ((t->c_cflag & CSTOPB) != 0)
+		return (EIO);
+	if ((t->c_cflag & PARENB) != 0)
+		return (EIO);
 
 	if (uchcom_calc_divider_settings(&dv, t->c_ospeed)) {
 		return (EIO);



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201806250853.w5P8rU2c046021>