freebsd-skq/share
neel d070810920 Add support for PCI-to-ISA LPC bridge emulation. If the LPC bus is attached
to a virtual machine then we implicitly create COM1 and COM2 ISA devices.

Prior to this change the only way of attaching a COM port to the virtual
machine was by presenting it as a PCI device that is mapped at the legacy
I/O address 0x3F8 or 0x2F8.

There were some issues with the original approach:
- It did not work at all with UEFI because UEFI will reprogram the PCI device
  BARs and remap the COM1/COM2 ports at non-legacy addresses.
- OpenBSD GENERIC kernel does not create a /dev/console because it expects
  the uart device at the legacy 0x3F8/0x2F8 address to be an ISA device.
- It was functional with a FreeBSD guest but caused the console to appear
  on /dev/ttyu2 which was not intuitive.

The uart emulation is now independent of the bus on which it resides. Thus it
is possible to have uart devices on the PCI bus in addition to the legacy
COM1/COM2 devices behind the LPC bus.

The command line option to attach ISA COM1/COM2 ports to a virtual machine is
"-s <bus>,lpc -l com1,stdio".

The command line option to create a PCI-attached uart device is:
"-s <bus>,uart[,stdio]"

The command line option to create PCI-attached COM1/COM2 device is:
"-S <bus>,uart[,stdio]". This style of creating COM ports is deprecated.

Discussed with:	grehan
Reviewed by:	grehan
Submitted by:	Tycho Nightingale (tycho.nightingale@pluribusnetworks.com)

M    share/examples/bhyve/vmrun.sh
AM   usr.sbin/bhyve/legacy_irq.c
AM   usr.sbin/bhyve/legacy_irq.h
M    usr.sbin/bhyve/Makefile
AM   usr.sbin/bhyve/uart_emul.c
M    usr.sbin/bhyve/bhyverun.c
AM   usr.sbin/bhyve/uart_emul.h
M    usr.sbin/bhyve/pci_uart.c
M    usr.sbin/bhyve/pci_emul.c
M    usr.sbin/bhyve/inout.c
M    usr.sbin/bhyve/pci_emul.h
M    usr.sbin/bhyve/inout.h
AM   usr.sbin/bhyve/pci_lpc.c
AM   usr.sbin/bhyve/pci_lpc.h
2013-10-29 00:18:11 +00:00
..
colldef
dict Disconnect non-MPSAFE NTFS from the build in preparation for dropping 2012-10-17 11:30:00 +00:00
doc Revert r256095, r256120 (partial), r256121: 2013-10-09 17:07:20 +00:00
dtrace Remove copy/pasteo in the copyright notice. 2012-07-21 07:14:52 +00:00
examples Add support for PCI-to-ISA LPC bridge emulation. If the LPC bus is attached 2013-10-29 00:18:11 +00:00
i18n share/i18n: Fix installworld with read-only obj. 2013-09-17 20:09:25 +00:00
info Install the template info directory with mode 644 instead of 444 to 2013-01-21 22:54:43 +00:00
man New sentence -> new line and some mdoc cleanup. 2013-10-28 22:54:28 +00:00
me
misc Fix NetBSD release number 2013-10-11 18:51:37 +00:00
mk Switch the default mtree to nmtree our new NetBSD derived mtree. 2013-10-25 22:45:18 +00:00
mklocale
monetdef Do not overwrite the new UTF-8 files with the old ISO one 2013-07-17 14:00:51 +00:00
msgdef Don't link two different things to the same paths. As tiebreaker I've 2013-01-24 17:00:11 +00:00
numericdef Don't link two different things to the same paths. As tiebreaker I've 2013-01-24 17:00:11 +00:00
security
sendmail
skel Remove hack to emulate effective uid and just use the EUID's name in the 2012-12-05 13:56:39 +00:00
snmp
syscons Fix the formatting for the danish keymap. 2013-10-12 07:00:51 +00:00
tabset
termcap Some software, notably dialog(1), can understand back-tab, which is 2012-11-15 15:05:54 +00:00
timedef
zoneinfo Use find -exec to install zoneinfo instead of requiring xargs to be an 2013-01-11 18:37:51 +00:00
Makefile Remove most of the ATF tools and the _atf user. 2013-10-12 06:06:53 +00:00
Makefile.inc