On Fri, 9 May 2025 at 15:32, Cédric Le Goater <c...@redhat.com> wrote:
> In the ast2700fc machine and the fby35, each SoC has its own memory
> region and, since there is no need for the global system memory
> region, it's empty. But in some places, like
> rom_check_and_register_reset(), it's a problem for the flattened
> global view.

Generally speaking, board models should set things up so
that the "main" SoC for the board uses the main system memory
MR, rather than creating its own empty MR for that purpose,
I think.

But separately from that, it's weird to get into flatview_lookup
with an empty FlatView here. We called memory_region_find(),
which is a wrapper around memory_region_find_rcu(). That
function doesn't make assumptions about where the MR it's
passed is from: it walks up the tree of MRs to find the
root MR, it looks up the AddressSpace for that root MR,
and then it gets the FlatView for that AS and calls
flatview_lookup(). If the FlatView we end up with doesn't
have the MR in it, what's happened ?

-- PMM

Reply via email to