]> git.baikalelectronics.ru Git - kernel.git/commit
ARC: [SMP] Fix build failures for large NR_CPUS
authorVineet Gupta <vgupta@synopsys.com>
Fri, 1 Nov 2013 05:16:40 +0000 (10:46 +0530)
committerVineet Gupta <vgupta@synopsys.com>
Wed, 6 Nov 2013 05:11:46 +0000 (10:41 +0530)
commit45416d9cb2b2507c70f927fcc7cdc563e69797ee
tree8100ec071f56fbd4cd3a01747ce971235118f6f3
parent66caf1c0f4d5e0949fe5e7a30dd0bdaa8c9af2a5
ARC: [SMP] Fix build failures for large NR_CPUS

ST.as only takes S9 (255) for offset. This was going out of range when
accessing a task_struct field with 4k NR_CPUS (due to 128b of coumaks
itself in there).

Workaround by using an intermediate register to do the address scaling.

There is some duplication of fix for ctx_sw.c and ctx_sw_asm.S however
given that C version will go away soon I'm not bothering to factor out
the common code.

Reported-by: Noam Camus <noamc@ezchip.com>
Signed-off-by: Vineet Gupta <vgupta@synopsys.com>
arch/arc/kernel/ctx_sw.c
arch/arc/kernel/ctx_sw_asm.S