On Thu, 2006-08-10 at 21:35 +0200, Andi Kleen wrote:
> --- linux.orig/include/asm-i386/mach-summit/mach_apic.h
> +++ linux/include/asm-i386/mach-summit/mach_apic.h
> @@ -46,10 +46,12 @@ extern u8 cpu_2_logical_apicid[];
> static inline void init_apic_ldr(void)
> {
> unsigned long val, id;
> - int i, count;
> - u8 lid;
> + int count = 0;
> u8 my_id = (u8)hard_smp_processor_id();
> u8 my_cluster = (u8)apicid_cluster(my_id);
> +#ifdef CONFIG_SMP
> + u8 lid;
> + int i;
>
> /* Create logical APIC IDs by counting CPUs already in cluster. */
> for (count = 0, i = NR_CPUS; --i >= 0; ) {
> @@ -57,6 +59,7 @@ static inline void init_apic_ldr(void)
> if (lid != BAD_APICID && apicid_cluster(lid) == my_cluster)
> ++count;
> }
> +#endif
Why does this particular loop have to go? I'm sure it's OK, but I also
wonder if there is a nice way to do it without the #ifdef.
-- Dave
-
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]