On 21.05.2025 16:35, Alejandro Vallejo wrote: > I think we should aim to share binding code wherever possible, using common > datastructures (kernel_info and bootmodule) as dumping ground for the results > of the binding parsing functions. I seek agreement on the following 3 points > for the end goal of DTB multidomain boots on x86 before I start slicing > my hacks into reasonable chunks. > > 1. We want common data structures, with arch-specific fields to hold > information from xen,domain DT nodes > 2. We want to have a single collection of DTB parsers in the code. > 3. We want to operate on the unflattened DTB for the majority of parsing. > (plus a minimal version on the FDT in order to bootstrap, also common)
+1 on all three, with the caveat that I'm far from being an expert on DT. Jan > (2) and (3) are tightly related. There's many reasons for wanting to use the > unflattened blobs as much as possible. They range from quirks in specific > "dtc" > versions, to complexities parsing phandles, to corner cases involving > duplicate > properties (i.e: due to .dtsi files), etc. Unflattening an FDT brings a > lots of "maybe-ok-after-sanitising" FDTs back into canonically correct DTs. > > I'll share the PoC code as soon as as it's in a presentable state. > Hopefully by the end of the week. But I'm sending this ahead of time to > start collecting thoughts right away. > > So. Thoughts? > > Cheers, > Alejandro