SHIVAM DEOLANKAR commented on a discussion on bsps/aarch64/xilinx-zynqmp/start/bspstart.c: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1116#note_145111 > + if (ranges == NULL) { > + return; > + } > + > + uint64_t addr; > + uint64_t size; > + > + /* Extract PCIe address and size from the ranges property */ > + addr = fdt64_to_cpu(*(uint64_t *)&ranges[1]); > + size = fdt64_to_cpu(*(uint64_t *)&ranges[3]); > + > + aarch64_mmu_map( > + addr, > + addr + size, > + AARCH64_MMU_DEVICE > + ); The PCIe initialization code has been moved into a static function `zynqmp_pcie_init()` which is called from `bsp_start()`. The formatting has been adjusted to follow the existing BSP style. A NULL check for the pointer returned by `bsp_fdt_get()` has been added to avoid a potential crash if the FDT is missing. Additionally, an example PCIe node from the device tree has been included as a comment to document the expected `ranges` property format. -- View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems/-/merge_requests/1116#note_145111 You're receiving this email because of your account on gitlab.rtems.org.
_______________________________________________ bugs mailing list [email protected] http://lists.rtems.org/mailman/listinfo/bugs
