[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] PVH and ACPI discussion



On Fri, Jan 04, 2019 at 06:10:29AM -0700, Jan Beulich wrote:
> >>> On 03.01.19 at 18:45, <roger.pau@xxxxxxxxxx> wrote:
> > While looking at some tangential issues I realized that the 'VGA Not
> > Present' flag that Xen currently sets for PVH DomUs might be slightly
> > different from what we expect it to mean. The purpose was that Xen
> > would set this flag to denote there's no VGA MMIO region in the low
> > 1MB, so that the guest OS would not reserve memory in that area
> > thinking there's a MMIO window there. The memory map provided to a PVH
> > DomU typically contains a single RAM range that expands from 0 to the
> > selected amount of memory.
> > 
> > The description of such flag by the ACPI spec (6.2A) however is as
> > follows:
> > 
> > "If set, indicates to OSPM that it must not blindly probe the VGA
> > hardware (that responds to MMIO addresses A0000h-BFFFFh and IO ports
> > 3B0h-3BBh and 3C0h-3DFh) that may cause machine check on this system.
> > If clear, indicates to OSPM that it is safe to probe the VGA
> > hardware."
> > 
> > My reading of the above text would make me think that if the flag is
> > set the memory region A0000h-BFFFFh should not be used at all, and
> > that would be in conflict with the memory map that's provided to
> > guests (which lists this area as RAM).
> > 
> > I'm not convinced of the best way to proceed here. I can contact the
> > ACPI working group and try to clarify the meaning of the flag, or
> > inquiry if there's a more suitable flag for or use case, but I would
> > like to hear others opinion on this topic.
> 
> "Should not blindly probe" != "should not use". To me the wording
> implies that some secondary means are necessary to tell what the
> region is used for, which is left unspecified by ACPI itself. If that's
> what's meant, we're free to make our secondary spec "it's RAM in
> all cases".

OK, so in our case this flag together with the memory map provided to
the guest should make it clear this is a RAM region and accesses are
fine.

> > Secondly, I've also been looking at whether it would make sense to set
> > the ACPI reduced hardware flag for PVH DomUs, according to the
> > description in the ACPI spec:
> > 
> > "For certain classes of systems the ACPI Hardware Specification may
> > not be adequate. Examples include legacy-free, UEFI-based platforms
> > with recent processors, and those implementing mobile platform
> > architectures. For such platforms, a Hardware-reduced ACPI mode is
> > defined."
> > 
> > Certainly the legacy-free and UEFI part is quite applicable to PVH
> > DomU, for which we don't plan to support legacy BIOS and only provide
> > UEFI firmware in the long term.
> > 
> > Reduced HW ACPI also gets rid of the SCI interrupt, and instead
> > provides some other methods to signal ACPI events (note we don't
> > use any ACPI event ATM for PVH DomU). It also gets rid of a bunch of
> > FADT fields that we don't use for PVH DomU either.
> > 
> > I however seem to remember some past discussion about PVH DomU and
> > reduced ACPI, but I cannot find the thread. If there are no objections
> > I think we should look into this (likely discuss with the ACPI working
> > group) in order to figure out if reduced HW ACPI could work for us,
> > and how the event delivery could be implemented for PVH DomU if it
> > turns out we need it later on. It might make sense to also figure out
> > what other people do, like HyperV Gen2 instances (which also get rid
> > of a lot of legacy hw).
> 
> Well, without a proper / complete list of implications and restrictions
> resulting from that mode I don't think we can take a decision either
> way. All I recall is things being scattered all over the spec at the time
> I first looked at this a little.

Yes. I've looked at the spec also, and I'm having the same issue. It's
hard to tell exactly what reduced hardware ACPI implies, because
there's no clear list of differences from traditional ACPI, and it's
all scattered around the spec. I will likely send an email to the ACPI
working group about this.

Do you agree however that PVH DomU could maybe use reduced hardware
ACPI while Dom0 using whatever mode (reduced or not) is set by the
native ACPI tables?

Thanks, Roger.

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.