Documentation ¶
Index ¶
Constants ¶
View Source
const ( FlagsReadOnly = 1 FlagsAutoClear = 4 FlagsPartScan = 8 FlagsDirectIO = 16 )
Loop device flags values
View Source
const ( CryptNone = 0 CryptXor = 1 CryptDes = 2 CryptFish2 = 3 CryptBlow = 4 CryptCast128 = 5 CryptIdea = 6 CryptDummy = 9 CryptSkipJack = 10 CryptCryptoAPI = 18 CryptMax = 20 )
Loop device encryption types
View Source
const ( CmdSetFd = 0x4C00 CmdClrFd = 0x4C01 CmdSetStatus = 0x4C02 CmdGetStatus = 0x4C03 CmdSetStatus64 = 0x4C04 CmdGetStatus64 = 0x4C05 CmdChangeFd = 0x4C06 CmdSetCapacity = 0x4C07 CmdSetDirectIO = 0x4C08 )
Loop device IOCTL commands
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Device ¶
type Device struct { MaxLoopDevices int // contains filtered or unexported fields }
Device describes a loop device
func (*Device) AttachFromFile ¶
AttachFromFile finds a free loop device, opens it, and stores file descriptor provided by image file pointer
func (*Device) AttachFromPath ¶
AttachFromPath finds a free loop device, opens it, and stores file descriptor of opened image path
Click to show internal directories.
Click to hide internal directories.