From: Thierry Reding <tred...@nvidia.com>

The fdtdec_get_carveout() and fdtdec_set_carveout() function can be used
to read a carveout from a given node or add a carveout to a given node
using the standard device tree bindings (involving reserved-memory nodes
and the memory-region property).

Reviewed-by: Simon Glass <s...@chromium.org>
Signed-off-by: Thierry Reding <tred...@nvidia.com>
---
Changes in v3:
- add examples to code comments

Changes in v2:
- use debug() instead of printf() to save code size
- fix carveout size computations, was off by one
- use fdtdec_get_addr_size_auto_noparent()

 include/fdtdec.h | 81 ++++++++++++++++++++++++++++++++++++++++++++
 lib/fdtdec.c     | 87 ++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 168 insertions(+)

Applied to u-boot-dm, thanks!
_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot

Reply via email to