pub enum Error {
Show 23 variants
BadMagic,
BadNodeName,
BadPropertyName,
BadStrEncoding(Utf8Error),
BadStructItemType,
BadStructToken,
BadTotalSize,
BadU32List,
BadValueStr,
BadVersion,
BufferTooSmall,
NoMoreStructItems,
NoZeroReservedMemEntry,
OutOfParentNode,
OverlappingReservedMem,
OverlappingStrings,
OverlappingStruct,
UnalignedBlob,
UnalignedReservedMem,
UnalignedStruct,
UnexpectedEndOfBlob,
UnexpectedEndOfStruct,
UnsupportedCompVersion,
}
Expand description
DTB-related error.
Variants
BadMagic
Incorrect DTB magic number.
BadNodeName
Node name is not a zero-terminated string.
BadPropertyName
Property name is not a zero-terminated string.
BadStrEncoding(Utf8Error)
Failed to decode UTF-8 string.
BadStructItemType
Operation doesn’t support a given type of StructItem.
BadStructToken
Unrecognized DTB structure token.
BadTotalSize
Total size in DTB header is incorrect.
BadU32List
Property value cannot be decoded as list of integers.
BadValueStr
Property value cannot be decoded as string.
BadVersion
DTB format version is less than last compatible version.
BufferTooSmall
Given buffer is too small to decode property value.
NoMoreStructItems
No more StructItem left in DTB structure.
NoZeroReservedMemEntry
No zero entry found in reserved memory block.
OutOfParentNode
Stopped matching a given path, since the parent node has ended.
OverlappingReservedMem
Reserved memory block overlaps a structure block.
OverlappingStrings
Structure block overlaps an end of blob.
OverlappingStruct
Structure block overlaps a strings block.
UnalignedBlob
Given blob is not 8-byte aligned.
UnalignedReservedMem
Reserved memory block is not 8-byte aligned.
UnalignedStruct
Structure block is not 4-byte aligned.
UnexpectedEndOfBlob
Given blob is smaller than DTB-header.
UnexpectedEndOfStruct
Structure block doesn’t end with DTB_END token.
UnsupportedCompVersion
Unsupported last compatible version.