23#define FDT_ERR_NOTFOUND 1
25#define FDT_ERR_EXISTS 2
29#define FDT_ERR_NOSPACE 3
37#define FDT_ERR_BADOFFSET 4
42#define FDT_ERR_BADPATH 5
47#define FDT_ERR_BADPHANDLE 6
53#define FDT_ERR_BADSTATE 7
60#define FDT_ERR_TRUNCATED 8
65#define FDT_ERR_BADMAGIC 9
70#define FDT_ERR_BADVERSION 10
76#define FDT_ERR_BADSTRUCTURE 11
81#define FDT_ERR_BADLAYOUT 12
90#define FDT_ERR_INTERNAL 13
97#define FDT_ERR_BADNCELLS 14
102#define FDT_ERR_BADVALUE 15
108#define FDT_ERR_BADOVERLAY 16
114#define FDT_ERR_NOPHANDLES 17
119#define FDT_ERR_BADFLAGS 18
124#define FDT_ERR_ALIGNMENT 19
129#define FDT_ERR_MAX 19
142 UINT32 OffsetDtStruct;
143 UINT32 OffsetDtStrings;
144 UINT32 OffsetMemRsvmap;
146 UINT32 LastCompVersion;
149 UINT32 BootCpuidPhys;
152 UINT32 SizeDtStrings;
176#define FDT_TAGSIZE sizeof(UINT32)
178#ifndef FDT_MAX_NCELLS
179#define FDT_MAX_NCELLS 4
182#define FdtGetHeader(Fdt, Field) \
183 (Fdt32ToCpu (((const FDT_HEADER *)(Fdt))->Field))
184#define FdtTotalSize(Fdt) (FdtGetHeader ((Fdt), TotalSize))
186#define FdtForEachSubnode(Node, Fdt, Parent) \
187 for (Node = FdtFirstSubnode (Fdt, Parent); \
189 Node = FdtNextSubnode (Fdt, Node))
418 IN INT32 ParentOffset,
488 IN INT32 StartOffset,
491 IN INT32 PropertyLength
631 IN INT32 *Length OPTIONAL
648 IN INT32 ParentOffset,
815 IN INT32 StartOffset,
INT32 EFIAPI FdtNodeDepth(IN CONST VOID *Fdt, IN INT32 NodeOffset)
INT32 FdtDelProp(IN OUT VOID *Fdt, IN INT32 NodeOffset, IN CONST CHAR8 *Name)
INT32 EFIAPI FdtAppendProp(IN VOID *Fdt, IN INT32 NodeOffset, IN CONST CHAR8 *Name, IN CONST VOID *Value, IN UINT32 Length)
UINT64 EFIAPI CpuToFdt64(IN UINT64 Value)
INT32 EFIAPI FdtStringListContains(IN CONST CHAR8 *StringList, IN INT32 ListLength, IN CONST CHAR8 *String)
CONST VOID *EFIAPI FdtOffsetPointer(IN CONST VOID *Fdt, IN INT32 Offset, IN UINT32 Length)
INT32 EFIAPI FdtNextPropertyOffset(IN CONST VOID *Fdt, IN INT32 Offset)
INT32 EFIAPI FdtNodeOffsetByPropertyValue(IN CONST VOID *Fdt, IN INT32 StartOffset, IN CONST CHAR8 *PropertyName, IN CONST VOID *PropertyValue, IN INT32 PropertyLength)
INT32 EFIAPI FdtFirstSubnode(IN CONST VOID *Fdt, IN INT32 Offset)
CONST FDT_PROPERTY *EFIAPI FdtGetProperty(IN CONST VOID *Fdt, IN INT32 NodeOffset, IN CONST CHAR8 *Name, IN INT32 *Length)
UINT64 EFIAPI Fdt64ToCpu(IN UINT64 Value)
INT32 EFIAPI FdtOpenInto(IN CONST VOID *Fdt, OUT VOID *Buffer, IN INT32 BufferSize)
CONST CHAR8 *EFIAPI FdtGetAliasNameLen(IN CONST VOID *Fdt, IN CONST CHAR8 *Name, IN INT32 Length)
CONST CHAR8 *EFIAPI FdtGetString(IN CONST VOID *Fdt, IN INT32 StrOffset, IN INT32 *Length OPTIONAL)
INT32 EFIAPI FdtSetProperty(IN VOID *Fdt, IN INT32 NodeOffset, IN CONST CHAR8 *Name, IN CONST VOID *Value, IN UINT32 Length)
INT32 EFIAPI FdtPack(IN OUT VOID *Fdt)
UINT16 EFIAPI Fdt16ToCpu(IN UINT16 Value)
INT32 EFIAPI FdtNodeOffsetByCompatible(IN CONST VOID *Fdt, IN INT32 StartOffset, IN CONST CHAR8 *Compatible)
INT32 EFIAPI FdtSetPropU64(IN VOID *Fdt, IN INT32 NodeOffset, IN CONST CHAR8 *Name, IN UINT64 Value)
INT32 EFIAPI FdtSubnodeOffsetNameLen(IN CONST VOID *Fdt, IN INT32 ParentOffset, IN CONST CHAR8 *Name, IN INT32 NameLength)
INT32 EFIAPI FdtAddressCells(IN CONST VOID *Fdt, IN INT32 NodeOffset)
INT32 EFIAPI FdtAddSubnode(IN VOID *Fdt, IN INT32 ParentOffset, IN CONST CHAR8 *Name)
UINT16 EFIAPI CpuToFdt16(IN UINT16 Value)
INT32 EFIAPI FdtNextNode(IN CONST VOID *Fdt, IN INT32 Offset, IN INT32 *Depth)
UINT32 EFIAPI CpuToFdt32(IN UINT32 Value)
INT32 EFIAPI FdtCheckHeader(IN CONST VOID *Fdt)
INT32 EFIAPI FdtParentOffset(IN CONST VOID *Fdt, IN INT32 NodeOffset)
INTN EFIAPI FdtGetNumberOfReserveMapEntries(IN CONST VOID *Fdt)
UINT32 EFIAPI Fdt32ToCpu(IN UINT32 Value)
INT32 EFIAPI FdtSizeCells(IN CONST VOID *Fdt, IN INT32 NodeOffset)
INT32 EFIAPI FdtPathOffset(IN CONST VOID *Fdt, IN CONST CHAR8 *Path)
INT32 EFIAPI FdtFirstPropertyOffset(IN CONST VOID *Fdt, IN INT32 NodeOffset)
INT32 EFIAPI FdtPathOffsetNameLen(IN CONST VOID *Fdt, IN CONST CHAR8 *Path, IN INT32 NameLength)
CONST CHAR8 *EFIAPI FdtGetName(IN VOID *Fdt, IN INT32 NodeOffset, IN INT32 *Length)
INT32 EFIAPI FdtNodeOffsetByPhandle(IN CONST VOID *Fdt, IN UINT32 Phandle)
INTN EFIAPI FdtGetReserveMapEntry(IN CONST VOID *Fdt, IN INTN Index, OUT UINT64 *Addr, OUT UINT64 *Size)
INT32 EFIAPI FdtCreateEmptyTree(IN VOID *Buffer, IN UINT32 BufferSize)
INT32 EFIAPI FdtNextSubnode(IN CONST VOID *Fdt, IN INT32 Offset)
CONST FDT_PROPERTY *EFIAPI FdtGetPropertyByOffset(IN CONST VOID *Fdt, IN INT32 Offset, IN INT32 *Length)