Skip to content

Commit

Permalink
Merge pull request #240 from e0ne/bf2-configuration
Browse files Browse the repository at this point in the history
Fix BlueField2 SR-IOV configuration
  • Loading branch information
adrianchiris authored Feb 20, 2022
2 parents c1f0ddc + be1f285 commit 15db360
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pkg/utils/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -173,14 +173,14 @@ func SyncNodeState(newState *sriovnetworkv1.SriovNetworkNodeState) error {
return nil
}

// skip config VF for switchdev mode or BF-2 NICs
// SkipConfigVf Use systemd service to configure switchdev mode or BF-2 NICs in OpenShift
func SkipConfigVf(ifSpec sriovnetworkv1.Interface, ifStatus sriovnetworkv1.InterfaceExt) bool {
if ifSpec.EswitchMode == sriovnetworkv1.ESWITCHMODE_SWITCHDEV {
glog.V(2).Infof("SkipConfigVf(): skip config VF for switchdev device")
return true
}
// Nvidia_mlx5_MT42822_BlueField-2_integrated_ConnectX-6_Dx
if ifStatus.Vendor == VendorMellanox && ifStatus.DeviceID == DeviceBF2 {
// Nvidia_mlx5_MT42822_BlueField-2_integrated_ConnectX-6_Dx in OpenShift
if ClusterType == ClusterTypeOpenshift && ifStatus.Vendor == VendorMellanox && ifStatus.DeviceID == DeviceBF2 {
glog.V(2).Infof("SkipConfigVf(): skip config VF for BF2 device")
return true
}
Expand Down

0 comments on commit 15db360

Please sign in to comment.