s390/preempt: move preempt_count to the lowcore
authorMartin Schwidefsky <schwidefsky@de.ibm.com>
Tue, 25 Oct 2016 10:21:44 +0000 (12:21 +0200)
committerMartin Schwidefsky <schwidefsky@de.ibm.com>
Fri, 11 Nov 2016 15:37:40 +0000 (16:37 +0100)
commitc360192bf4a8dc72f102dd6a4e1bf8bd0b404cfa
treec54104bae43978dfe31e6fc2c9a4d996218379fd
parent1993dbc7e09a7ffdd98975589aa83387928e9fe7
s390/preempt: move preempt_count to the lowcore

Convert s390 to use a field in the struct lowcore for the CPU
preemption count. It is a bit cheaper to access a lowcore field
compared to a thread_info variable and it removes the depencency
on a task related structure.

bloat-o-meter on the vmlinux image for the default configuration
(CONFIG_PREEMPT_NONE=y) reports a small reduction in text size:

add/remove: 0/0 grow/shrink: 18/578 up/down: 228/-5448 (-5220)

A larger improvement is achieved with the default configuration
but with CONFIG_PREEMPT=y and CONFIG_DEBUG_PREEMPT=n:

add/remove: 2/6 grow/shrink: 59/4477 up/down: 1618/-228762 (-227144)

Reviewed-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
arch/s390/include/asm/lowcore.h
arch/s390/include/asm/preempt.h [new file with mode: 0644]
arch/s390/include/asm/thread_info.h
arch/s390/kernel/asm-offsets.c
arch/s390/kernel/early.c
arch/s390/kernel/entry.S
arch/s390/kernel/setup.c
arch/s390/mm/fault.c