From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jan Kiszka Subject: Re: [PATCH 1/4] Fix tboot enabled macro Date: Wed, 26 May 2010 09:25:49 +0200 Message-ID: <4BFCCCFD.20203@web.de> References: <4BFC9686.9050300@redhat.com> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="------------enig2D4CF80948DD6548AA7C9D80" Cc: kvm , Avi Kivity , Gleb Natapov , Shane Wang To: Zachary Amsden Return-path: Received: from fmmailgate02.web.de ([217.72.192.227]:60655 "EHLO fmmailgate02.web.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754403Ab0EZH02 (ORCPT ); Wed, 26 May 2010 03:26:28 -0400 In-Reply-To: <4BFC9686.9050300@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: This is an OpenPGP/MIME signed message (RFC 2440 and 3156) --------------enig2D4CF80948DD6548AA7C9D80 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Zachary Amsden wrote: >=20 (please post inlined - I have to copy your patch manually now) > From 614d5fa8bba5f98fd3cb1d66d63b0b70ca98fe51 Mon Sep 17 00:00:00 2001 > From: Zachary Amsden > Date: Fri, 14 May 2010 12:25:14 -1000 > Subject: [PATCH 1/5] Fix tboot_enabled macro; was present in 2.6.33 >=20 > Signed-off-by: Zachary Amsden > --- > x86/external-module-compat.h | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) >=20 > diff --git a/x86/external-module-compat.h b/x86/external-module-compat.= h > index 7d793a0..09bf232 100644 > --- a/x86/external-module-compat.h > +++ b/x86/external-module-compat.h > @@ -770,7 +770,7 @@ static inline void hw_breakpoint_restore(void) > #define percpu_write(t, v) __get_cpu_var(t) =3D v > #endif > =20 > -#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,35) > +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,33) > #define tboot_enabled() 0 > #endif This is for CONFIG_INTEL_TXT enabled? Good point but needs to be solved differently. tboot, the variable that is checked by the original header, is not exported to modules. I wonder how this worked out for you... Solution should be: hack tboot_enabled to kvm_tboot_enabled and unconditionally define that to 0 for older kernels. If tboot is actually enabled in hardware, KVM may not load but I'm unsure if it's OK to assume tboot =3D=3D 1 for that case or if that will cause breakages if it= 's off instead - CC'ing the KVM patch author. Jan --------------enig2D4CF80948DD6548AA7C9D80 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (GNU/Linux) Comment: Using GnuPG with SUSE - http://enigmail.mozdev.org iEYEARECAAYFAkv8zQEACgkQitSsb3rl5xRMnACfY+JioXJKAjiHLshJ741k8kbG Q9AAoOPe1xjyY9MaFXTrumld/sv3t/GT =8BL5 -----END PGP SIGNATURE----- --------------enig2D4CF80948DD6548AA7C9D80--