Skip to content

Commit a3cf527

Browse files
chenhuacaibonzini
authored andcommitted
KVM: MIPS: Remove a "set but not used" variable
This fix a build warning: arch/mips/kvm/vz.c: In function '_kvm_vz_restore_htimer': >> arch/mips/kvm/vz.c:392:10: warning: variable 'freeze_time' set but not used [-Wunused-but-set-variable] 392 | ktime_t freeze_time; | ^~~~~~~~~~~ Reported-by: kernel test robot <lkp@intel.com> Signed-off-by: Huacai Chen <chenhuacai@loongson.cn> Message-Id: <20210406024911.2008046-1-chenhuacai@loongson.cn> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
1 parent e99314a commit a3cf527

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

arch/mips/kvm/vz.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -388,15 +388,14 @@ static void _kvm_vz_restore_htimer(struct kvm_vcpu *vcpu,
388388
u32 compare, u32 cause)
389389
{
390390
u32 start_count, after_count;
391-
ktime_t freeze_time;
392391
unsigned long flags;
393392

394393
/*
395394
* Freeze the soft-timer and sync the guest CP0_Count with it. We do
396395
* this with interrupts disabled to avoid latency.
397396
*/
398397
local_irq_save(flags);
399-
freeze_time = kvm_mips_freeze_hrtimer(vcpu, &start_count);
398+
kvm_mips_freeze_hrtimer(vcpu, &start_count);
400399
write_c0_gtoffset(start_count - read_c0_count());
401400
local_irq_restore(flags);
402401

0 commit comments

Comments
 (0)