nvpassthrough

package
v0.11.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 11, 2026 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Interface

type Interface interface {
	FindBestVFIOVariant(string) (string, error)
	BindToVFIODriver(string) error
	BindToDriver(string, string) error
	Unbind(string) error
}

func New

func New(opts ...Option) Interface

type Option

type Option func(*nvpassthrough)

Option defines a function for passing options to the New() call.

func WithHostRoot

func WithHostRoot(hostRoot string) Option

WithHostRoot provides an Option to set the path to the host root filesystem. The path is only used when the WithLoadKernelModules option is also enabled. The path is assumed to be a chroot-able filesystem.

func WithLoadKernelModules

func WithLoadKernelModules(loadKernelModules bool) Option

WithLoadKernelModules provides an Option for opting-in to loading kernel modules before binding NVIDIA PCI devices to them. By default, this behavior is disabled.

func WithLogger

func WithLogger(logger basicLogger) Option

WithLogger provides an Option to set the logger for the library.

func WithNvpciLib

func WithNvpciLib(lib nvpci.Interface) Option

WithNvpciLib provides an Option to set the nvpci lib used.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL