opnsense-src/sys/dev/hyperv/vmbus
Mark Johnston 97993d1ebf hyperv: Fix vmbus after the i386 4/4 split
The vmbus ISR needs to live in a trampoline.  Dynamically allocating a
trampoline at driver initialization time poses some difficulties due to
the fact that the KENTER macro assumes that the offset relative to
tramp_idleptd is fixed at static link time.  Another problem is that
native_lapic_ipi_alloc() uses setidt(), which assumes a fixed trampoline
offset.

Rather than fight this, move the Hyper-V ISR to i386/exception.s.  Add a
new HYPERV kernel option to make this optional, and configure it by
default on i386.  This is sufficient to make use of vmbus(4) after the
4/4 split.  Note that vmbus cannot be loaded dynamically and both the
HYPERV option and device must be configured together.  I think this is
not too onerous a requirement, since vmbus(4) was previously
non-functional.

Reported by:	Harry Schmalzbauer <freebsd@omnilan.de>
Tested by:	Harry Schmalzbauer <freebsd@omnilan.de>
Reviewed by:	whu, kib
MFC after:	2 weeks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D30577
2021-06-08 09:40:30 -04:00
..
amd64 x86: remove gcov kernel support 2021-04-02 15:41:51 +03:00
i386 hyperv: Fix vmbus after the i386 4/4 split 2021-06-08 09:40:30 -04:00
hyperv.c Eliminate the arena parameter to kmem_free(). Implicitly this corrects an 2018-08-25 19:38:08 +00:00
hyperv_busdma.c hyperv/busdma: Take BUS_DMA_ZERO into account 2016-05-24 05:26:52 +00:00
hyperv_machdep.h hyperv: Move machine dependent bits into machine dependent files. 2016-06-06 05:55:37 +00:00
hyperv_reg.h hyperv: Allow userland to ro-mmap reference TSC page 2016-12-15 03:32:24 +00:00
hyperv_var.h hyperv/timesync: Support "sent TC" to improve accuracy. 2016-12-08 05:37:39 +00:00
vmbus.c hyperv: register intr handler as usermode-mapped if loaded as module 2021-06-05 18:03:18 +03:00
vmbus_br.c Fix i386 build for r361275 2020-05-20 13:51:27 +00:00
vmbus_brvar.h HyperV socket implementation for FreeBSD 2020-05-20 11:03:59 +00:00
vmbus_chan.c HyperV socket implementation for FreeBSD 2020-05-20 11:03:59 +00:00
vmbus_chanvar.h HyperV socket implementation for FreeBSD 2020-05-20 11:03:59 +00:00
vmbus_et.c hyperv: Update copyright for the files changed in 2017 2017-08-14 06:00:50 +00:00
vmbus_if.m hyperv/vmbus: Add DEVMETHOD to map cpu to event taskq. 2016-11-30 07:45:05 +00:00
vmbus_reg.h HyperV socket implementation for FreeBSD 2020-05-20 11:03:59 +00:00
vmbus_res.c Distinguish _CID match and _HID match and make lower priority probe 2018-10-26 00:05:46 +00:00
vmbus_var.h hyperv/vmbus: Nuke unnecessary critical sections. 2016-12-28 03:07:58 +00:00
vmbus_xact.c hyperv/vmbus: Add result polling support for xact API. 2016-11-28 07:27:08 +00:00