Skip to main content

ubi_ebunmap

Function ubi_ebunmap 

pub fn ubi_ebunmap<Fd: AsFd>(fd: Fd, lnum: i32) -> Result<(), Errno>
Expand description

UBI_IOCEBUNMAP: unmaps logical eraseblock lnum of the volume of the file, /dev/ubi<n>_<m>.

The physical eraseblock is erased later. After a power cut before that, the logical eraseblock can be mapped to it again. Added in Linux 2.6.29.

ยงErrors

Returns the error of the ioctl. A static volume or a read-only file returns EROFS, and a volume that is being updated returns EBADF.