RTEMS | bsps/riscv: Checked conditions for FDT pointer (!1057)
Gedare Bloom (@gedare)
gitlab at rtems.org
Tue Feb 10 18:35:52 UTC 2026
Gedare Bloom started a new discussion on bsps/shared/start/bsp-fdt.c: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1057#note_142346
> {
> + const void *bsp_fdt = NULL;
> +
> #ifdef BSP_DTB_IS_SUPPORTED
> - return system_dtb;
> + bsp_fdt = system_dtb;
> #else
> - return &bsp_fdt_blob[0];
> + bsp_fdt = &bsp_fdt_blob[0];
> #endif
> +
> +if (bsp_fdt == NULL) {
> + rtems_fatal(RTEMS_FATAL_SOURCE_BSP, 0);
> +}
> +
> +if (((uintptr_t)bsp_fdt & 0x7) != 0) {
this is redundant to `fdt_check_header`
--
View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1057#note_142346
You're receiving this email because of your account on gitlab.rtems.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20260210/3c4041ac/attachment-0001.htm>
More information about the bugs
mailing list