Skip to contentSkip to conversation

ARM: GIC: fix non-SMP builds

PATCH New Marek Szyprowski 3 participants 5 messages Jan 23, 2012 Arm (32-bit)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ARM: GIC: fix non-SMP builds

This patch fixes the build break introduced by commit db0d4db22. It happen only if SMP support has been disabled:

arch/arm/common/gic.c: In function 'gic_init_bases':
arch/arm/common/gic.c:679: error: implicit declaration of function 'cpu_logical_map' make[1]: *** [arch/arm/common/gic.o] Error 1
make: *** [arch/arm/common] Error 2

---
 arch/arm/common/gic.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
arch/arm/common/gic.c +4 -1
index b2dc2dd..1a29555 100644
@@ -676,7 +676,10 @@ void __init gic_init_bases(unsigned int gic_nr, int irq_start,
 		}
 
 		for_each_possible_cpu(cpu) {
-			unsigned long offset = percpu_offset * cpu_logical_map(cpu);
+			unsigned long offset = 0;
+#ifdef CONFIG_SMP
+			offset = percpu_offset * cpu_logical_map(cpu);
+#endif
 			*per_cpu_ptr(gic->dist_base.percpu_base, cpu) = dist_base + offset;
 			*per_cpu_ptr(gic->cpu_base.percpu_base, cpu) = cpu_base + offset;
 		}
Signature · 1 line
1.7.1.569.g6f426
#1 lore raw

PATCH 1/1 ARM: GIC: fix non-SMP builds

Quoted 10 lines · Marek Szyprowski

This patch fixes the build break introduced by commit db0d4db22. It happen only if SMP support has been disabled:

arch/arm/common/gic.c: In function 'gic_init_bases':
arch/arm/common/gic.c:679: error: implicit declaration of function 'cpu_logical_map' make[1]: *** [arch/arm/common/gic.o] Error 1
make: *** [arch/arm/common] Error 2

Please have a look at Will's patches:
http://patchwork.ozlabs.org/patch/136504/

which fix this problem in a far more elegant way.

	M.
Signature · 1 line
Jazz is not dead. It just smells funny...
#2 lore raw

PATCH 1/1 ARM: GIC: fix non-SMP builds

Hello,

Quoted 9 lines · Marc Zyngier
Quoted 8 lines · Marek Szyprowski

This patch fixes the build break introduced by commit db0d4db22. It happen only if SMP support has been disabled:

arch/arm/common/gic.c: In function 'gic_init_bases':
arch/arm/common/gic.c:679: error: implicit declaration of function 'cpu_logical_map' make[1]: *** [arch/arm/common/gic.o] Error 1
make: *** [arch/arm/common] Error 2

Quoted 7 lines
Quoted 2 lines

Please have a look at Will's patches:
http://patchwork.ozlabs.org/patch/136504/

which fix this problem in a far more elegant way.

Ok, thanks for the hint! I hope it will be merged to 3.3-rc2+ to fix the regression in GIC code. If so, please ignore my patch.

Best regards

Signature · 2 lines
Marek Szyprowski
Samsung Poland R&D Center
#3 lore raw

PATCH 1/1 ARM: GIC: fix non-SMP builds

Quoted 16 lines · Marek Szyprowski

Hello,

Quoted 12 lines · Marc Zyngier
Quoted 10 lines · Marek Szyprowski

This patch fixes the build break introduced by commit db0d4db22. It happen only if SMP support has been disabled:

arch/arm/common/gic.c: In function 'gic_init_bases':
arch/arm/common/gic.c:679: error: implicit declaration of function 'cpu_logical_map' make[1]: *** [arch/arm/common/gic.o] Error 1
make: *** [arch/arm/common] Error 2

Quoted 7 lines
Quoted 4 lines

Please have a look at Will's patches:
http://patchwork.ozlabs.org/patch/136504/

which fix this problem in a far more elegant way.

Ok, thanks for the hint! I hope it will be merged to 3.3-rc2+ to fix the regression in GIC code. If so, please ignore my patch.

It just got picked up by Russell, so I'd expect to see it being merged upstream in a short while.

	M.
Signature · 1 line
Jazz is not dead. It just smells funny...
#4 lore raw

PATCH 1/1 ARM: GIC: fix non-SMP builds

In reply to Marek Szyprowski

Hello.

Quoted 1 line · Marek Szyprowski

This patch fixes the build break introduced by commit db0d4db22. It

Please also specify the summary of that commit. Russell has recently again
explained why it's needed.

Quoted 9 lines

happen only if SMP support has been disabled:

arch/arm/common/gic.c: In function 'gic_init_bases':
arch/arm/common/gic.c:679: error: implicit declaration of function 'cpu_logical_map' make[1]: *** [arch/arm/common/gic.o] Error 1
make: *** [arch/arm/common] Error 2

WBR, Sergei