x86/kvm: Fix compile warning in kvm_register_steal_time()
Subsystems (2)
PATCH 1/1 x86/kvm: Fix compile warning in kvm_register_steal_time()
Fix the following compile warning in kvm_register_steal_time():
CC arch/x86/kernel/kvm.oarch/x86/kernel/kvm.c: In function ‘kvm_register_steal_time’:arch/x86/kernel/kvm.c:302:3: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘phys_addr_t’ [-Wformat]
--- arch/x86/kernel/kvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/kernel/kvm.c +2 -2
@@ -298,8 +298,8 @@ static void kvm_register_steal_time(void)memset (st,0 ,sizeof (*st));wrmsrl (MSR_KVM_STEAL_TIME , (slow_virt_to_phys (st) |KVM_MSR_ENABLED )); -printk (KERN_INFO "kvm-stealtime: cpu %d, msr %lx\n" , - cpu,slow_virt_to_phys (st)); +pr_info ("kvm-stealtime: cpu %d, msr %llx\n" , + cpu, (unsigned long long )slow_virt_to_phys (st)); } static DEFINE_PER_CPU(unsigned long, kvm_apic_eoi) = KVM_PV_EOI_DISABLED;
Signature · 1 line
1.7.9.5
Quoted 5 lines · Shuah Khan
Fix the following compile warning in
kvm_register_steal_time():
CCarch/x86/kernel/kvm.oarch/x86/kernel/kvm.c: In function ‘kvm_register_steal_time’:arch/x86/kernel/kvm.c:302:3: warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘phys_addr_t’ [-Wformat]
Ingo, the warning is from the tip tree. Can you take the fix?
Quoted 24 lines
Signed-off-by Shuah Khan <[email protected]>--- arch/x86/kernel/kvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)arch/x86/kernel/kvm.c +2
-2@@ -298,8 +298,8 @@ static void kvm_register_steal_time(void)memset (st,0 ,sizeof (*st));wrmsrl (MSR_KVM_STEAL_TIME , (slow_virt_to_phys (st) |KVM_MSR_ENABLED )); -printk (KERN_INFO "kvm-stealtime: cpu %d, msr %lx\n" , - cpu,slow_virt_to_phys (st)); +pr_info ("kvm-stealtime: cpu %d, msr %llx\n" , + cpu, (unsigned long long )slow_virt_to_phys (st)); } static DEFINE_PER_CPU(unsigned long, kvm_apic_eoi) = KVM_PV_EOI_DISABLED;Signature · 1 line
1.7.9.5
--
Gleb.
Quoted 7 lines · Gleb Natapov
Quoted 5 lines · Shuah Khan
Fix the following compile warning in
kvm_register_steal_time():
CCarch/x86/kernel/kvm.oarch/x86/kernel/kvm.c: In function ?kvm_register_steal_time?:arch/x86/kernel/kvm.c:302:3: warning: format ?%lx? expects argument of type ?long unsigned int?, but argument 3 has type ?phys_addr_t? [-Wformat]Ingo, the warning is from the tip tree. Can you take the fix?
Yeah, it came via these x86 improvements to __pa():
5dfd486c4750 x86, kvm: Fix kvm's use of __pa() on percpu areas d76565344512 x86, mm: Create slow_virt_to_phys()f3c4fbb68e93 x86, mm: Use new pagetable helpers in try_preserve_large_page() 4cbeb51b860c x86, mm: Pagetable level size/shift/mask helpers a25b9316841c x86, mm: Make DEBUG_VIRTUAL work earlier in boot
So up the fix - I added an Acked-by from you as well, is that fine with you?
Thanks,
Ingo
Quoted 13 lines · Ingo Molnar
Quoted 7 lines · Gleb Natapov
Quoted 5 lines · Shuah Khan
Fix the following compile warning in
kvm_register_steal_time():
CCarch/x86/kernel/kvm.oarch/x86/kernel/kvm.c: In function ?kvm_register_steal_time?:arch/x86/kernel/kvm.c:302:3: warning: format ?%lx? expects argument of type ?long unsigned int?, but argument 3 has type ?phys_addr_t? [-Wformat]Ingo, the warning is from the tip tree. Can you take the fix?
Yeah, it came via these x86 improvements to
__pa():
Quoted 9 lines
5dfd486c4750x86, kvm: Fix kvm's use of__pa()on percpu areasd76565344512x86, mm: Createslow_virt_to_phys()f3c4fbb68e93x86, mm: Use new pagetable helpers intry_preserve_large_page()4cbeb51b860cx86, mm: Pagetable level size/shift/mask helpersa25b9316841cx86, mm: MakeDEBUG_VIRTUALwork earlier in bootSo up the fix - I added an Acked-by from you as well, is that fine with you?
Yes, of course. Thank you.
--
Gleb.
Quoted 13 lines · Ingo Molnar
Quoted 7 lines · Gleb Natapov
Quoted 5 lines · Shuah Khan
Fix the following compile warning in
kvm_register_steal_time():
CCarch/x86/kernel/kvm.oarch/x86/kernel/kvm.c: In function ?kvm_register_steal_time?:arch/x86/kernel/kvm.c:302:3: warning: format ?%lx? expects argument of type ?long unsigned int?, but argument 3 has type ?phys_addr_t? [-Wformat]Ingo, the warning is from the tip tree. Can you take the fix?
Yeah, it came via these x86 improvements to
__pa():
Quoted 7 lines
5dfd486c4750x86, kvm: Fix kvm's use of__pa()on percpu areasd76565344512x86, mm: Createslow_virt_to_phys()f3c4fbb68e93x86, mm: Use new pagetable helpers intry_preserve_large_page()4cbeb51b860cx86, mm: Pagetable level size/shift/mask helpersa25b9316841cx86, mm: MakeDEBUG_VIRTUALwork earlier in bootSo up the fix - I added an Acked-by from you as well, is that
s/So I applied the fix
Thanks,
Ingo
Commit-ID: 136867f517cbc3f8a91f035677911a6b503c3323 Gitweb: http://git.kernel.org/tip/136867f517cbc3f8a91f035677911a6b503c3323 Author: Shuah Khan <[email protected]> AuthorDate: Tue, 5 Feb 2013 19:57:22 -0700 Committer: Ingo Molnar <[email protected]> CommitDate: Mon, 11 Feb 2013 11:04:31 +0100
x86/kvm: Fix compile warning in kvm_register_steal_time()
Fix the following compile warning in kvm_register_steal_time():
CC arch/x86/kernel/kvm.o
arch/x86/kernel/kvm.c: In function ‘kvm_register_steal_time’: arch/x86/kernel/kvm.c:302:3:
warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘phys_addr_t’ [-Wformat]
Introduced via:
5dfd486c4750 x86, kvm: Fix kvm's use of __pa() on percpu areas d76565344512 x86, mm: Create slow_virt_to_phys()
f3c4fbb68e93 x86, mm: Use new pagetable helpers in try_preserve_large_page() 4cbeb51b860c x86, mm: Pagetable level size/shift/mask helpers a25b9316841c x86, mm: Make DEBUG_VIRTUAL work earlier in boot
--- arch/x86/kernel/kvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/kernel/kvm.c +2 -2
@@ -298,8 +298,8 @@ static void kvm_register_steal_time(void)memset (st,0 ,sizeof (*st));wrmsrl (MSR_KVM_STEAL_TIME , (slow_virt_to_phys (st) |KVM_MSR_ENABLED )); -printk (KERN_INFO "kvm-stealtime: cpu %d, msr %lx\n" , - cpu,slow_virt_to_phys (st)); +pr_info ("kvm-stealtime: cpu %d, msr %llx\n" , + cpu, (unsigned long long )slow_virt_to_phys (st)); } static DEFINE_PER_CPU(unsigned long, kvm_apic_eoi) = KVM_PV_EOI_DISABLED;
Borislav Petkov
maintainerQuoted 43 lines · tip-bot for Shuah Khan
Commit-ID: 136867f517cbc3f8a91f035677911a6b503c3323 Gitweb: http://git.kernel.org/tip/136867f517cbc3f8a91f035677911a6b503c3323 Author: Shuah Khan <[email protected]> AuthorDate: Tue, 5 Feb 2013 19:57:22 -0700 Committer: Ingo Molnar <[email protected]> CommitDate: Mon, 11 Feb 2013 11:04:31 +0100x86/kvm: Fix compile warning in
kvm_register_steal_time()Fix the following compile warning in
kvm_register_steal_time():CC
arch/x86/kernel/kvm.o
arch/x86/kernel/kvm.c: In function ‘kvm_register_steal_time’:arch/x86/kernel/kvm.c:302:3:
warning: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 3 has type ‘phys_addr_t’ [-Wformat]Introduced via:
5dfd486c4750x86, kvm: Fix kvm's use of__pa()on percpu areasd76565344512x86, mm: Createslow_virt_to_phys()
f3c4fbb68e93x86, mm: Use new pagetable helpers intry_preserve_large_page()4cbeb51b860cx86, mm: Pagetable level size/shift/mask helpersa25b9316841cx86, mm: MakeDEBUG_VIRTUALwork earlier in bootSigned-off-by Shuah Khan <[email protected]>Acked-by Gleb Natapov <[email protected]>Cc Marcelo Tosatti <[email protected]>Cc Dave Hansen <[email protected]>Cc Rik van Riel <[email protected]>Signed-off-by Ingo Molnar <[email protected]>--- arch/x86/kernel/kvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)arch/x86/kernel/kvm.c +0
-0
arch/x86/kernel/kvm.c static void kvm_register_steal_time(void) · line 302
Quoted 7 lines
arch/x86/kernel/kvm.c +2
-2@@ -298,8 +298,8 @@ static void kvm_register_steal_time(void)memset (st,0 ,sizeof (*st));wrmsrl (MSR_KVM_STEAL_TIME , (slow_virt_to_phys (st) |KVM_MSR_ENABLED )); -printk (KERN_INFO "kvm-stealtime: cpu %d, msr %lx\n" , - cpu,slow_virt_to_phys (st)); +pr_info ("kvm-stealtime: cpu %d, msr %llx\n" , + cpu, (unsigned long long )slow_virt_to_phys (st));
I'm guessing this - like a bunch of other places in the kernel - should be converted to the new %pa printk format once the last has been merged:
http://marc.info/?l=linux-kernel&m=135883371328510&w=2
Signature · 5 lines
Regards/Gruss,
Boris.
Sent from a fat crate under my desk. Formatting is fine.
--