From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755187AbbCRIq0 (ORCPT ); Wed, 18 Mar 2015 04:46:26 -0400 Received: from youngberry.canonical.com ([91.189.89.112]:34276 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751074AbbCRIqV (ORCPT ); Wed, 18 Mar 2015 04:46:21 -0400 Message-ID: <55093B52.5090904@canonical.com> Date: Wed, 18 Mar 2015 09:46:10 +0100 From: Stefan Bader User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.5.0 MIME-Version: 1.0 To: kvm@vger.kernel.org, Linux Kernel Mailing List , Paolo Bonzini Subject: regression: nested: L1 3.15+ fails to load kvm-intel on L0 <3.15 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="spe3D2LNn6wKkNS5akjXKtSu3e06jiNqq" Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --spe3D2LNn6wKkNS5akjXKtSu3e06jiNqq Content-Type: text/plain; charset=iso-8859-15 Content-Transfer-Encoding: quoted-printable Someone reported[1] that some of their L1 guests fail to load the kvm-int= el module (without much details). Turns out that this was (at least) caused = by KVM: vmx: Allow the guest to run with dirty debug registers as this adds VM_EXIT_SAVE_DEBUG_CONTROLS to the required MSR_IA32_VMX_EXI= T_CTLS bits. Not sure this should be fixed up in pre 3.15 kernels or the other w= ay round. Maybe naively asked but would it be sufficient to add this as requ= ired to older kernels vmcs setup (without the code to make any use of it)? Regardless of that, I wonder whether the below (this version untested) so= und acceptable for upstream? At least it would make debugging much simpler. := ) --- a/arch/x86/kvm/vmx.c +++ b/arch/x86/kvm/vmx.c @@ -2953,8 +2953,11 @@ static __init int adjust_vmx_controls(u32 ctl_min,= u32 ct ctl |=3D vmx_msr_low; /* bit =3D=3D 1 in low word =3D=3D> must = be one */ /* Ensure minimum (required) set of control bits are supported. *= / - if (ctl_min & ~ctl) + if (ctl_min & ~ctl) { + printk(KERN_ERR "vmx: msr(%08x) does not match requiremen= ts. " + "req=3D%08x cur=3D%08x\n", msr, ctl_min, = ctl); return -EIO; + } *result =3D ctl; return 0; Thanks, -Stefan [1] https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1431473 --spe3D2LNn6wKkNS5akjXKtSu3e06jiNqq Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIcBAEBCgAGBQJVCTtaAAoJEOhnXe7L7s6jIKgP/0C7degdlWpiM7FEQQS56g2o dKLGBRq3CNd/0v+RKS6syr0b8BaIsYo3VpD9hZzO18fqimQyKfBDs1xVV6R+VWPm ehKo7J1Tlqi0Ff1CQj5GLX+Ps2NDM1YtpOijNDxdETRTO1W5REECA2K5XMfNT/oa c17HisJs+qZ7Ef4vRVtIE0xWuMJC4z0F2/DtOOwkKGyLfby+UXUpAlVAsuzpTGlu ULxwieXXgrIHBHq5MjxmpdXxgO6EQq6P1oKPMpV+F+ISmG8fTrtOdYBA1NS+Hcfd iWIeOJDYr3uIY0TiAbJuRgaisNAkz+7f+OFWiHSHPnxP55nEUe7tMAaBnGjiWb9n PUl25Hq7scXHo7cQR+hMzs76hwUgNBY3FZDMbre6Q7aTuk+3bquW4CUBOukqDv2u +kbsNHNkB9HGenOyJCgeEEy8XEdZCNL/wJfC2RRz8SOjLpclnII8hXGvoCFBRzpO QCCZBbCxm77JamNhnlSs3qioaVk5Xa56VMvNLS89QGpngPrmOsQMurFuMu2zeSX/ PU7ENDAW0BKuBMcKrnVW+XsdKQpMuZW+AK3wWB0mHz94txUfhdAAnZkEo3fVpbhZ 08a4DyL5U/hVuxsqLpjbyhTkTU7iJVtVd7YcQt/43S5D9NBVspcYPx9HRuUHGTyU hK52OEmlrV5PkNSa2hn+ =ghzk -----END PGP SIGNATURE----- --spe3D2LNn6wKkNS5akjXKtSu3e06jiNqq--