AETHER-724 Add support of running UPF from SRIOV enabled VM
Change-Id: I4d9f337d1a91dedb35934246ba8703553a130820
diff --git a/omec/omec-upf-cni/Chart.yaml b/omec/omec-upf-cni/Chart.yaml
index ae32d3b..9ad20b7 100644
--- a/omec/omec-upf-cni/Chart.yaml
+++ b/omec/omec-upf-cni/Chart.yaml
@@ -9,4 +9,4 @@
name: omec-upf-cni
icon: https://guide.opencord.org/logos/cord.svg
-version: 0.1.1
+version: 0.1.2
diff --git a/omec/omec-upf-cni/templates/configmap-sriov-conf.yaml b/omec/omec-upf-cni/templates/configmap-sriov-conf.yaml
index e3e9bbd..72b9bd6 100644
--- a/omec/omec-upf-cni/templates/configmap-sriov-conf.yaml
+++ b/omec/omec-upf-cni/templates/configmap-sriov-conf.yaml
@@ -18,15 +18,23 @@
{
"resourceName": "sriov_vfio_access_net",
"selectors": {
+{{- if hasKey .Values.config.sriov.resourceList.vfio "accessPciAddresses" }}
+ "pciAddresses": {{ toJson .Values.config.sriov.resourceList.vfio.accessPciAddresses }}
+{{- else if hasKey .Values.config.sriov.resourceList.vfio "accessPfNames" }}
"pfNames": {{ toJson .Values.config.sriov.resourceList.vfio.accessPfNames }},
"drivers": ["vfio-pci"]
+{{- end }}
}
},
{
"resourceName": "sriov_vfio_core_net",
"selectors": {
+{{- if hasKey .Values.config.sriov.resourceList.vfio "corePciAddresses" }}
+ "pciAddresses": {{ toJson .Values.config.sriov.resourceList.vfio.corePciAddresses }}
+{{- else if hasKey .Values.config.sriov.resourceList.vfio "corePfNames" }}
"pfNames": {{ toJson .Values.config.sriov.resourceList.vfio.corePfNames }},
"drivers": ["vfio-pci"]
+{{- end }}
}
}
{{- if hasKey .Values.config.sriov.resourceList "netDevice" }}
diff --git a/omec/omec-upf-cni/values.yaml b/omec/omec-upf-cni/values.yaml
index 2008555..e67a53e 100644
--- a/omec/omec-upf-cni/values.yaml
+++ b/omec/omec-upf-cni/values.yaml
@@ -19,8 +19,8 @@
# If your cluster has multiple nodes with different interface names,
# simply provide the whole list
resourceList:
- # Provide PF name with VF range for S1U and SGI interfaces.
- # Note that VF range of S1U must be smaller than SGI's.
+ # Provide PF name with VF range or PCI address for access and core interfaces.
+ # PCI address has higher precedence when both provided.
vfio:
accessPfNames:
- eno1#0-3
@@ -29,10 +29,9 @@
# Provide PF name with its VFs bounded to PF's driver
# The driver name must be specified to prevent one interface is
# registered to both vfio and netdevice resource pools
- # NOTE: netDevice is required to use CDN service
- netDevice:
- pfNames:
- - eno1
- drivers:
- - i40evf
- - ixgbevf
+ #netDevice:
+ # pfNames:
+ # - eno1
+ # drivers:
+ # - i40evf
+ # - ixgbevf