Hi Michal, > So we have 2 separate issues. I don't particularly like the concept of > introducing MEMBANK_NONE > and the changes below look a bit too much for me, given that for boot modules > we can only have > /memreserve/ matching initrd. > > Shawn patch fixes the first issue. AFAICT the second issue can be fixed by > below simple patch: > diff --git a/xen/common/device-tree/bootfdt.c > b/xen/common/device-tree/bootfdt.c > index 927f59c64b0d..d8bd8c44bd35 100644 > --- a/xen/common/device-tree/bootfdt.c > +++ b/xen/common/device-tree/bootfdt.c > @@ -586,6 +586,10 @@ size_t __init boot_fdt_info(const void *fdt, paddr_t > paddr) > > add_boot_module(BOOTMOD_FDT, paddr, fdt_totalsize(fdt), false); > > + ret = device_tree_for_each_node(fdt, 0, early_scan_node, NULL); > + if ( ret ) > + panic("Early FDT parsing failed (%d)\n", ret); > + > nr_rsvd = fdt_num_mem_rsv(fdt); > if ( nr_rsvd < 0 ) > panic("Parsing FDT memory reserve map failed (%d)\n", nr_rsvd); > @@ -594,10 +598,14 @@ size_t __init boot_fdt_info(const void *fdt, paddr_t > paddr) > { > struct membank *bank; > paddr_t s, sz; > + const struct bootmodule *mod = > boot_module_find_by_kind(BOOTMOD_RAMDISK); > > if ( fdt_get_mem_rsv_paddr(device_tree_flattened, i, &s, &sz) < 0 ) > continue; > > + if ( mod && (mod->start == s) && (mod->size == sz) ) > + continue;
Ok I see, we skip the /memreserve/ entry if it matches the ramdisk, fair enough, I don’t have a strong opinion on how we do that, the important thing is just to unblock the users experiencing this issue. Cheers, Luca