Skip to contentSkip to conversation

KVM: arm/arm64: arch_timer: remove unused error handling

PATCH In review Arnd Bergmann 2 participants 2 messages Sep 8, 2016

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 KVM: arm/arm64: arch_timer: remove unused error handling

A cleanup removed the call to create_singlethread_workqueue(), but did not remove the code that was used in case it failed:

virt/kvm/arm/arch_timer.c: In function 'kvm_timer_hyp_init':
virt/kvm/arm/arch_timer.c:457:1: error: label 'out_free' defined but not used [-Werror=unused-label]

This removes the now dead code too.

Fixes 3706feacd007 ("KVM: Remove deprecated create_singlethread_workqueue")
---
 virt/kvm/arm/arch_timer.c | 3 ---
 1 file changed, 3 deletions(-)
virt/kvm/arm/arch_timer.c +0 -3
index 4309b60ebf17..46980a49a3bb 100644
@@ -453,9 +453,6 @@ int kvm_timer_hyp_init(void)
 	cpuhp_setup_state(CPUHP_AP_KVM_ARM_TIMER_STARTING,
 			  "AP_KVM_ARM_TIMER_STARTING", kvm_timer_starting_cpu,
 			  kvm_timer_dying_cpu);
-	goto out;
-out_free:
-	free_percpu_irq(host_vtimer_irq, kvm_get_running_vcpus());
 out:
 	return err;
 }
Signature · 1 line
2.9.0
#1 lore raw

Hi Arnd,

Quoted 7 lines · Arnd Bergmann

A cleanup removed the call to create_singlethread_workqueue(), but did not remove the code that was used in case it failed:

virt/kvm/arm/arch_timer.c: In function 'kvm_timer_hyp_init':
virt/kvm/arm/arch_timer.c:457:1: error: label 'out_free' defined but not used [-Werror=unused-label]

This removes the now dead code too.

Paolo beat you to it:
https://lists.cs.columbia.edu/pipermail/kvmarm/2016-September/021626.html

Thanks,
-Christoffer

Quoted 24 lines
Fixes 3706feacd007 ("KVM: Remove deprecated create_singlethread_workqueue")
---
 virt/kvm/arm/arch_timer.c | 3 ---
 1 file changed, 3 deletions(-)
virt/kvm/arm/arch_timer.c +0 -3
index 4309b60ebf17..46980a49a3bb 100644
@@ -453,9 +453,6 @@ int kvm_timer_hyp_init(void)
 	cpuhp_setup_state(CPUHP_AP_KVM_ARM_TIMER_STARTING,
 			  "AP_KVM_ARM_TIMER_STARTING", kvm_timer_starting_cpu,
 			  kvm_timer_dying_cpu);
-	goto out;
-out_free:
-	free_percpu_irq(host_vtimer_irq, kvm_get_running_vcpus());
 out:
 	return err;
 }
Signature · 1 line
2.9.0