coreboot/src/lib
Maximilian Brune 33079b8174 lib/device_tree: Add some FDT helper functions
This adds some helper functions for FDT, since more and more mainboards
seem to need FDT nowadays. For example our QEMU boards need it in order
to know how much RAM is available. Also all RISC-V boards in our tree
need FDT.

This also adds some tests in order to test said functions.

Signed-off-by: Maximilian Brune <maximilian.brune@9elements.com>
Change-Id: I2fb1d93c5b3e1cb2f7d9584db52bbce3767b63d8
Reviewed-on: https://review.coreboot.org/c/coreboot/+/81081
Reviewed-by: Julius Werner <jwerner@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
2024-05-21 13:44:47 +00:00
..
gnat lib,console,sbom: Rename Makefiles from .inc to .mk 2024-01-24 10:12:57 +00:00
asan.c Allow to build romstage sources inside the bootblock 2023-11-09 13:20:18 +00:00
b64_decode.c
bmp_logo.c lib: Refactor bmp_load_logo() implementation 2024-04-06 04:31:50 +00:00
boot_device.c
bootblock.c
bootmem.c
bootmode.c lib: Perform display init in normal boot mode if BMP_LOGO is set 2023-05-16 13:08:12 +00:00
bootsplash.c tree: Drop unused <stdlib.h> 2024-04-11 19:24:44 +00:00
cb.ads
cbfs.c treewide: Move list.h to commonlib 2024-02-24 11:49:46 +00:00
cbfs_master_header.c
cbmem_common.c
cbmem_console.c lib/cbmem_console.c: Use C99 flexible arrays 2023-07-30 09:59:46 +00:00
cbmem_stage_cache.c src/lib: Add memory/time saving special case for ramstage caching 2023-12-18 08:13:12 +00:00
coreboot_table.c tree: Remove blank lines before '}' and after '{' 2024-04-11 19:19:08 +00:00
crc_byte.c
decompressor.c
delay.c
device_tree.c lib/device_tree: Add some FDT helper functions 2024-05-21 13:44:47 +00:00
dimm_info_util.c lib/dimm_info_util.c: Add newlines to log messages 2023-06-03 16:12:54 +00:00
dp_aux.c
edid.c tree: Remove blank lines before '}' and after '{' 2024-04-11 19:19:08 +00:00
edid_fill_fb.c treewide: Move list.h to commonlib 2024-02-24 11:49:46 +00:00
espi_debug.c
ext_stage_cache.c src/lib: Add memory/time saving special case for ramstage caching 2023-12-18 08:13:12 +00:00
fallback_boot.c
fit.c treewide: Move stdlib.h to commonlib 2024-03-15 10:09:43 +00:00
fit_payload.c
fmap.c tree: Use accessor functions for struct region fields 2024-01-14 02:06:11 +00:00
fw_config.c lib/fw_config: Remove redundant stdbool and stdint 2024-01-13 20:27:48 +00:00
gcc.c
gcov-glue.c
gcov-io.c
gcov-io.h lib/gcov-io.h: Use C99 flexible arrays 2023-08-01 13:34:27 +00:00
gcov-iov.h
gpio.c
halt.c treewide: Move stdlib.h to commonlib 2024-03-15 10:09:43 +00:00
hardwaremain.c tree: Remove blank lines before '}' and after '{' 2024-04-11 19:19:08 +00:00
hexdump.c
hexstrtobin.c
hw-time-timer.adb
identity.c
imd.c
imd_cbmem.c
jpeg.c lib/jpeg: Replace decoder with Wuffs' implementation 2023-12-13 16:17:34 +00:00
jpeg.h lib/jpeg: Replace decoder with Wuffs' implementation 2023-12-13 16:17:34 +00:00
Kconfig ec, lib, security, sb: Add SPDX license headers to Kconfig files 2024-02-18 02:00:21 +00:00
Kconfig.cbfs_verification Kconfig.cbfs_verification: Update TOCTOU_SAFETY combination with VBOOT 2023-11-07 22:30:20 +00:00
libgcc.c
libgcov.c treewide: Move stdlib.h to commonlib 2024-03-15 10:09:43 +00:00
lzma.c
lzmadecode.c lib/lzmadecode: Allow for 8 byte reads on 64bit 2024-02-21 16:19:05 +00:00
lzmadecode.h lib/lzmadecode: Allow for 8 byte reads on 64bit 2024-02-21 16:19:05 +00:00
Makefile.mk lib: Remove heap from rmodules 2024-02-26 10:10:07 +00:00
malloc.c malloc/memalign: Return NULL if the request is too large 2024-01-29 19:12:43 +00:00
master_header_pointer.c
memchr.c
memcmp.c
memcpy.c
memmove.c
memrange.c tree: Remove blank lines before '}' and after '{' 2024-04-11 19:19:08 +00:00
memset.c
metadata_hash.c
nhlt.c
primitive_memtest.c
prog_loaders.c Allow to build romstage sources inside the bootblock 2023-11-09 13:20:18 +00:00
prog_ops.c
program.ld lib/program.ld: Account for large code model sections 2024-04-08 00:02:18 +00:00
ramdetect.c riscv/mb/qemu: fix DRAM probing 2024-03-04 23:43:46 +00:00
ramtest.c commonlib/console/post_code.h: Change post code prefix to POSTCODE 2023-06-23 15:06:04 +00:00
reg_script.c tree: Drop duplicated <device/{path,resource}.h> 2024-04-12 04:24:20 +00:00
region_file.c tree: Remove blank lines before '}' and after '{' 2024-04-11 19:19:08 +00:00
reset.c
rmodule.c
rmodule.ld
romstage_handoff.c
rtc.c lib/rtc: Fix off-by-one error in February day count in leap year 2024-02-29 13:07:02 +00:00
selfboot.c
smbios.c tree: Drop duplicated <device/pci_{def,type}.h> 2024-04-12 04:24:43 +00:00
smbios_defaults.c arch/x86,lib: Migrate SMBIOS implementation to common code 2023-06-22 22:24:57 +00:00
spd_bin.c lib/spd_bin: Add LPDDR5X dram_type in use_ddr4_params 2024-03-28 07:26:45 +00:00
spd_cache.c
stack.c tree: Remove blank lines before '}' and after '{' 2024-04-11 19:19:08 +00:00
string.c
thread.c lib/thread.c: Move 'asmlinkage' before type 'void' 2024-04-10 06:05:55 +00:00
timer.c
timer_queue.c
timestamp.c
ubsan.c lib/ubsan.c: Restore Jonas' copyright 2023-05-22 12:33:32 +00:00
uuid.c
ux_locales.c lib: Update locales for non-VBOOT platforms 2023-11-16 05:19:20 +00:00
version.c
wrdd.c
xxhash.c