summaryrefslogtreecommitdiff
path: root/board/raspberrypi/rpi/rpi.c
diff options
context:
space:
mode:
Diffstat (limited to 'board/raspberrypi/rpi/rpi.c')
-rw-r--r--board/raspberrypi/rpi/rpi.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/board/raspberrypi/rpi/rpi.c b/board/raspberrypi/rpi/rpi.c
index 6b1fa5fc14..df52a4689f 100644
--- a/board/raspberrypi/rpi/rpi.c
+++ b/board/raspberrypi/rpi/rpi.c
@@ -157,6 +157,16 @@ static const struct rpi_model rpi_models_new_scheme[] = {
DTB_DIR "bcm2711-rpi-4-b.dtb",
true,
},
+ [0x13] = {
+ "400",
+ DTB_DIR "bcm2711-rpi-400.dtb",
+ true,
+ },
+ [0x14] = {
+ "Compute Module 4",
+ DTB_DIR "bcm2711-rpi-cm4.dtb",
+ true,
+ },
};
static const struct rpi_model rpi_models_old_scheme[] = {
@@ -268,6 +278,13 @@ int dram_init(void)
gd->ram_size = msg->get_arm_mem.body.resp.mem_size;
+ /*
+ * In some configurations the memory size returned by VideoCore
+ * is not aligned to the section size, what is mandatory for
+ * the u-boot's memory setup.
+ */
+ gd->ram_size &= ~MMU_SECTION_SIZE;
+
return 0;
}