Ignore DCD handling on /dev/console entirely.

This makes /dev/console more fail-safe and prevents a potential console
lock-up during boot.

Discussed on:	stable@
Tested by:	koitsu@
MFC after:	1 week
This commit is contained in:
Ed Schouten 2010-09-19 14:21:39 +00:00
parent ddf21c6ae1
commit 4b5d5046ab
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=212860

View File

@ -282,7 +282,8 @@ ttydev_open(struct cdev *dev, int oflags, int devtype, struct thread *td)
/* Wait for Carrier Detect. */
if (!TTY_CALLOUT(tp, dev) && (oflags & O_NONBLOCK) == 0 &&
(tp->t_termios.c_cflag & CLOCAL) == 0) {
(tp->t_termios.c_cflag & CLOCAL) == 0 &&
dev != dev_console) {
while ((ttydevsw_modem(tp, 0, 0) & SER_DCD) == 0) {
error = tty_wait(tp, &tp->t_dcdwait);
if (error != 0)