pub enum Error {
InvalidMagicNumber,
SizeMismatch,
SliceReadError(SliceReadError),
ParseError(usize),
Utf8Error,
VersionNotSupported,
VecWriteError(VecWriteError),
PropError(PropError),
}
Expand description
An error describe parsing problems when creating device trees.
Variants§
InvalidMagicNumber
The magic number MAGIC_NUMBER
was not found at the start of the
structure.
SizeMismatch
An offset or size found inside the device tree is outside of what was
supplied to load()
.
SliceReadError(SliceReadError)
Failed to read data from slice.
ParseError(usize)
The data format was not as expected at the given position
Utf8Error
While trying to convert a string that was supposed to be ASCII, invalid utf8 sequences were encounted
VersionNotSupported
The device tree version is not supported by this library.
VecWriteError(VecWriteError)
The device tree structure could not be serialized to DTB
PropError(PropError)
Property could not be parsed
Trait Implementations§
Source§impl From<SliceReadError> for Error
impl From<SliceReadError> for Error
Source§fn from(e: SliceReadError) -> Error
fn from(e: SliceReadError) -> Error
Converts to this type from the input type.
Source§impl From<VecWriteError> for Error
impl From<VecWriteError> for Error
Source§fn from(e: VecWriteError) -> Error
fn from(e: VecWriteError) -> Error
Converts to this type from the input type.
impl Copy for Error
impl Eq for Error
impl StructuralPartialEq for Error
Auto Trait Implementations§
impl Freeze for Error
impl RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnwindSafe for Error
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more