318393 |
17-May-2017 |
sephe |
MFC 318136
hyperv/vmbus: Reorganize vmbus device tree
For GEN1 Hyper-V, vmbus is attached to pcib0, which contains the resources for PCI passthrough and SR-IOV. There is no acpi_syscontainer0 on GEN1 Hyper-V.
For GEN2 Hyper-V, vmbus is attached to acpi_syscontainer0, which contains the resources for PCI passthrough and SR-IOV. There is no pcib0 on GEN2 Hyper-V.
The ACPI VMBUS device now only holds its _CRS, which is empty as of this commit; its existence is mainly for upward compatibility.
Device tree structure is suggested by jhb@.
Tested-by: dexuan@ Collabrated-wth: dexuan@ Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D10565 |
311254 |
04-Jan-2017 |
sephe |
MFC 310324
hyperv/ic: Rename cleaned up files.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8850 |
311251 |
04-Jan-2017 |
sephe |
MFC 310317
hyperv/ic: Rname cleaned up file.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8848 |
310799 |
30-Dec-2016 |
sephe |
MFC 309346,309348
309346 hyperv/hn: Add HN_DEBUG kernel option.
If bufring is used for per-TX ring descs, don't update "available" counter, which is only used to help debugging.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8674
309348 hyperv/hn: Don't hold txdesc, if no BPFs are attached.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8675 |
310735 |
29-Dec-2016 |
sephe |
MFC 308664,308742,308743
308664 hyperv/vss: Add driver and tools for VSS
VSS stands for "Volume Shadow Copy Service". Unlike virtual machine snapshot, it only takes snapshot for the virtual disks, so both filesystem and applications have to aware of it, and cooperate the whole VSS process.
This driver exposes two device files to the userland:
/dev/hv_fsvss_dev
Normally userland programs should _not_ mess with this device file. It is currently used by the hv_vss_daemon(8), which freezes and thaws the filesystem. NOTE: currently only UFS is supported, if the system mounts _any_ other filesystems, the hv_vss_daemon(8) will veto the VSS process.
If hv_vss_daemon(8) was disabled, then this device file must be opened, and proper ioctls must be issued to keep the VSS working.
/dev/hv_appvss_dev
Userland application can opened this device file to receive the VSS freeze notification, hold the VSS for a while (mainly to flush application data to filesystem), release the VSS process, and receive the VSS thaw notification i.e. applications can run again.
The VSS will still work, even if this device file is not opened. However, only filesystem consistency is promised, if this device file is not opened or is not operated properly.
hv_vss_daemon(8) is started by devd(8) by default. It can be disabled by editting /etc/devd/hyperv.conf.
Submitted by: Hongjiang Zhang <honzhan microsoft com> Reviewed by: kib, mckusick Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8224
308742 hyperv/vss: Nuke unused variables.
Submitted by: markj Reported by: markj Sponsored by: Microsoft
308743 hyperv/vss: Install the userland daemon to /usr/sbin instead of /
Submitted by: markj Reported by: markj Sponsored by: Microsoft |
309313 |
30-Nov-2016 |
dexuan |
MFC: 308723-308725,308793-308795,309127
Approved by: sephe (mentor)
r308723 hyperv/vmbus: add a new method to get vcpu_id
vcpu_id is host's representation of guest CPU. We get the mapping between vcpu_id and FreeBSD kernel's cpu id when VMBus driver is loaded. Later, when a driver, like the coming pcib driver, talks to the host and needs to refer to a guest CPU, the driver must use the vcpu_id.
Reviewed by: jhb, sephe Approved by: sephe (mentor) Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8410
r308724 hyperv/vmbus: add new vmbus methods to support PCIe pass-through
The new methods will be used by the coming pcib driver.
Reviewed by: sephe Approved by: sephe (mentor) Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8409
r308725 hyperv/pcib: enable PCIe pass-through (a.k.a. Discrete Device Assignment)
The feature enables us to pass through physical PCIe devices to FreeBSD VM running on Hyper-V (Windows Server 2016) to get near-native performance with low CPU utilization.
The patch implements a PCI bridge driver to support the feature:
1) The pcib driver talks to the host to discover device(s) and presents the device(s) to FreeBSD's pci driver via PCI configuration space (note: to access the configuration space, we don't use the standard I/O port 0xCF8/CFC method; instead, we use an MMIO-based method supplied by Hyper-V, which is very similar to the 0xCF8/CFC method).
2) The pcib driver allocates resources for the device(s) and initialize the related BARs, when the device driver's attach method is invoked;
3) The pcib driver talks to the host to create MSI/MSI-X interrupt remapping between the guest and the host;
4) The pcib driver supports device hot add/remove.
Reviewed by: sephe Approved by: sephe (mentor) Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8332
r308793 hyperv/pcib: Fix the build for some kernel configs
Add the dependency on pci explicitly for the pcib and vmbus drivers. The related Makefiles are updated accordingly too.
Reviewed by: sephe Approved by: sephe (mentor) Sponsored by: Microsoft
r308794 hyperv/vmbus,pcib: Add MODULE_DEPEND on pci
We'd better add this dependency explicitly, though usually the pci driver is built into the kernel by default.
Reviewed by: sephe Approved by: sephe (mentor) Sponsored by: Microsoft
r308795 hyperv/pcib: change the file name: pcib.c -> vmbus_pcib.c
This makes the file name and the variable naming in the file consistent.
Reviewed by: sephe Approved by: sephe (mentor) Sponsored by: Microsoft
r309127 hyperv/vmbus,pcib: unbreak build in case NEW_PCIB is undefined
vmbus_pcib requires NEW_PCIB, but in case that's not defined, we at least shouldn't break build.
Reviewed by: sephe Approved by: sephe (mentor) Sponsored by: Microsoft |
308511 |
11-Nov-2016 |
sephe |
MFC 308163
hyperv/hn: Rename cleaned up file.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8390 |
308508 |
11-Nov-2016 |
sephe |
MFC 308018,308116
308018 hyeprv/hn: Rename cleaned up RNDIS header file.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8360
308116 hyperv/hn: Rename cleaned up RNDIS source file.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8361 |
308505 |
11-Nov-2016 |
sephe |
MFC 308011,308012
308011 hyperv/hn: Rename cleaned up NVS header file.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8353
308012 hyperv/hn: Rename cleaned up NVS source file.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8354 |
307260 |
14-Oct-2016 |
sephe |
MFC 306484,306485
306484 hyperv/vmbus: Add missing vmbus_if.c to module build.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8067
306485 hyperv/hn: Add stubs for OFFLOAD_CURRENT_CONFIG and NETWORK_CHANGE status
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D8068 |
307254 |
14-Oct-2016 |
sephe |
MFC 306426
hyperv/storvsc: Fix the blkvsc disk attachment issues.
- The original 'disengage' ATA controller model does not work properly for all possible disk configurations. Use the newly added ATA disk veto eventhandler to fit into all possible disk configuration. - If the 'invalid LUN' happens on blkvsc controllers, return CAM_DEV_NOT_THERE so that CAM will not destroy attached disks under the blkvsc controllers.
Submitted by: Hongjiang Zhang <honzhan microsoft com> Discussed with: mav Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7693 |
307164 |
13-Oct-2016 |
sephe |
MFC 303945,303947-303949,303989,303992,303998,304001,304002,304109,304111
303945 hyperv/vmbus: Add macro to get channel packet data length.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7455
303947 hyperv/vmbus: Add APIs for various types of transactions.
Reviewed by: Jun Su <junsu microsoft com> Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7456
303948 hyperv/hn: Switch to vmbus xact APIs for NVS initialization
Reviewed by: Jun Su <junsu microsoft com> Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7457
303949 hyperv/vmbus: Use xact APIs to implement post message Hypercall APIs
Avoid code duplication.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7458
303989 hyperv/hn: Simplify NDIS configuration.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7466
303992 hyperv/hn: Simplify NDIS initialization.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7467
303998 hyperv/hn: Switch to vmbus xact APIs for NVS RXBUF connection.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7469
304001 hyperv/hn: Switch to vmbus xact APIs for NVS chimney buffer connection.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7470
304002 hyperv/hn: Simplify RXBUF disconnection.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7472
304109 hyperv/hn: Simplify chimney sending buffer disconnection.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7479
304111 hyperv/hn: Switch to vmbus xact APIs for sub-channel alloc request.
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7480 |
307114 |
12-Oct-2016 |
sephe |
MFC 303379
hyperv/vmbus: Rename cleaned up bufring code
Sponsored by: Microsoft Differential Revision: https://reviews.freebsd.org/D7318 |
307086 |
12-Oct-2016 |
sephe |
MFC 303023
hyperv/vmbus: Rename laundered vmbus channel code
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7232 |
307030 |
11-Oct-2016 |
sephe |
MFC 302864
hyperv/vmbus: Merge hv_channel_mgmt.c into hv_channel.c
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7126 |
307022 |
11-Oct-2016 |
sephe |
MFC 302698-302704,302706
302698 hyperv/vmbus: Add vmbus method for GUID base device probing.
Reduce the exposure of hv_device.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7024
302699 hyperv/vmbus: All ivars are read-only; nuke unnecessary write_ivar
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7025
302700 hyperv/vmbus: Add channel ivar accessor.
This makes life easier during the transition period to nuke the hv_device.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7026
302701 hyperv/stor: Avoid the hv_device and nuke the broken get_stor_device
This paves way to nuke the hv_device, which is actually an unncessary indirection.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7027
302702 hyperv/util: Avoid the hv_device
This paves way to nuke the hv_device, which is actually an unncessary indirection.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7028
302703 hyperv/vmbus: Deprecate the usage of hv_device.
This paves way to nuke the hv_device, which is actually an unncessary indirection.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7032
302704 hyperv/hn: Avoid the hv_device
This paves way to nuke the hv_device, which is actually an unncessary indirection.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7033
302706 hyperv: Get rid of hv_device, which is unnecessary indirection.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7034 |
307020 |
11-Oct-2016 |
sephe |
MFC 302636-302638,302692
302636 hyperv/vmbus: Move channel map to vmbus_softc
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6982
302637 hyperv/vmbus: Remove needed bits
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7002
302638 hyperv/vmbus: Destroy channel list lock upon attach failure and detach.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7003
302692 hyperv/vmbus: Merge hv_connection.c into hv_channel.c
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D7004 |
307018 |
11-Oct-2016 |
sephe |
MFC 302617-302621,302623,302629-302631
302617 hyperv/vmbus: Flatten channel message response processing.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6914
302618 hyperv/vmbus: Avoid tx_evtflags setting code duplication.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6915
302619 hyperv/vmbus: Busdma-fy Hypercall signal event input parameter.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6916
302620 hyperv: Nuke unused stuffs
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6917
302621 hyperv/vmbus: Don't be oversmart in default cpu selection.
Pin the channel to cpu0 by default. Drivers having special channel-cpu mapping requirement should call vmbus_channel_cpu_{set,rr}() themselves.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6918
302623 hyperv/vmbus: Minor renaming
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6919
302629 hyperv/vmbus: Rework vmbus version accessing.
Instead of global variable, vmbus version is accessed through a vmbus DEVMETHOD now.
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6953
302630 hyperv/vmbus: Move GPADL index into vmbus_softc
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6954
302631 hyperv/vmbus: Move channel list to vmbus_softc
Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6956 |
302170 |
24-Jun-2016 |
sephe |
MFC 301483,301484,301487,301488,301583,301588
301483 hyperv: Move machine dependent bits into machine dependent files.
MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6701
301484 hyperv/vmbus: Define type for channel messages.
And fix message processing; only channel messages are supported.
MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6706
301487 hyperv/vmbus: Factor out channel message processing
This paves the way for further cleanup.
MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6707
301488 hyperv/vmbus: Constify channel message
MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6708
301583 hyperv/vmbus: Busdma-fy MNF and event flags.
MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6744
301588 hyperv/vmbus: Change tx_evtflags type to u_long to match vmbus_evtflags
MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6745 |
302167 |
24-Jun-2016 |
sephe |
MFC 301113
hyperv: Rename some cleaned up/almost cleaned up files
MFC after: 1 week Sponsored by: Microsoft OSTC |
302113 |
23-Jun-2016 |
sephe |
MFC 300478,300479
300478 hyperv: Add helpers for busdma(9) operation
MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6443
300479 hyperv/hn: Use hyperv busdma(9) helper.
MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D6444 |
302041 |
21-Jun-2016 |
sephe |
MFC 297931,298022
297931 Expose doreti as a global symbol on amd64 and i386.
doreti provides the common code path for returning from interrupt andlers on x86. Exposing doreti as a global symbol allows kernel modules to include low-level interrupt handlers instead of requiring all low-level handlers to be statically compiled into the kernel.
Submitted by: Howard Su <howard0su@gmail.com> Reviewed by: kib
298022 hyperv: Deprecate HYPERV option by moving Hyper-V IDT vector into vmbus
Submitted by: Jun Su <junsu microsoft com> Reviewed by: jhb, kib, sephe Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D5910 |
301866 |
13-Jun-2016 |
sephe |
MFC 295919,295958,295964
295919 hyperv/stor: Fix print format
Detected by: PVS Static Analysis MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D5388
295958 hyperv/utils: Code rearrange and cleanup
Split heartbeat, shutdown and timesync out of utils code and name them properly.
Submitted by: Jun Su <junsu microsoft com> Reviewed by: adrian, sephe, Hongjiang Zhang <honzhan microsoft com> MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D5216
295964 hyperv/vmbus: Use free(9) for interrupt page; it is allocated by malloc(9)
MFC after: 1 week Sponsored by: Microsoft OSTC Differential Revision: https://reviews.freebsd.org/D5417 |
295789 |
19-Feb-2016 |
sephe |
MFC [Hyper-V]: r293719-r293722, r293869-r293871, r293873-r293875, r293877
r293719 hyperv/hn: Implement LRO r293720 hyperv/hn: Implement SIOC[SG]IFMEDIA support r293721 hyperv/hn: Avoid mbuf cluster allocation, if the packet is small. r293722 hyperv/hn: Removed unused netvsc_init() r293869 hyperv/hn: Unbreak LINT-NOIP r293870 hyperv: use x86 generic code to do the hypervisor detection r293871 hyperv: remove unused vmbus definitions r293873 hyperv: implement an event timer r293874 hyperv: add interrupt counters r293875 hyperv: set receive buffer size according to NVSP protocol version r293877 Unbreak `make depend` with sys/modules/hyperv/vmbus after r293870
Approved by: re (glebius), adrian (mentor) Sponsored by: Microsoft OSTC |
292796 |
27-Dec-2015 |
ngie |
MFC r284969: r284969 (by lwhsu):
- Fix `make depend` in sys/modules
Differential Revision: https://reviews.freebsd.org/D2951 Approved by: delphij |
272322 |
30-Sep-2014 |
delphij |
MFC r271493,271688-271689,271696,271854,272139-272143:
Import HyperV Key-Value Pair (KVP) driver and daemon code by Microsoft, many thanks for their continued support of FreeBSD.
While I'm there, also implement a new build knob, WITHOUT_HYPERV to disable building and installing of the HyperV utilities when necessary.
The HyperV utilities are only built for i386 and amd64 targets.
Approved by: re (gjb) |
272152 |
26-Sep-2014 |
gjb |
Properly revert r272128.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation |
272151 |
26-Sep-2014 |
gjb |
Revert r272149, which introduces obscure vestiges from the r272128 reversal.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation |
272149 |
26-Sep-2014 |
gjb |
Revert r272128: Though this passes the buildworld test, this fails during installworld with:
make[3]: "/releng/scripts-release/chroots/10/i386/release/etc/devd/Makefile" line 13: Malformed conditional (${MK_HYPERV} != "no")
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation |
272128 |
25-Sep-2014 |
delphij |
MFC r271493,271688,271689,271696,271854:
Import HyperV Key-Value Pair (KVP) driver and daemon code by Microsoft, many thanks for their continued support of FreeBSD.
While I'm there, also implement a new build knob, WITHOUT_HYPERV to disable building and installing of the HyperV utilities when necessary.
The HyperV utilities are only built for i386 and amd64 targets.
Approved by: re (gjb) |
259073 |
07-Dec-2013 |
peter |
Hoist all the mergeinfo up to the root in preparation for enforcing merges to the root only. All MFC's were rerecorded to the root.
Going forward, if an MFC includes mergeinfo, it will need to be made to the root and committed from the root. Merges with --ignore-ancestry or diff | patch can go anywhere.
The mergeinfo in HEAD is in a bad state from years of neglect and manual tampering and this was branched into 10.x. This confuses the coalescing code and prevents it from doing its job.
Approved by: re (gjb, implicit) |
256281 |
10-Oct-2013 |
gjb |
Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.
Approved by: re (implicit) Sponsored by: The FreeBSD Foundation
|
255923 |
28-Sep-2013 |
uqs |
Fix make depend, apply a bit of style.
Approved by: re (marius) Reviewed by: grehan
|
255561 |
14-Sep-2013 |
kib |
Fix module build when device ata is not in kernel config.
Sponsored by: The FreeBSD Foundation Build-tested by: gjb Approved by: re (delphij)
|
255560 |
14-Sep-2013 |
kib |
Correct the svn:keywords value.
Approved by: re (gjb, implicit)
|
255558 |
14-Sep-2013 |
kib |
Add svn:keywords property to Makefile.
Approved by: re (gjb)
|
255524 |
13-Sep-2013 |
grehan |
Import Hyper-V paravirtualized drivers from projects/hyperv branch into head.
Approved by: re@ (hrs) Obtained from: Microsoft, NetApp, and Citrix.
|
255427 |
09-Sep-2013 |
grehan |
Revert the kvp code - there's still some work that needs to be done for that.
Discussed with: Microsoft hyper-v devs
|
255414 |
09-Sep-2013 |
grehan |
Latest update from Microsoft.
Obtained from: Microsoft Hyper-v dev team
|
253411 |
17-Jul-2013 |
grehan |
Microsoft have changed their policy on how the hyper-v code will be pulled into FreeBSD. From now, FreeBSD will be considered the upstream repo.
First step: move the drivers away from the contrib area and into the base system.
A follow-on commit will include the drivers in the amd64 GENERIC kernel.
|
252649 |
03-Jul-2013 |
grehan |
Connect the stordisengage driver to the build.
|
251777 |
15-Jun-2013 |
grehan |
make glue to hook up the hyperv kmods to the build.
Modified from the original Microsoft versions to pull code/headers in from the sys/contrib/dev directory.
|