blkpg

package
v0.1.1-0...-42241d0 Latest Latest
Warning

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

Go to latest
Published: Jan 22, 2021 License: MPL-2.0 Imports: 12 Imported by: 0

Documentation

Overview

Package blkpg provices functions for working the the BLKPG family of iotctls.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InformKernelOfAdd

func InformKernelOfAdd(f *os.File, first, length uint64, n int32) error

InformKernelOfAdd invokes the BLKPG_ADD_PARTITION ioctl.

func InformKernelOfDelete

func InformKernelOfDelete(f *os.File, first, length uint64, n int32) error

InformKernelOfDelete invokes the BLKPG_DEL_PARTITION ioctl.

func InformKernelOfResize

func InformKernelOfResize(f *os.File, first, length uint64, n int32) error

InformKernelOfResize invokes the BLKPG_RESIZE_PARTITION ioctl.

Types

type KernelPartition

type KernelPartition struct {
	No     int
	Start  int64
	Length int64
}

KernelPartition represents kernel partition info.

func GetKernelPartitions

func GetKernelPartitions(f *os.File) ([]KernelPartition, error)

GetKernelPartitions returns kernel partition table state.

Jump to

Keyboard shortcuts

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