Skip to content

Commit

Permalink
Merge pull request #619 from NVIDIA/fix-mig-get-minor-number
Browse files Browse the repository at this point in the history
[bugfix] Process error type instead of nvml.Return
  • Loading branch information
cdesiniotis authored Jul 22, 2024
2 parents c5c124b + d8ccd50 commit 87a63a6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions internal/platform-support/dgpu/nvml.go
Original file line number Diff line number Diff line change
Expand Up @@ -145,9 +145,9 @@ type toRequiredMigInfo struct {
}

func (d *toRequiredMigInfo) getPlacementInfo() (int, int, int, error) {
gpu, ret := d.parent.GetMinorNumber()
if ret != nvml.SUCCESS {
return 0, 0, 0, fmt.Errorf("error getting GPU minor: %v", ret)
gpu, err := d.parent.GetMinorNumber()
if err != nil {
return 0, 0, 0, fmt.Errorf("error getting GPU minor: %w", err)
}

gi, ret := d.GetGpuInstanceId()
Expand Down

0 comments on commit 87a63a6

Please sign in to comment.