diff options
author | grehan <grehan@FreeBSD.org> | 2014-03-07 06:23:37 +0000 |
---|---|---|
committer | grehan <grehan@FreeBSD.org> | 2014-03-07 06:23:37 +0000 |
commit | 873043aeab23d61813d4b405225a2737fadd3cfd (patch) | |
tree | 4af52d7d4bcf7f3bb6de2b212c48cb049f2b1694 /usr.sbin | |
parent | 3c2665ae5efd918534e936cb3f36bfc693f34fdb (diff) | |
download | FreeBSD-src-873043aeab23d61813d4b405225a2737fadd3cfd.zip FreeBSD-src-873043aeab23d61813d4b405225a2737fadd3cfd.tar.gz |
Open the uart emulation's backing tty in non-blocking mode.
This fixes the issue of bhyve appearing to halt when using
nmdm ports for the console, until a connection is made to
the other end.
bhyveload already does this.
Reported by: Many.
MFC after: 3 weeks.
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/bhyve/uart_emul.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/bhyve/uart_emul.c b/usr.sbin/bhyve/uart_emul.c index 2fbbd15..dd1c220 100644 --- a/usr.sbin/bhyve/uart_emul.c +++ b/usr.sbin/bhyve/uart_emul.c @@ -585,7 +585,7 @@ uart_tty_backend(struct uart_softc *sc, const char *opts) retval = -1; - fd = open(opts, O_RDWR); + fd = open(opts, O_RDWR | O_NONBLOCK); if (fd > 0 && isatty(fd)) { sc->tty.fd = fd; sc->tty.opened = true; |