-
Notifications
You must be signed in to change notification settings - Fork 292
Qemu stable rebase from master 20180323 #3531
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
mseri
merged 119 commits into
xapi-project:qemu-stable
from
mg12:qemu-stable-rebase-20180323
Mar 23, 2018
Merged
Qemu stable rebase from master 20180323 #3531
mseri
merged 119 commits into
xapi-project:qemu-stable
from
mg12:qemu-stable-rebase-20180323
Mar 23, 2018
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Add net SR-IOV object 2. Add a. PIF.sriov_physical_PIF_of b. PIF.sriov_logical_PIF_of c. TODO: add PIF.pci d. TODO: add PCI.driver_name 3. Add net sriov cli interface for create/destroy 4. Add faked SRIOV module in api-server and xapi_net_sriov signature simultaneously Signed-off-by: Min Li <min.li1@citrix.com> Signed-off-by: Yang Qian <yang.qian@citrix.com>
Signed-off-by: Cheng Zhang <cheng.zhang@citrix.com>
Signed-off-by: Cheng Zhang <cheng.zhang@citrix.com>
1. Set PIF.PCI of physical PIF to corresponding pci ref when creating 2. Set PIF.PCI of Vlan master, Bond master and tunnel PIF to Ref.null 3. Refresh PIF.PCI on xapi restarting for all kinds of PIFs 4. Call Network.Interface.get_pci_bus_path to get the pci bus path of device underneath the PIF Signed-off-by: Yang Qian <yang.qian@citrix.com>
Signed-off-by: Min Li <min.li1@citrix.com>
Signed-off-by: Min Li <min.li1@citrix.com>
This temporary fix will be overwritten when merging Ming's change Signed-off-by: Yang Qian <yang.qian@citrix.com>
1. Add Xapi_pif_helpers.ml contains: + Add get_pif_type to get PIF type + Add X_is_allowed_on_pif serial functions to exectue check before creating VLAN, bond and tunnel + Add get_pif_topo to get the types of the PIFs underneath the given PIF 2. Apply Xapi_pif_helpers.get_pif_type in nm.ml 3. Refine VLAN UT Signed-off-by: Yang Qian <yang.qian@citrix.com>
…699-pif CP-25699 Refine PIF type check related stuff
1. remove redundant Api_errors 2. fix typo error 3. slightly refine xapi_vlan.ml Signed-off-by: Yang Qian <yang.qian@citrix.com>
1. implement Network sriov create/destroy 2. consider vlan on network sriov scenario when: + plug vlan pif on top of network sriov + unplug network sriov pif underneath vlan pif 3. check SRIOV compatibility before adding it to network Signed-off-by: Yang Qian <yang.qian@citrix.com>
1. call networkd to enable/disable sriov in bring_pif_up/bring_pif_down 2. when disabling sriov, only call networkd when all of PIFs that use same driver in the host has disabled sriov Signed-off-by: Yang Qian <yang.qian@citrix.com>
Signed-off-by: Yang Qian <yang.qian@citrix.com>
Add a new function to get backend of vif. In this new function, network SR-IOV is supported. Update the metadata of vif to support network SR-IOV VF backed vif. Signed-off-by: Ming Lu <ming.lu@citrix.com>
Add PCIs of network SR-IOV VFs into PCI metadata between Xapi and Xenopsd. Signed-off-by: Ming Lu <ming.lu@citrix.com>
Reduce duplicate DB access. Signed-off-by: Ming Lu <ming.lu@citrix.com>
CP-25699 Network sriov create/destroy
…25795 CP-25795: Add new VIF backend for network SR-IOV
Signed-off-by: Yang Qian <yang.qian@citrix.com>
The 'forget' operation is blocked on following 2 kinds of PIFs: 1. SR-IOV logical PIF -> `Api_errors.cannot_forget_sriov_logical` 2. SR-IOV physical PIF -> `Api_errors.pif_sriov_still_exists` Signed-off-by: Ming Lu <ming.lu@citrix.com>
When fixing CA-25160 of allowed one to put a VLAN on another VLAN, we added a FIST to control the restriction and disallow it by default. As VLAN on VLAN is a meanless use case, so remove the support. Signed-off-by: Yang Qian <yang.qian@citrix.com>
1. Update virtual/physical function relations when updating pci devices 2. call update_pci after bring up/down sriov logical pifs 3. refine gpu code of updating pgpu records, eliminate the annoying side effect Signed-off-by: Yang Qian <yang.qian@citrix.com>
CP-27001 Update pci status after enable/disable sriov
1. move the function to new place 2. refine it Signed-off-by: Yang Qian <yang.qian@citrix.com>
…atible_with_sriov` Signed-off-by: Yang Qian <yang.qian@citrix.com>
1. when creating vlan, check the candidate pif type and the first type of the first existing pif of the network. Only allow the creation if: a. both candidate PIF and existing PIF are sriov logical PIF and share same PCI device type or b. both candidate PIF and existing PIF are not sriov logical PIF 2. when creating bond/tunnel, ensure the network is not sriov or sriov vlan network Signed-off-by: Yang Qian <yang.qian@citrix.com>
Signed-off-by: Yang Qian <yang.qian@citrix.com>
…_network_compatible_with_sriov` Signed-off-by: Yang Qian <yang.qian@citrix.com>
Timebox creates a thread to supervise the execution of a function. If this execution hangs, it does not get to closing the fd_out file descriptor. This commit ensures fd_out is closed. Signed-off-by: Yang Qian <yang.qian@citrix.com>
Eliminate fd leak in timebox
The background logic is that XAPI will try to construct all information on a VM as metadata and push this metadata to Xenopsd to manage the VM. Particularly the logic on vifs are: for the `start` of VM, XAPI will try to push all vifs, no matter attached or not, to Xenopsd; while for the `reboot` of VM, it will try to push the vifs which are currently attached only. SR-IOV VF backed vifs should follow same logic. This means XAPI should not push the VFs' PCIs which are backend of un-attached vifs also. This fix adds a filter on contructing PCI metata to filter out the vifs which are backed by VF PCIs and currently un-attached. Signed-off-by: Ming Lu <ming.lu@citrix.com>
CA-285897: Filter out un-attached VF-backed vifs in PCI metadata
Currently the mentioned error is only raised in one situation where VM is being migrated, so make it more specific and hide some of the details that is not user friendly. Signed-off-by: YarsinCitrix <yarsin.he@citrix.com>
If a VM is not running, then we don't have to worry about being able to live-migrate its vGPUs, so don't bother checking if the vGPU supports it. Note that the `migrate_send` operation is used for `VM.migrate_send`, but also for `VDI.pool_migrate`. Signed-off-by: Rob Hoes <rob.hoes@citrix.com>
CA-284492: Ignore vGPU live-migratability in migrate_send for halted VMs
vGPU migration is now enabled by default - remove all checks. Signed-off-by: Christian Lindig <christian.lindig@citrix.com>
CP-27433 remove checks for vgpu_migration_enabled()
hosts by best SR-IOV. This issue was found when VM has VLAN SR-IOV network,then the PIFs of the network were not SR-IOV logical PIF. To avoid internal erros raised,change the way for getting SR-IOV object from any type of PIFs by using `get_pif_topo`. Signed-off-by: Min Li <min.li1@citrix.com>
…iov-vlan CP-27446: Group hosts failed as no sr-iov found when VM has VLAN SR-IOV network
When synchronising PIF currently_attached, should ignore VLAN PIF on SR-IOV and SR-IOV logical PIF because they don't have real vswitch bridge, so that the bridge existance does not indicate the connection status of the PIF. Signed-off-by: Yang Qian <yang.qian@citrix.com>
CA-286292: VLAN PIF on SR-IOV status is incorrect after restarting toolstack
This fix will add logic to bring up a bond master PIF when bringing up a SR-IOV physical PIF and this PIF is also a bond slave. This is because following PIF structure is required to be supported: (Bond slave) -------------------+ | +- (Bond master) | (Bond slave + SR-IOV physical)--+ | | (SR-IOV logical) Signed-off-by: Ming Lu <ming.lu@citrix.com>
In a pool, restarting the toolstack on a slave will go through two stages: first shutting down, and next booting up again. In the shutting-down stage, Host.enabled will be set as false. Then in the booting-up stage, XAPI will set it back to true in the 'initialising storage' step. The bug to be fixed in this ticket is that the allowed_operations of the slave host is not updated correspondingly when setting Host.enabled back to true while booting up. Signed-off-by: ming <ming.lu@citrix.com>
This fix will add logic to bring down SR-IOV physical PIF if it is also a slave of bond and this bond is being brought down. This is because following PIF structure is required to supported: (Bond slave) -------------------+ | +- (Bond master) | (Bond slave + SR-IOV physical)--+ | | (SR-IOV logical) Meanwhile, this commit also refines the code structure in `unplug` to put exclusive PIF types into a pattern match. Signed-off-by: ming <ming.lu@citrix.com>
…286135 CA-286135: Bring up bond when bring up SR-IOV physical and vice versa
CA-280342: Bad error message when migration fails
…281178 CA-281178: Update allowed operations in consider_enabling_host
Merge feature SR-IOV to master
Signed-off-by: Yang Qian <yang.qian@citrix.com>
Fix typo of `modprobe`
… origin-qemu-stable
@mseri if you don't see anything obviously wrong, would you please merge today asap, together will the corresponding xenopsd merge? Ross would like to have a new build today containing these changes. |
mseri
approved these changes
Mar 23, 2018
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Feels right. Please test it thoroughly
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This change depends on using the latest xcp-idl/master because of the sriov changes and xenopsd at xapi-project/xenopsd#489