Re: [PATCH linux-next] x86/kvm: Fix compile warning inkvm_register_steal_time()

From: Gleb Natapov
Date: Mon Feb 11 2013 - 04:06:43 EST


On Tue, Feb 05, 2013 at 07:57:22PM -0700, Shuah Khan wrote:
> 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]
>
Ingo, the warning is from the tip tree. Can you take the fix?

> Signed-off-by: Shuah Khan <shuah.khan@xxxxxx>
> ---
> arch/x86/kernel/kvm.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/arch/x86/kernel/kvm.c b/arch/x86/kernel/kvm.c
> index fe75a28..b686a90 100644
> --- a/arch/x86/kernel/kvm.c
> +++ b/arch/x86/kernel/kvm.c
> @@ -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;
> --
> 1.7.9.5
>
>

--
Gleb.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/