[2.6 patch] x86_64 __setup_APIC_LVTT(): remove unused variable

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Nov 21, 2006 at 07:46:46PM +0000, d binderman wrote:
> 
> Hello there,
> 
> I just tried to compile Linux kernel 2.6.18.3 with the Intel C
> C compiler.
> 
> The compiler said
> 
> arch/x86_64/kernel/apic.c(701): remark #593: variable "ver" was set but 
> never used
> 
> The source code is
> 
>    unsigned int lvtt_value, tmp_value, ver;
> 
> I have checked the source code and I agree with the compiler.
> Suggest delete local variable.

Thanks for your report, patch below.

> Regards
> 
> David Binderman

cu
Adrian


<--  snip  -->


This patch removes a variable that whose usage was removed some time ago 
by Andi.

Spotted by the Intel C compiler.

Reported by David Binderman.

Signed-off-by: Adrian Bunk <[email protected]>

--- linux-2.6.19-rc5-mm2/arch/x86_64/kernel/apic.c.old	2006-11-21 21:17:03.000000000 +0100
+++ linux-2.6.19-rc5-mm2/arch/x86_64/kernel/apic.c	2006-11-21 21:17:16.000000000 +0100
@@ -722,10 +722,9 @@
 
 static void __setup_APIC_LVTT(unsigned int clocks)
 {
-	unsigned int lvtt_value, tmp_value, ver;
+	unsigned int lvtt_value, tmp_value;
 	int cpu = smp_processor_id();
 
-	ver = GET_APIC_VERSION(apic_read(APIC_LVR));
 	lvtt_value = APIC_LVT_TIMER_PERIODIC | LOCAL_TIMER_VECTOR;
 
 	if (cpu_isset(cpu, timer_interrupt_broadcast_ipi_mask))

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

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux