Message ID | 20090526115252.3362.67189.stgit@mchn012c.ww002.siemens.net (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Jan Kiszka wrote: > Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> > --- > > x86/external-module-compat.h | 8 ++++++++ > 1 files changed, 8 insertions(+), 0 deletions(-) > > diff --git a/x86/external-module-compat.h b/x86/external-module-compat.h > index c33eb2e..cc984ab 100644 > --- a/x86/external-module-compat.h > +++ b/x86/external-module-compat.h > @@ -540,3 +540,11 @@ struct mtrr_state_type { > #ifndef CONFIG_HAVE_KVM_IRQCHIP > #define CONFIG_HAVE_KVM_IRQCHIP 1 > #endif > + > +#ifndef MCG_CTL_P > +#define MCG_CTL_P (1ULL<<8) > +#define MCG_STATUS_MCIP (1ULL<<2) > +#define MCI_STATUS_VAL (1ULL<<63) > +#define MCI_STATUS_OVER (1ULL<<62) > +#define MCI_STATUS_UC (1ULL<<61) > +#endif > > This breaks on recent kernels (redefinition), so I removed it. Suggest adding an include-compat/asm-x86/asm/mce.h and including that.
Avi Kivity wrote: > Jan Kiszka wrote: >> Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> >> --- >> >> x86/external-module-compat.h | 8 ++++++++ >> 1 files changed, 8 insertions(+), 0 deletions(-) >> >> diff --git a/x86/external-module-compat.h b/x86/external-module-compat.h >> index c33eb2e..cc984ab 100644 >> --- a/x86/external-module-compat.h >> +++ b/x86/external-module-compat.h >> @@ -540,3 +540,11 @@ struct mtrr_state_type { >> #ifndef CONFIG_HAVE_KVM_IRQCHIP >> #define CONFIG_HAVE_KVM_IRQCHIP 1 >> #endif >> + >> +#ifndef MCG_CTL_P >> +#define MCG_CTL_P (1ULL<<8) >> +#define MCG_STATUS_MCIP (1ULL<<2) >> +#define MCI_STATUS_VAL (1ULL<<63) >> +#define MCI_STATUS_OVER (1ULL<<62) >> +#define MCI_STATUS_UC (1ULL<<61) >> +#endif >> >> > > This breaks on recent kernels (redefinition), so I removed it. Suggest > adding an include-compat/asm-x86/asm/mce.h and including that. Non-empty mce.h will not work (but a patch to add an empty one was missing from my queue) - new kernel have that file, but with improper definitions for 32-bit. But what was that recent kernel and what was the precise problem? ATM I could only imagine that the block above is included before original mce.h, right? Then adding an explicit include here should cure the problem. Jan
Jan Kiszka wrote: >>> + >>> +#ifndef MCG_CTL_P >>> +#define MCG_CTL_P (1ULL<<8) >>> +#define MCG_STATUS_MCIP (1ULL<<2) >>> +#define MCI_STATUS_VAL (1ULL<<63) >>> +#define MCI_STATUS_OVER (1ULL<<62) >>> +#define MCI_STATUS_UC (1ULL<<61) >>> +#endif >>> >>> >>> >> This breaks on recent kernels (redefinition), so I removed it. Suggest >> adding an include-compat/asm-x86/asm/mce.h and including that. >> > > Non-empty mce.h will not work (but a patch to add an empty one was > missing from my queue) - new kernel have that file, but with improper > definitions for 32-bit. But what was that recent kernel and what was the > precise problem? 2.6.27, those defines were redefined (by the subsequent include of mce.h) > ATM I could only imagine that the block above is > included before original mce.h, right? Then adding an explicit include > here should cure the problem. > Yes.
diff --git a/x86/external-module-compat.h b/x86/external-module-compat.h index c33eb2e..cc984ab 100644 --- a/x86/external-module-compat.h +++ b/x86/external-module-compat.h @@ -540,3 +540,11 @@ struct mtrr_state_type { #ifndef CONFIG_HAVE_KVM_IRQCHIP #define CONFIG_HAVE_KVM_IRQCHIP 1 #endif + +#ifndef MCG_CTL_P +#define MCG_CTL_P (1ULL<<8) +#define MCG_STATUS_MCIP (1ULL<<2) +#define MCI_STATUS_VAL (1ULL<<63) +#define MCI_STATUS_OVER (1ULL<<62) +#define MCI_STATUS_UC (1ULL<<61) +#endif
Signed-off-by: Jan Kiszka <jan.kiszka@siemens.com> --- x86/external-module-compat.h | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html