dev

package
v0.0.0-...-7bf5820 Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2024 License: Apache-2.0, MIT Imports: 11 Imported by: 2

Documentation

Overview

Package dev provides a filesystem implementation for /dev.

Index

Constants

View Source
const Name = "dev"

Name is the dev filesystem name.

Variables

This section is empty.

Functions

func CreateDeviceFile

func CreateDeviceFile(ctx context.Context, vfsObj *vfs.VirtualFilesystem, creds *auth.Credentials, root vfs.VirtualDentry, pathname string, major, minor uint32, mode linux.FileMode, uid, gid *uint32) error

CreateDeviceFile creates a device special file at the given pathname from root.

Types

type FilesystemType

type FilesystemType struct{}

FilesystemType implements vfs.FilesystemType.

+stateify savable

func (FilesystemType) GetFilesystem

func (fst FilesystemType) GetFilesystem(ctx context.Context, vfsObj *vfs.VirtualFilesystem, creds *auth.Credentials, source string, opts vfs.GetFilesystemOptions) (*vfs.Filesystem, *vfs.Dentry, error)

GetFilesystem implements vfs.FilesystemType.GetFilesystem.

func (FilesystemType) Name

func (FilesystemType) Name() string

Name implements vfs.FilesystemType.Name.

func (*FilesystemType) Release

func (fst *FilesystemType) Release(ctx context.Context)

Release implements vfs.FilesystemType.Release.

func (*FilesystemType) StateFields

func (fst *FilesystemType) StateFields() []string

func (*FilesystemType) StateLoad

func (fst *FilesystemType) StateLoad(ctx context.Context, stateSourceObject state.Source)

+checklocksignore

func (*FilesystemType) StateSave

func (fst *FilesystemType) StateSave(stateSinkObject state.Sink)

+checklocksignore

func (*FilesystemType) StateTypeName

func (fst *FilesystemType) StateTypeName() string

type InternalData

type InternalData struct {
	// ShmMode indicates the mode to create the /dev/shm dir with.
	ShmMode *uint16
}

InternalData contains internal data passed in via vfs.GetFilesystemOptions.

Jump to

Keyboard shortcuts

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