Received: from eggs.gnu.org ([2001:4830:134:3::10]:49155) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z7nES-0000PR-VG for qemu-devel@nongnu.org; Wed, 24 Jun 2015 12:09:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Z7nEN-0003vx-0V for qemu-devel@nongnu.org; Wed, 24 Jun 2015 12:09:00 -0400 Received: from mx1.redhat.com ([209.132.183.28]:41457) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z7nEM-0003vs-Ov for qemu-devel@nongnu.org; Wed, 24 Jun 2015 12:08:54 -0400 Date: Wed, 24 Jun 2015 13:08:52 -0300 From: Eduardo Habkost Message-ID: <20150624160852.GY3134@thinpad.lan.raisama.net> References: <20150623162555.GL30318@redhat.com> <20150623183115-mutt-send-email-mst@redhat.com> <20150623164204.GM30318@redhat.com> <55898D94.4070702@suse.de> <20150623171122.GI3134@thinpad.lan.raisama.net> <20150623213445.GA17756@redhat.com> <20150624142446.GU3134@thinpad.lan.raisama.net> <20150624162659-mutt-send-email-mst@redhat.com> <20150624154429.GW3134@thinpad.lan.raisama.net> <558AD39A.1070607@suse.de> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline In-Reply-To: <558AD39A.1070607@suse.de> Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] Not introducing new host-side requirements on new machine-type versions (was Re: [PATCH 0/2] target-i386: "custom" CPU model + script to dump existing CPU models) List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Andreas =?iso-8859-1?Q?F=E4rber?= Cc: mimu@linux.vnet.ibm.com, "Michael S. Tsirkin" , qemu-devel@nongnu.org, Alexander Graf , borntraeger@de.ibm.com, Igor Mammedov , Paolo Bonzini , Jiri Denemark , rth@twiddle.net On Wed, Jun 24, 2015 at 05:58:18PM +0200, Andreas F=E4rber wrote: > Am 24.06.2015 um 17:44 schrieb Eduardo Habkost: > > In another message, Paolo wrote: > >> libvirt should trust that QEMU developers will not prevent a VM from > >> running on a previously viable host, just because you change the mac= hine > >> type. > >=20 > > I assumed that was never going to be true. > >=20 > > As long as QEMU guarantees that, so we don't change existing CPU mode= ls > > (in new machines) in a way that introduces new host-side dependencies= , > > we will be OK. > >=20 > > We may need something new to implement this guarantee for KVM feature= s, > > though. libvirt will need something that says "please don't enable an= y > > KVM CPUID bits silently for me, let me ask for them explicitly". But > > that won't be as drastic as requiring "-cpu custom". >=20 > That's what I suggested a global property for yesterday. Not sure how i= t > would be implemented though. A "default-kvm-features" property that enables/disables loading of kvm_default_features would be enough, probably. >=20 > > That have some consequences in the way we add new CPU models and > > implement CPU model changes. For example: until we know all the featu= res > > we want in a CPU model are already available and supported in the lat= est > > kernel, we won't add a new CPU model. The choice of features in CPU > > models should be "final" as soon as we add the CPU model, so CPU mode= l > > changes should never introduce new host-side requirements. If a CPU > > model change requires some additional KVM code or newer host CPU, we > > need to add a new CPU model name. We must agree on that and document = it, > > because I expect to see some complaints in the future when enforcing > > this rule. > >=20 > >> > >> It's as if someone wrote a wrapper around all kernel system calls > >> on the assumption that kernel can not guarantee kernel/userspace ABI > >> will never change. It can and it does. > >> > >> So let's promise not to break things, and avoid a ton of copy and pa= ste bugs. > >=20 > > My assumption was that this (introducing type-(2) machine changes) wa= s > > never considered "breaking things" and just a fact of life. > >=20 > > If we guarantee that we will never prevent a VM from running on a > > previously viable host, just because you change the machine type, we > > will be OK. >=20 > Could you clarify whether that is for KVM only or in general? >=20 > Also, if we ignore qemu64 and pick a current X86CPU such as Haswell, ca= n > you make a list of features that are missing in our model and in KVM, i= f > any, and might be enabled in future Haswell / Haswell+X models? What > delta are we talking about exactly? We can make a list by comparing CPUID data from the guest/QEMU with the real host CPUID data. But I believe we don't have any features we expect to enable in the future in existing CPU models that would require new KVM-side code. We just need to be aware of this in the (unlikely?) case it happens. Note that the recent ARAT patches are OK because they don't depend on new KVM-side GET_SUPPORTED_CPUID changes to work. >=20 > Are we at the same point of stability guarantee for ppc POWER? > For s390x, arm and aarch64 I guess not yet? That's a good question, and I have no idea how difficult it would be to implement that guarantee in those machines. In s390x we are implementing machine-type-dependent "runnable" info on query-cpu-definitions, but I don't know what the use caes look like, and what are the consequences for libvirt and OpenStack. --=20 Eduardo