public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c
@ 2008-11-20  2:43 Zhang, Xiantao
  2008-11-20 10:50 ` Avi Kivity
  0 siblings, 1 reply; 7+ messages in thread
From: Zhang, Xiantao @ 2008-11-20  2:43 UTC (permalink / raw)
  To: kvm-ia64@vger.kernel.org, Avi Kivity; +Cc: kvm@vger.kernel.org

[-- Attachment #1: Type: text/plain, Size: 1045 bytes --]

Hi, Avi 
	Please apply the patch and queue it as 2.6.28 fix. Thanks!
Xiantao

>From d759572033e1bf0e4ca6b7d8f7be8e8387fb4bbb Mon Sep 17 00:00:00 2001
From: Xiantao Zhang <xiantao.zhang@intel.com>
Date: Thu, 20 Nov 2008 10:35:35 +0800
Subject: [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c

EXTRA_CFLAGS doesn't work for this case.
Signed-off-by: Xiantao Zhang <xiantao.zhang@intel.com>
---
 arch/ia64/kvm/Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/ia64/kvm/Makefile b/arch/ia64/kvm/Makefile
index 3ab4d6d..92cef66 100644
--- a/arch/ia64/kvm/Makefile
+++ b/arch/ia64/kvm/Makefile
@@ -58,7 +58,7 @@ endif
 kvm-objs := $(common-objs) kvm-ia64.o kvm_fw.o
 obj-$(CONFIG_KVM) += kvm.o
 
-EXTRA_CFLAGS_vcpu.o += -mfixed-range=f2-f5,f12-f127
+CFLAGS_vcpu.o += -mfixed-range=f2-f5,f12-f127
 kvm-intel-objs = vmm.o vmm_ivt.o trampoline.o vcpu.o optvfault.o mmio.o \
 	vtlb.o process.o
 #Add link memcpy and memset to avoid possible structure assignment error
-- 
1.6.0

[-- Attachment #2: 0001-KVM-IA64-Using-CFLAGS_vcpu.o-to-compile-vcpu.c.patch --]
[-- Type: application/octet-stream, Size: 937 bytes --]

From d759572033e1bf0e4ca6b7d8f7be8e8387fb4bbb Mon Sep 17 00:00:00 2001
From: Xiantao Zhang <xiantao.zhang@intel.com>
Date: Thu, 20 Nov 2008 10:35:35 +0800
Subject: [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c

EXTRA_CFLAGS doesn't work for this case.
Signed-off-by: Xiantao Zhang <xiantao.zhang@intel.com>
---
 arch/ia64/kvm/Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/ia64/kvm/Makefile b/arch/ia64/kvm/Makefile
index 3ab4d6d..92cef66 100644
--- a/arch/ia64/kvm/Makefile
+++ b/arch/ia64/kvm/Makefile
@@ -58,7 +58,7 @@ endif
 kvm-objs := $(common-objs) kvm-ia64.o kvm_fw.o
 obj-$(CONFIG_KVM) += kvm.o
 
-EXTRA_CFLAGS_vcpu.o += -mfixed-range=f2-f5,f12-f127
+CFLAGS_vcpu.o += -mfixed-range=f2-f5,f12-f127
 kvm-intel-objs = vmm.o vmm_ivt.o trampoline.o vcpu.o optvfault.o mmio.o \
 	vtlb.o process.o
 #Add link memcpy and memset to avoid possible structure assignment error
-- 
1.6.0


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c
  2008-11-20  2:43 [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c Zhang, Xiantao
@ 2008-11-20 10:50 ` Avi Kivity
  2008-11-20 11:03   ` Zhang, Xiantao
  0 siblings, 1 reply; 7+ messages in thread
From: Avi Kivity @ 2008-11-20 10:50 UTC (permalink / raw)
  To: Zhang, Xiantao; +Cc: kvm-ia64@vger.kernel.org, kvm@vger.kernel.org

Zhang, Xiantao wrote:
> Hi, Avi 
> 	Please apply the patch and queue it as 2.6.28 fix. Thanks!
> Xiantao
>
> From d759572033e1bf0e4ca6b7d8f7be8e8387fb4bbb Mon Sep 17 00:00:00 2001
> From: Xiantao Zhang <xiantao.zhang@intel.com>
> Date: Thu, 20 Nov 2008 10:35:35 +0800
> Subject: [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c
>
> EXTRA_CFLAGS doesn't work for this case.
>   

Can you provide more information on how this was only discovered now?  
Was there a change in mainline that removed support for EXTRA_CFLAGS?


-- 
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* RE: [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c
  2008-11-20 10:50 ` Avi Kivity
