mirror of
https://github.com/dgibson/dtc.git
synced 2025-10-13 16:27:39 -04:00
libfdt: Add functions to get/add/delete memory reservemap entries
This patch adds functions to libfdt for accessing the memory reservation map section of a device tree blob. fdt_num_mem_rsv() retreives the number of reservation entries in a dtb, and fdt_get_mem_rsv() retreives a specific reservation entry. fdt_add_mem_rsv() adds a new entry, and fdt_del_mem_rsv() removes a specific numbered entry. Testcases for these new functions are also included. Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
This commit is contained in:
parent
ad9593f229
commit
fd1bf3a5ae
13 changed files with 131 additions and 3 deletions
|
@ -108,6 +108,8 @@ static inline void *xrealloc(void *p, size_t size)
|
|||
return p;
|
||||
}
|
||||
|
||||
void check_mem_rsv(void *fdt, int n, uint64_t addr, uint64_t size);
|
||||
|
||||
void check_property(void *fdt, int nodeoffset, const char *name,
|
||||
int len, const void *val);
|
||||
#define check_property_typed(fdt, nodeoffset, name, val) \
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue