Skip to content

Commit

Permalink
Fix argument order
Browse files Browse the repository at this point in the history
  • Loading branch information
gjulianm committed Oct 30, 2024
1 parent 18c6760 commit b39574d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/gpu/cuda/env.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ const cudaVisibleDevicesEnvVar = "CUDA_VISIBLE_DEVICES"
// applications." If an invalid index is found, an error is returned together
// with the list of valid devices found up until that point.
func GetVisibleDevicesForProcess(systemDevices []nvml.Device, pid int, procfs string) ([]nvml.Device, error) {
cudaVisibleDevices, err := kernel.GetProcessEnvVariable(pid, cudaVisibleDevicesEnvVar, procfs)
cudaVisibleDevices, err := kernel.GetProcessEnvVariable(pid, procfs, cudaVisibleDevicesEnvVar)
if err != nil {
return nil, fmt.Errorf("cannot get env var %s for process %d: %w", cudaVisibleDevicesEnvVar, pid, err)
}
Expand Down

0 comments on commit b39574d

Please sign in to comment.