alistair23-linux/arch/cris
Tejun Heo 0415b00d17 percpu: Always align percpu output section to PAGE_SIZE
Percpu allocator honors alignment request upto PAGE_SIZE and both the
percpu addresses in the percpu address space and the translated kernel
addresses should be aligned accordingly.  The calculation of the
former depends on the alignment of percpu output section in the kernel
image.

The linker script macros PERCPU_VADDR() and PERCPU() are used to
define this output section and the latter takes @align parameter.
Several architectures are using @align smaller than PAGE_SIZE breaking
percpu memory alignment.

This patch removes @align parameter from PERCPU(), renames it to
PERCPU_SECTION() and makes it always align to PAGE_SIZE.  While at it,
add PCPU_SETUP_BUG_ON() checks such that alignment problems are
reliably detected and remove percpu alignment comment recently added
in workqueue.c as the condition would trigger BUG way before reaching
there.

For um, this patch raises the alignment of percpu area.  As the area
is in .init, there shouldn't be any noticeable difference.

This problem was discovered by David Howells while debugging boot
failure on mn10300.

Signed-off-by: Tejun Heo <tj@kernel.org>
Acked-by: Mike Frysinger <vapier@gentoo.org>
Cc: uclinux-dist-devel@blackfin.uclinux.org
Cc: David Howells <dhowells@redhat.com>
Cc: Jeff Dike <jdike@addtoit.com>
Cc: user-mode-linux-devel@lists.sourceforge.net
2011-03-24 18:50:09 +01:00
..
arch-v10 Merge branches 'irq-fixes-for-linus' and 'sched-fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip 2011-03-18 10:44:05 -07:00
arch-v32 cris: Use accessor functions to set IRQ_PER_CPU flag 2011-03-17 15:52:13 +01:00
boot CRIS: Discard .note.gnu.build-id section 2010-08-04 13:02:33 +02:00
configs kconfig: rename CONFIG_EMBEDDED to CONFIG_EXPERT 2011-01-20 17:02:05 -08:00
include remove dma64_addr_t 2011-03-23 19:47:18 -07:00
kernel percpu: Always align percpu output section to PAGE_SIZE 2011-03-24 18:50:09 +01:00
mm CRIS: Always dump registers for segfaulting process. 2010-08-04 18:28:49 +02:00
Kconfig cris: Use generic show_interrupts() 2011-03-17 15:52:25 +01:00
Kconfig.debug CRIS: Add config for pausing a seg-faulting process 2010-08-04 18:28:48 +02:00
Makefile