devices

package
v0.0.0-...-2393a11 Latest Latest
Warning

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

Go to latest
Published: Jan 13, 2021 License: MIT Imports: 16 Imported by: 0

Documentation

Rendered for windows/amd64

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddDevice

func AddDevice(ctx context.Context, vm *uvm.UtilityVM, idType, deviceID, deviceUtilPath string) (vpci *uvm.VPCIDevice, locationPaths []string, err error)

AddDevice is the api exposed to hcsoci to handle assigning a device on a UVM

`idType` refers to the specified device's type, supported types here are `VPCIDeviceIDType` and `VPCIDeviceIDTypeLegacy`.

`deviceID` refers to the specified device's identifier. This must refer to a device instance id for hyper-v isolated device assignment.

`deviceUtilPath` refers to the path in the UVM of the device-util tool used for finding the given device's location path(s).

Returns the allocated vpci device in `vpci` to be tracked for release by the caller. On failure in this function, `vpci` is released and nil is returned for that value.

Returns a slice of strings representing the resulting location path(s) for the specified device.

func InstallWindowsDriver

func InstallWindowsDriver(ctx context.Context, vm *uvm.UtilityVM, driver string) (closer resources.ResourceCloser, err error)

InstallWindowsDriver mounts a specified kernel driver using vsmb, then installs it in the UVM.

`driver` is a directory path on the host that contains driver files for standard installation.

Returns a ResourceCloser for the added vsmb share. On failure, the vsmb share will be released, the returned ResourceCloser will be nil, and an error will be returned.

Types

This section is empty.

Jump to

Keyboard shortcuts

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