nvmodules

package
v1.16.2 Latest Latest
Warning

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

Go to latest
Published: Sep 24, 2024 License: Apache-2.0 Imports: 5 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 struct {
	// contains filtered or unexported fields
}

Interface provides a set of utilities for interacting with NVIDIA modules on the system.

func New

func New(opts ...Option) *Interface

New constructs a new Interface struct with the specified options.

func (*Interface) Load

func (m *Interface) Load(module string) error

Load loads the specified NVIDIA kernel module. If the root is specified we first chroot into this root.

func (*Interface) LoadAll

func (m *Interface) LoadAll() error

LoadAll loads all the NVIDIA kernel modules.

type Option

type Option func(*Interface)

Option is a function that sets an option on the Interface struct.

func WithDryRun

func WithDryRun(dryRun bool) Option

WithDryRun sets the dry run option for the Interface struct.

func WithLogger

func WithLogger(logger logger.Interface) Option

WithLogger sets the logger for the Interface struct.

func WithRoot

func WithRoot(root string) Option

WithRoot sets the root directory for the NVIDIA device nodes.

Jump to

Keyboard shortcuts

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