@ 2008-11-20 11:03   ` Zhang, Xiantao
  2008-11-20 11:05     ` Avi Kivity
  0 siblings, 1 reply; 7+ messages in thread
From: Zhang, Xiantao @ 2008-11-20 11:03 UTC (permalink / raw)
  To: Avi Kivity; +Cc: kvm-ia64@vger.kernel.org, kvm@vger.kernel.org

Avi Kivity wrote:
> Zhang, Xiantao wrote:
>> Hi, Avi
>> 	Please apply the patch and queue it as 2.6.28 fix. Thanks!
>> Xiantao
>> 
>> From d759572033e1bf0e4ca6b7d8f7be8e8387fb4bbb Mon Sep 17 00:00:00
>> 2001 From: Xiantao Zhang <xiantao.zhang@intel.com>
>> Date: Thu, 20 Nov 2008 10:35:35 +0800
>> Subject: [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c
>> 
>> EXTRA_CFLAGS doesn't work for this case.
>> 
> 
> Can you provide more information on how this was only discovered now?
> Was there a change in mainline that removed support for EXTRA_CFLAGS?]
It should be an old issue we didn't sense before.  To specify single object's compile option, only CFLAGS can work in this case. 
Xiantao

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c
  2008-11-20 11:03   ` Zhang, Xiantao
@ 2008-11-20 11:05     ` Avi Kivity
  2008-11-20 11:54       ` Zhang, Xiantao
  0 siblings, 1 reply; 7+ messages in thread
From: Avi Kivity @ 2008-11-20 11:05 UTC (permalink / raw)
  To: Zhang, Xiantao; +Cc: kvm-ia64@vger.kernel.org, kvm@vger.kernel.org

Zhang, Xiantao wrote:
>> Can you provide more information on how this was only discovered now?
>> Was there a change in mainline that removed support for EXTRA_CFLAGS?]
>>     
> It should be an old issue we didn't sense before.  To specify single object's compile option, only CFLAGS can work in this case. 

How did we not notice the issue?  What is the effect of the missing flags?

It seems like a critical problem that should prevent kvm from working at 
all, so I don't understand how it was discovered so late.

-- 
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* RE: [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c
  2008-11-20 11:05     ` Avi Kivity
@ 2008-11-20 11:54       ` Zhang, Xiantao
  2008-11-20 12:23         ` Avi Kivity
  0 siblings, 1 reply; 7+ messages in thread
From: Zhang, Xiantao @ 2008-11-20 11:54 UTC (permalink / raw)
  To: Avi Kivity; +Cc: kvm-ia64@vger.kernel.org, kvm@vger.kernel.org

[-- Attachment #1: Type: text/plain, Size: 1947 bytes --]

Avi Kivity wrote:
> Zhang, Xiantao wrote:
>>> Can you provide more information on how this was only discovered
>>> now? Was there a change in mainline that removed support for
>>> EXTRA_CFLAGS?] 
>>> 
>> It should be an old issue we didn't sense before.  To specify single
>> object's compile option, only CFLAGS can work in this case. 
> 
> How did we not notice the issue?  What is the effect of the missing
> flags? 
> It seems like a critical problem that should prevent kvm from working
> at all, so I don't understand how it was discovered so late.

