Skip to content
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

Fix BlueField2 SR-IOV configuration #240

Merged
merged 1 commit into from
Feb 20, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 {
Copy link
Collaborator

@zshi-redhat zshi-redhat Feb 17, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We'd also like to support BF in connectx mode in openshift, this check makes the bf2 device in connectx mode to go through the path of systemd service configuration on openshift, which is not ideal since currently systemd service doesn't initialize the VF device as is done by config-daemon runtime configSriovDevice.

Shall we take this opptunitiy to implement the VF initialization in systemd service?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR is proposed as a temporary solution to enable the use-case for vanilla k8s. @e0ne is working of VF initialization in systemd.

for openshift i suspect the need to support BF as connectx will come at a later stage so it gives us some time to move to systemd., Driver changes might be needed as well as a new mstflint version that needs to be pulled to RHEL repo (for when we need to query the DPU mode and change it).

will this be acceptable ?

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

okay, the sysetmd can come later.

glog.V(2).Infof("SkipConfigVf(): skip config VF for BF2 device")
return true
}
Expand Down