We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ef57c07 commit 8fc4b9cCopy full SHA for 8fc4b9c
pkg/nvcdi/options.go
@@ -18,6 +18,7 @@ package nvcdi
18
19
import (
20
"github.com/NVIDIA/go-nvlib/pkg/nvlib/device"
21
+ "github.com/NVIDIA/go-nvlib/pkg/nvlib/info"
22
"github.com/NVIDIA/go-nvml/pkg/nvml"
23
24
"github.com/NVIDIA/nvidia-container-toolkit/internal/logger"
@@ -34,6 +35,13 @@ func WithDeviceLib(devicelib device.Interface) Option {
34
35
}
36
37
38
+// WithInfoLib sets the info library for CDI spec generation.
39
+func WithInfoLib(infolib info.Interface) Option {
40
+ return func(l *nvcdilib) {
41
+ l.infolib = infolib
42
+ }
43
+}
44
+
45
// WithDeviceNamers sets the device namer for the library
46
func WithDeviceNamers(namers ...DeviceNamer) Option {
47
return func(l *nvcdilib) {
0 commit comments