Once missing this flags, compiler can touch the fixed registers and leads to faults. But fortunately,current gcc didn't use them for optimizations, so we didn't find it before. But anyway it should be a potential issue. 
Updated one, remove kernel's default range. 

>From 451ce36037cb1075c572de42d9ad9c4c7ee863e4 Mon Sep 17 00:00:00 2001
From: Xiantao Zhang <xiantao.zhang@intel.com>
Date: Thu, 20 Nov 2008 19:49:00 +0800
Subject: [PATCH] KVM: ia64: Fix: Use CFLAGS_vcpu.o to compile vcpu.c

EXTRA_CFLAGS doesn't work for this case.Without this flag,
it may result in compiler touch fixed registers.

Signed-off-by: Xiantao Zhang <xiantao.zhang@intel.com>
---
 arch/ia64/kvm/Makefile |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/arch/ia64/kvm/Makefile b/arch/ia64/kvm/Makefile
index 3ab4d6d..603e53c 100644
--- a/arch/ia64/kvm/Makefile
+++ b/arch/ia64/kvm/Makefile
@@ -58,7 +58,8 @@ endif
 kvm-objs := $(common-objs) kvm-ia64.o kvm_fw.o
 obj-$(CONFIG_KVM) += kvm.o
 
-EXTRA_CFLAGS_vcpu.o += -mfixed-range=f2-f5,f12-f127
+CFLAGS_REMOVE_vcpu.o += -mfixed-range=f12-f15,f32-f127
+CFLAGS_vcpu.o += -mfixed-range=f2-f5,f12-f127
 kvm-intel-objs = vmm.o vmm_ivt.o trampoline.o vcpu.o optvfault.o mmio.o \
 	vtlb.o process.o
 #Add link memcpy and memset to avoid possible structure assignment error
-- 
1.6.0


Xiantao

