Thread (59 messages) 59 messages, 8 authors, 7d ago

Re: [PATCH v19 6/7] firmware: arm_rmm: Ensure the RMM has GPT entries for memory

flat view

From: Jonathan Cameron <hidden>
Date: 2026-09-25 15:30:48
Also in: kvm, kvmarm, linux-coco, lkml

quoted
quoted
+
+static int rmi_init_metadata(void)
+{
+	phys_addr_t start, end;
+	struct memblock_region *r;
+
+	for_each_mem_region(r) {
+		int ret;
+
+		/* Firmware-reserved NOMAP regions are not usable system RAM */
+		if (memblock_is_nomap(r))
+			continue;
+
+		start = PAGE_ALIGN(r->base);
+		end = PAGE_ALIGN_DOWN(r->base + r->size);  
Add a comment on why rounding down.  Doe we expect that to ever be relevant?  
Do we really need a comment here ? We always deal with PAGE_SIZE and if
in the odd case this region boundary is not PAGE aligned we stick to the
page that we can use from the region. I can stick in a comment if you
really think so.
Ok.  I was mostly thinking that it was an odd thing to happen.



Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help