Date: Tue, 8 Apr 2014 21:02:04 +0000 (UTC) From: John Baldwin <jhb@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r264277 - head/usr.sbin/bhyve Message-ID: <201404082102.s38L24Kl015339@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jhb Date: Tue Apr 8 21:02:03 2014 New Revision: 264277 URL: http://svnweb.freebsd.org/changeset/base/264277 Log: Handle single-byte reads from the bvmcons port (0x220) by returning 0xff. Some guests may attempt to read from this port to identify psuedo-PNP ISA devices. (The ie(4) driver in FreeBSD/i386 is one example.) Reviewed by: grehan Modified: head/usr.sbin/bhyve/consport.c Modified: head/usr.sbin/bhyve/consport.c ============================================================================== --- head/usr.sbin/bhyve/consport.c Tue Apr 8 20:59:02 2014 (r264276) +++ head/usr.sbin/bhyve/consport.c Tue Apr 8 21:02:03 2014 (r264277) @@ -110,6 +110,15 @@ console_handler(struct vmctx *ctx, int v return (0); } + /* + * Guests might probe this port to look for old ISA devices + * using single-byte reads. Return 0xff for those. + */ + if (bytes == 1 && in) { + *eax = 0xff; + return (0); + } + if (bytes != 4) return (-1);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201404082102.s38L24Kl015339>