[-- Attachment #2: 0001-KVM-ia64-Fix-Use-CFLAGS_vcpu.o-to-compile-vcpu.c.patch --]
[-- Type: application/octet-stream, Size: 1065 bytes --]

From 451ce36037cb1075c572de42d9ad9c4c7ee863e4 Mon Sep 17 00:00:00 2001
From: Xiantao Zhang <xiantao.zhang@intel.com>
Date: Thu, 20 Nov 2008 19:49:00 +0800
Subject: [PATCH] KVM: ia64: Fix: Use CFLAGS_vcpu.o to compile vcpu.c

EXTRA_CFLAGS doesn't work for this case.Without this flag,
it may result in compiler touch fixed registers.

Signed-off-by: Xiantao Zhang <xiantao.zhang@intel.com>
---
 arch/ia64/kvm/Makefile |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/arch/ia64/kvm/Makefile b/arch/ia64/kvm/Makefile
index 3ab4d6d..603e53c 100644
--- a/arch/ia64/kvm/Makefile
+++ b/arch/ia64/kvm/Makefile
@@ -58,7 +58,8 @@ endif
 kvm-objs := $(common-objs) kvm-ia64.o kvm_fw.o
 obj-$(CONFIG_KVM) += kvm.o
 
-EXTRA_CFLAGS_vcpu.o += -mfixed-range=f2-f5,f12-f127
+CFLAGS_REMOVE_vcpu.o += -mfixed-range=f12-f15,f32-f127
+CFLAGS_vcpu.o += -mfixed-range=f2-f5,f12-f127
 kvm-intel-objs = vmm.o vmm_ivt.o trampoline.o vcpu.o optvfault.o mmio.o \
 	vtlb.o process.o
 #Add link memcpy and memset to avoid possible structure assignment error
-- 
1.6.0


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c
  2008-11-20 11:54       ` Zhang, Xiantao
@ 2008-11-20 12:23         ` Avi Kivity
  2008-11-20 15:04           ` Zhang, Xiantao
  0 siblings, 1 reply; 7+ messages in thread
From: Avi Kivity @ 2008-11-20 12:23 UTC (permalink / raw)
  To: Zhang, Xiantao; +Cc: kvm-ia64@vger.kernel.org, kvm@vger.kernel.org

Zhang, Xiantao wrote:
> Avi Kivity wrote:
>   
>> Zhang, Xiantao wrote:
>>     
>>>> Can you provide more information on how this was only discovered
>>>> now? Was there a change in mainline that removed support for
>>>> EXTRA_CFLAGS?] 
>>>>
>>>>         
>>> It should be an old issue we didn't sense before.  To specify single
>>> object's compile option, only CFLAGS can work in this case. 
>>>       
>> How did we not notice the issue?  What is the effect of the missing
>> flags? 
>> It seems like a critical problem that should prevent kvm from working
>> at all, so I don't understand how it was discovered so late.
>>     
>
> Once missing this flags, compiler can touch the fixed registers and leads to faults. But fortunately,current gcc didn't use them for optimizations, so we didn't find it before. But anyway it should be a potential issue. 
> Updated one, remove kernel's default range. 
>
>   

Okay, so it worked by accident?

> Subject: [PATCH] KVM: ia64: Fix: Use CFLAGS_vcpu.o to compile vcpu.c
>
> EXTRA_CFLAGS doesn't work for this case.Without this flag,
> it may result in compiler touch fixed registers.
>   

Applied, thanks.

-- 
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.


^ permalink raw reply	[flat|nested] 7+ messages in thread

* RE: [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c
  2008-11-20 12:23         ` Avi Kivity
@ 2008-11-20 15:04           ` Zhang, Xiantao
  0 siblings, 0 replies; 7+ messages in thread
From: Zhang, Xiantao @ 2008-11-20 15:04 UTC (permalink / raw)
  To: Avi Kivity; +Cc: kvm-ia64@vger.kernel.org, kvm@vger.kernel.org

Avi Kivity wrote:
> Zhang, Xiantao wrote:
>> Avi Kivity wrote:
>> 
>>> Zhang, Xiantao wrote:
>>> 
>>>>> Can you provide more information on how this was only discovered
>>>>> now? Was there a change in mainline that removed support for
>>>>> EXTRA_CFLAGS?] 
>>>>> 
>>>>> 
>>>> It should be an old issue we didn't sense before.  To specify
>>>> single object's compile option, only CFLAGS can work in this case.
>>>> 
>>> How did we not notice the issue?  What is the effect of the missing
>>> flags? It seems like a critical problem that should prevent kvm
>>> from working at all, so I don't understand how it was discovered so
>>> late. 
>>> 
>> 
>> Once missing this flags, compiler can touch the fixed registers and
>> leads to faults. But fortunately,current gcc didn't use them for
>> optimizations, so we didn't find it before. But anyway it should be
>> a potential issue. Updated one, remove kernel's default range.  
>> 
>> 
> 
> Okay, so it worked by accident?

At least we didn't meet explict issue was caused by it. But anyway, it may bite us with the changes of compiler or compiler's configuration.  

>> Subject: [PATCH] KVM: ia64: Fix: Use CFLAGS_vcpu.o to compile vcpu.c
>> 
>> EXTRA_CFLAGS doesn't work for this case.Without this flag,
>> it may result in compiler touch fixed registers.
>> 
> 
> Applied, thanks.


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2008-11-20 15:04 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-20  2:43 [PATCH] KVM: IA64: Using CFLAGS_vcpu.o to compile vcpu.c Zhang, Xiantao
2008-11-20 10:50 ` Avi Kivity
2008-11-20 11:03   ` Zhang, Xiantao
2008-11-20 11:05     ` Avi Kivity
2008-11-20 11:54       ` Zhang, Xiantao
2008-11-20 12:23         ` Avi Kivity
2008-11-20 15:04           ` Zhang, Xiantao

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox