diff options
author | jhb <jhb@FreeBSD.org> | 2014-01-23 20:21:39 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2014-01-23 20:21:39 +0000 |
commit | e1016866c7ece00b60ccc7f0807fb1c2ebd0f3b8 (patch) | |
tree | b240f9bae5e8b73b14e936389325d99b836c8748 /usr.sbin/bhyve/pci_lpc.c | |
parent | 49a10991a21d43b461cc6ca3357c283fd6f3dd45 (diff) | |
download | FreeBSD-src-e1016866c7ece00b60ccc7f0807fb1c2ebd0f3b8.zip FreeBSD-src-e1016866c7ece00b60ccc7f0807fb1c2ebd0f3b8.tar.gz |
MFC 257422,257661,258075,258476,258494,258579,258609,258699:
Several enhancements to the I/O APIC support in bhyve including:
- Move the I/O APIC device model from userspace into vmm.ko and add
ioctls to assert and deassert I/O APIC pins.
- Add HPET device emulation including a single timer block with 8 timers.
- Remove the 'vdev' abstraction.
Approved by: neel
Diffstat (limited to 'usr.sbin/bhyve/pci_lpc.c')
-rw-r--r-- | usr.sbin/bhyve/pci_lpc.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/usr.sbin/bhyve/pci_lpc.c b/usr.sbin/bhyve/pci_lpc.c index 9fd5f5c..4157c5c 100644 --- a/usr.sbin/bhyve/pci_lpc.c +++ b/usr.sbin/bhyve/pci_lpc.c @@ -31,13 +31,16 @@ __FBSDID("$FreeBSD$"); #include <sys/types.h> +#include <machine/vmm.h> +#include <machine/vmm_dev.h> #include <stdio.h> #include <stdlib.h> #include <string.h> +#include <vmmapi.h> + #include "inout.h" -#include "ioapic.h" #include "pci_emul.h" #include "uart_emul.h" @@ -91,17 +94,16 @@ lpc_uart_intr_assert(void *arg) assert(sc->irq >= 0); - ioapic_assert_pin(lpc_bridge->pi_vmctx, sc->irq); + vm_ioapic_pulse_irq(lpc_bridge->pi_vmctx, sc->irq); } static void lpc_uart_intr_deassert(void *arg) { - struct lpc_uart_softc *sc = arg; - - assert(sc->irq >= 0); - - ioapic_deassert_pin(lpc_bridge->pi_vmctx, sc->irq); + /* + * The COM devices on the LPC bus generate edge triggered interrupts, + * so nothing more to do here. + */ } static int |