Skip to content

Add support for vfio / sriov

yp-isi requested to merge 83-add-support-for-vfio-sriov into main

Materializations

Populate etcd with sriov keys: /net/<host>/vfs/pfs/<hostNicName> -keys are installed during harbor materialization and store the number of VFs enabled on each pf, as well as mac addresses for each vf. /net/<host>/vfs/mat/<fqvm>.<vfname>.<frontendname> keys store store sriov data used for materializations: pf, vf, vlan, mac, etc.

Configuration

Updates linux boot cmdline to include Sled boot parameters needed to enable IOMMU and such needed for SRIOV.

Canopy

Canopy is made aware of the new sriov-keys. Trunk key handling is updated to disable VFs on trunked interfaces that are used in place of Vlan-subinterfaces for virtio. Not disabling VFs causes problems with broadcasts/arp and leads to high loss rates. So virtio and vfio cannot co-exist on the same PF and we must disable VFs (set their number to 0) when using virtio, or enable them back (set their number to a pre-configured value) when using vfio.

Mariner

Updates for setting up VMs using vfio. Mariner is responsible for making sure VFs are enabled before passing them to VMs. This results is split functionality that is not ideal: VFs are enabled in Mariner for vfio, but disabled in Canopy for virtio. The problem here is that currently Mariner does not know about trunked devices or vlan sub-interface devices that are used by a Tap device. This can be fixed by adding a reference to a PF to state.Tap.

Mrs cli

Added commands to list keys and show their values.

Alt-names

Rebased to the alt-names patch for vlan sub-interfaces !121 (closed)

Related to #83

Edited by yp-isi

Merge request reports

Loading