[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v2 5/6] x86: fix up 32 bit phys_bits case
From: |
Daniel P. Berrange |
Subject: |
Re: [Qemu-devel] [PATCH v2 5/6] x86: fix up 32 bit phys_bits case |
Date: |
Tue, 5 Jul 2016 10:42:49 +0100 |
User-agent: |
Mutt/1.6.1 (2016-04-27) |
On Mon, Jul 04, 2016 at 08:16:08PM +0100, Dr. David Alan Gilbert (git) wrote:
> From: "Dr. David Alan Gilbert" <address@hidden>
>
> On 32 bit systems fix up phys_bits to be consistent with what
> we tell the guest; don't ever bother with using the phys_bits
> property.
> @@ -2990,6 +2986,15 @@ static void x86_cpu_realizefn(DeviceState *dev, Error
> **errp)
> cpu->phys_bits = host_phys_bits;
>
> }
> + } else {
> + /* For 32 bit systems don't use the user set value, but keep
> + * phys_bits consistent with what we tell the guest.
> + */
> + if (env->features[FEAT_1_EDX] & CPUID_PSE36) {
> + cpu->phys_bits = 36;
> + } else {
> + cpu->phys_bits = 32;
> + }
I kind of feel like we should report an error and exit if the
user/app has provided a phys_bits property value, rather than
silently ignoring their provided value, on the basis that this
is a user/app configuration error.
Regards,
Daniel
--
|: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org -o- http://virt-manager.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|
- Re: [Qemu-devel] [PATCH v2 2/6] x86: Mask mtrr mask based on CPU physical address limits, (continued)
[Qemu-devel] [PATCH v2 6/6] x86: Add sanity checks on phys_bits, Dr. David Alan Gilbert (git), 2016/07/04
Re: [Qemu-devel] [PATCH v2 0/6] x86: Physical address limit patches, Michael S. Tsirkin, 2016/07/04