提交 a0854600 编写于 作者: H Harvey Harrison 提交者: Avi Kivity

x86: pvclock: fix shadowed variable warning

arch/x86/kernel/pvclock.c:102:6: warning: symbol 'tsc_khz' shadows an earlier one
include/asm/tsc.h:18:21: originally declared here
Signed-off-by: NHarvey Harrison <harvey.harrison@gmail.com>
Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: NAvi Kivity <avi@redhat.com>
上级 1f095610
......@@ -99,14 +99,14 @@ static unsigned pvclock_get_time_values(struct pvclock_shadow_time *dst,
unsigned long pvclock_tsc_khz(struct pvclock_vcpu_time_info *src)
{
u64 tsc_khz = 1000000ULL << 32;
u64 pv_tsc_khz = 1000000ULL << 32;
do_div(tsc_khz, src->tsc_to_system_mul);
do_div(pv_tsc_khz, src->tsc_to_system_mul);
if (src->tsc_shift < 0)
tsc_khz <<= -src->tsc_shift;
pv_tsc_khz <<= -src->tsc_shift;
else
tsc_khz >>= src->tsc_shift;
return tsc_khz;
pv_tsc_khz >>= src->tsc_shift;
return pv_tsc_khz;
}
cycle_t pvclock_clocksource_read(struct pvclock_vcpu_time_info *src)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册