* 1 Bug found for compiling on 32 Bit machine
@ 2007-05-21 7:47 Daniel Hecken
[not found] ` <46514E80.3080208-LcvzS2Pvy/8X0D0ZMPkEVw@public.gmane.org>
0 siblings, 1 reply; 5+ messages in thread
From: Daniel Hecken @ 2007-05-21 7:47 UTC (permalink / raw)
To: avi-atKUWr5tajBWk0Htik3J/w, eddie.dong-ral2JQCrhuEAvxtiuMwx3w
Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f
[-- Attachment #1: Type: text/plain, Size: 256 bytes --]
Hello,
I have found an issue for compiling on 32 Bit machines in
v2.6.22-rc1-g1ab29f3.
I'm not sure if I have set the #ifdef CONFIG_X86_64 at the right place.
Please have a look at it. With this patch v2.6.22-rc1-g1ab29f3 compiles
und runs fine.
Daniel
[-- Attachment #2: vmx_32bit.patch --]
[-- Type: text/x-diff, Size: 992 bytes --]
Signed-off-by: Daniel Hecken dh-LcvzS2Pvy/8X0D0ZMPkEVw@public.gmane.org
--- my-kvm-tree/drivers/kvm/vmx.c 2007-05-21 09:19:41.000000000 +0200
+++ kvm-trunk/kernel/vmx.c 2007-05-21 09:35:05.000000000 +0200
@@ -41,7 +41,10 @@
#else
#define HOST_IS_64 0
#endif
+
+#ifdef CONFIG_X86_64
#define EFER_SAVE_RESTORE_BITS ((u64)EFER_SCE)
+#endif
static struct vmcs_descriptor {
int size;
@@ -87,7 +90,9 @@
static inline u64 msr_efer_save_restore_bits(struct vmx_msr_entry msr)
{
+#ifdef CONFIG_X86_64
return (u64)msr.data & EFER_SAVE_RESTORE_BITS;
+#endif
}
static inline int msr_efer_need_save_restore(struct kvm_vcpu *vcpu)
@@ -279,6 +284,7 @@
static void load_transition_efer(struct kvm_vcpu *vcpu)
{
+#ifdef CONFIG_X86_64
u64 trans_efer;
int efer_offset = vcpu->msr_offset_efer;
@@ -288,6 +294,7 @@
vcpu->guest_msrs[efer_offset]);
wrmsrl(MSR_EFER, trans_efer);
vcpu->stat.efer_reload++;
+#endif
}
static void vmx_save_host_state(struct kvm_vcpu *vcpu)
[-- Attachment #3: Type: text/plain, Size: 286 bytes --]
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
[-- Attachment #4: Type: text/plain, Size: 186 bytes --]
_______________________________________________
kvm-devel mailing list
kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
https://lists.sourceforge.net/lists/listinfo/kvm-devel
^ permalink raw reply [flat|nested] 5+ messages in thread[parent not found: <46514E80.3080208-LcvzS2Pvy/8X0D0ZMPkEVw@public.gmane.org>]
* Re: 1 Bug found for compiling on 32 Bit machine [not found] ` <46514E80.3080208-LcvzS2Pvy/8X0D0ZMPkEVw@public.gmane.org> @ 2007-05-21 8:30 ` Avi Kivity [not found] ` <4651588A.1050808-atKUWr5tajBWk0Htik3J/w@public.gmane.org> 0 siblings, 1 reply; 5+ messages in thread From: Avi Kivity @ 2007-05-21 8:30 UTC (permalink / raw) To: Daniel Hecken; +Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f Daniel Hecken wrote: > Hello, > > I have found an issue for compiling on 32 Bit machines in > v2.6.22-rc1-g1ab29f3. > > I'm not sure if I have set the #ifdef CONFIG_X86_64 at the right place. > Please have a look at it. With this patch v2.6.22-rc1-g1ab29f3 compiles > und runs fine. > > v2.6.22-rc1-170-ga6935db compiles fine here. Can you double-check? -- error compiling committee.c: too many arguments to function ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ^ permalink raw reply [flat|nested] 5+ messages in thread
[parent not found: <4651588A.1050808-atKUWr5tajBWk0Htik3J/w@public.gmane.org>]
* Re: 1 Bug found for compiling on 32 Bit machine [not found] ` <4651588A.1050808-atKUWr5tajBWk0Htik3J/w@public.gmane.org> @ 2007-05-21 9:07 ` Daniel Hecken 2007-05-23 11:40 ` Daniel Hecken 1 sibling, 0 replies; 5+ messages in thread From: Daniel Hecken @ 2007-05-21 9:07 UTC (permalink / raw) To: Avi Kivity; +Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f Avi Kivity schrieb: > Daniel Hecken wrote: >> Hello, >> >> I have found an issue for compiling on 32 Bit machines in >> v2.6.22-rc1-g1ab29f3. >> >> I'm not sure if I have set the #ifdef CONFIG_X86_64 at the right place. >> Please have a look at it. With this patch v2.6.22-rc1-g1ab29f3 compiles >> und runs fine. >> >> > > v2.6.22-rc1-170-ga6935db compiles fine here. Can you double-check? > The warnings are gone, but mine only compiles with my patch. gcc is Version 3.4.6 included in Ubuntu Feisty. (Intel Core 2 Duo running 32 Bit Ubuntu Feisty with kernel 2.6.20-15) ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: 1 Bug found for compiling on 32 Bit machine [not found] ` <4651588A.1050808-atKUWr5tajBWk0Htik3J/w@public.gmane.org> 2007-05-21 9:07 ` Daniel Hecken @ 2007-05-23 11:40 ` Daniel Hecken [not found] ` <4654281D.10806-LcvzS2Pvy/8X0D0ZMPkEVw@public.gmane.org> 1 sibling, 1 reply; 5+ messages in thread From: Daniel Hecken @ 2007-05-23 11:40 UTC (permalink / raw) To: Avi Kivity; +Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f [-- Attachment #1: Type: text/plain, Size: 623 bytes --] Avi Kivity schrieb: > Daniel Hecken wrote: >> Hello, >> >> I have found an issue for compiling on 32 Bit machines in >> v2.6.22-rc1-g1ab29f3. >> >> I'm not sure if I have set the #ifdef CONFIG_X86_64 at the right place. >> Please have a look at it. With this patch v2.6.22-rc1-g1ab29f3 compiles >> und runs fine. >> >> > > v2.6.22-rc1-170-ga6935db compiles fine here. Can you double-check? > Hello Avi, as we discovered on IRC EFER_SCE is only defined below 2.6.22 in include/asm-i386/msr-index.h or include/asm-386/msr.h so I made a patch for external-module-compat.h. I hope I defined it in the right way. Daniel [-- Attachment #2: external-module-compat.patch --] [-- Type: text/x-diff, Size: 469 bytes --] --- kvm-trunk/kernel/external-module-compat.h 2007-05-23 13:28:47.000000000 +0200 +++ kvm-trunk_old/kernel/external-module-compat.h 2007-05-23 11:01:54.000000000 +0200 @@ -151,3 +151,17 @@ #define CPU_DEAD_FROZEN (CPU_DEAD | CPU_TASKS_FROZEN) #endif + +#if LINUX_VERSION_CODE < KERNEL_VERSION(2,6,22) + +#ifndef _EFER_SCE +#define _EFER_SCE 0 /* SYSCALL/SYSRET */ +#endif + +#ifndef EFER_SCE +#define EFER_SCE (1<<_EFER_SCE) +#endif + +#endif + + [-- Attachment #3: Type: text/plain, Size: 286 bytes --] ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ [-- Attachment #4: Type: text/plain, Size: 186 bytes --] _______________________________________________ kvm-devel mailing list kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org https://lists.sourceforge.net/lists/listinfo/kvm-devel ^ permalink raw reply [flat|nested] 5+ messages in thread
[parent not found: <4654281D.10806-LcvzS2Pvy/8X0D0ZMPkEVw@public.gmane.org>]
* Re: 1 Bug found for compiling on 32 Bit machine [not found] ` <4654281D.10806-LcvzS2Pvy/8X0D0ZMPkEVw@public.gmane.org> @ 2007-05-23 12:12 ` Avi Kivity 0 siblings, 0 replies; 5+ messages in thread From: Avi Kivity @ 2007-05-23 12:12 UTC (permalink / raw) To: Daniel Hecken; +Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f Daniel Hecken wrote: > Avi Kivity schrieb: > >> Daniel Hecken wrote: >> >>> Hello, >>> >>> I have found an issue for compiling on 32 Bit machines in >>> v2.6.22-rc1-g1ab29f3. >>> >>> I'm not sure if I have set the #ifdef CONFIG_X86_64 at the right place. >>> Please have a look at it. With this patch v2.6.22-rc1-g1ab29f3 compiles >>> und runs fine. >>> >>> >>> >> v2.6.22-rc1-170-ga6935db compiles fine here. Can you double-check? >> >> > > > Hello Avi, > > as we discovered on IRC EFER_SCE is only defined below 2.6.22 in > include/asm-i386/msr-index.h or include/asm-386/msr.h so I made a patch > for external-module-compat.h. I hope I defined it in the right way. > Looks good. Applied & thanks. -- Do not meddle in the internals of kernels, for they are subtle and quick to panic. ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2007-05-23 12:12 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-21 7:47 1 Bug found for compiling on 32 Bit machine Daniel Hecken
[not found] ` <46514E80.3080208-LcvzS2Pvy/8X0D0ZMPkEVw@public.gmane.org>
2007-05-21 8:30 ` Avi Kivity
[not found] ` <4651588A.1050808-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
2007-05-21 9:07 ` Daniel Hecken
2007-05-23 11:40 ` Daniel Hecken
[not found] ` <4654281D.10806-LcvzS2Pvy/8X0D0ZMPkEVw@public.gmane.org>
2007-05-23 12:12 ` Avi Kivity
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox