On 06/17/20 15:43, Guilherme Piccoli wrote:

> So, the only problem with that refactor you're proposing is the
> retrocompatibility with qemu versions, as I can anticipate cases in
> which newer OVMF runs with older qemu, which does not provide such
> trustworth physbits info.

I don't necessarily see compat issues -- large-BAR PCI device assignment
might simply stop working under those circumstances, because you could
no longer use X-PciMmio64Mb, and the new way wouldn't be supported by
(old) QEMU.

This would indeed be a regression relative to "X-PciMmio64Mb", but
that's exactly why there's an "X" in "X-PciMmio64Mb".

> So, the code may be a bit complex, it'll
> need to take into account this case (probably we could just rely on
> the physbits "detected" by OVMF in such case, limiting PCI64 aperture
> to the current 36-bits, right?).

A "bit complex" is an understatement. The code is already much more
complex than it should be. (And I do think that's an inherent, not
accidental, complexity; it reflects the situation.) Once we have a new
design, we should do the bare minimum to keep such previous usage
functional that's *not* reliant on X-PciMmio64Mb.

Laszlo


Reply via email to