diff options
author | H. Peter Anvin <hpa@linux.intel.com> | 2009-02-04 16:58:26 -0800 |
---|---|---|
committer | H. Peter Anvin <hpa@linux.intel.com> | 2009-02-04 16:58:26 -0800 |
commit | 327641da8e3e227f42690479182b896fd19486be (patch) | |
tree | 05fa7f317e854f2da5d46d4c8977486d71bb2b21 /include/asm-generic/vmlinux.lds.h | |
parent | 1f4f931501e9270c156d05ee76b7b872de486304 (diff) | |
parent | ef3892bd63420380d115f755d351d2071f1f805f (diff) | |
download | blackbird-op-linux-327641da8e3e227f42690479182b896fd19486be.tar.gz blackbird-op-linux-327641da8e3e227f42690479182b896fd19486be.zip |
Merge branch 'core/percpu' into x86/paravirt
Diffstat (limited to 'include/asm-generic/vmlinux.lds.h')
-rw-r--r-- | include/asm-generic/vmlinux.lds.h | 22 |
1 files changed, 17 insertions, 5 deletions
diff --git a/include/asm-generic/vmlinux.lds.h b/include/asm-generic/vmlinux.lds.h index 53e21f36a802..5406e70aba86 100644 --- a/include/asm-generic/vmlinux.lds.h +++ b/include/asm-generic/vmlinux.lds.h @@ -445,10 +445,9 @@ * section in the linker script will go there too. @phdr should have * a leading colon. * - * This macro defines three symbols, __per_cpu_load, __per_cpu_start - * and __per_cpu_end. The first one is the vaddr of loaded percpu - * init data. __per_cpu_start equals @vaddr and __per_cpu_end is the - * end offset. + * Note that this macros defines __per_cpu_load as an absolute symbol. + * If there is no need to put the percpu section at a predetermined + * address, use PERCPU(). */ #define PERCPU_VADDR(vaddr, phdr) \ VMLINUX_SYMBOL(__per_cpu_load) = .; \ @@ -470,7 +469,20 @@ * Align to @align and outputs output section for percpu area. This * macro doesn't maniuplate @vaddr or @phdr and __per_cpu_load and * __per_cpu_start will be identical. + * + * This macro is equivalent to ALIGN(align); PERCPU_VADDR( , ) except + * that __per_cpu_load is defined as a relative symbol against + * .data.percpu which is required for relocatable x86_32 + * configuration. */ #define PERCPU(align) \ . = ALIGN(align); \ - PERCPU_VADDR( , ) + .data.percpu : AT(ADDR(.data.percpu) - LOAD_OFFSET) { \ + VMLINUX_SYMBOL(__per_cpu_load) = .; \ + VMLINUX_SYMBOL(__per_cpu_start) = .; \ + *(.data.percpu.first) \ + *(.data.percpu.page_aligned) \ + *(.data.percpu) \ + *(.data.percpu.shared_aligned) \ + VMLINUX_SYMBOL(__per_cpu_end) = .; \ + } |