aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-12-16 13:47:24 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2009-12-16 13:47:24 -0500
commit74f3ae743427b87e43b5cb9f4257021ae8ad4267 (patch)
tree378975998960af61558304c97999f3bf62c8ba12 /arch
parentd8bef0bb219154e655fa139e28400d6ae9aa3727 (diff)
parent8d99513c1b76cfd0b2dcf061c5136cb1061e6b37 (diff)
Merge branch 'module' of git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus
* 'module' of git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux-2.6-for-linus: modpost: fix segfault with short symbol names module: handle ppc64 relocating kcrctabs when CONFIG_RELOCATABLE=y Kbuild: clear marker out of modpost module: make MODULE_SYMBOL_PREFIX into a CONFIG option ARM: unexport symbols used to implement floating point emulation ARM: use unified discard definition in linker script x86: don't export inline function sparc64: don't export static inline pci_ functions
Diffstat (limited to 'arch')
-rw-r--r--arch/arm/kernel/armksyms.c20
-rw-r--r--arch/arm/kernel/vmlinux.lds.S13
-rw-r--r--arch/blackfin/Kconfig4
-rw-r--r--arch/blackfin/include/asm/module.h2
-rw-r--r--arch/blackfin/kernel/vmlinux.lds.S2
-rw-r--r--arch/h8300/Kconfig4
-rw-r--r--arch/h8300/include/asm/module.h2
-rw-r--r--arch/h8300/kernel/vmlinux.lds.S1
-rw-r--r--arch/powerpc/include/asm/module.h5
-rw-r--r--arch/powerpc/kernel/vmlinux.lds.S3
-rw-r--r--arch/sparc/kernel/pci.c1
-rw-r--r--arch/sparc/kernel/sparc_ksyms_64.c12
-rw-r--r--arch/x86/kernel/x8664_ksyms_64.c4
13 files changed, 27 insertions, 46 deletions
diff --git a/arch/arm/kernel/armksyms.c b/arch/arm/kernel/armksyms.c
index 0e627705f746..8214bfebfaca 100644
--- a/arch/arm/kernel/armksyms.c
+++ b/arch/arm/kernel/armksyms.c
@@ -48,27 +48,7 @@ extern void __aeabi_uidivmod(void);
48extern void __aeabi_ulcmp(void); 48extern void __aeabi_ulcmp(void);
49 49
50extern void fpundefinstr(void); 50extern void fpundefinstr(void);
51extern void fp_enter(void);
52 51
53/*
54 * This has a special calling convention; it doesn't
55 * modify any of the usual registers, except for LR.
56 */
57#define EXPORT_CRC_ALIAS(sym) __CRC_SYMBOL(sym, "")
58
59#define EXPORT_SYMBOL_ALIAS(sym,orig) \
60 EXPORT_CRC_ALIAS(sym) \
61 static const struct kernel_symbol __ksymtab_##sym \
62 __used __attribute__((section("__ksymtab"))) = \
63 { (unsigned long)&orig, #sym };
64
65/*
66 * floating point math emulator support.
67 * These symbols will never change their calling convention...
68 */
69EXPORT_SYMBOL_ALIAS(kern_fp_enter,fp_enter);
70EXPORT_SYMBOL_ALIAS(fp_printk,printk);
71EXPORT_SYMBOL_ALIAS(fp_send_sig,send_sig);
72 52
73EXPORT_SYMBOL(__backtrace); 53EXPORT_SYMBOL(__backtrace);
74 54
diff --git a/arch/arm/kernel/vmlinux.lds.S b/arch/arm/kernel/vmlinux.lds.S
index 71151bd87a36..4957e13ef55b 100644
--- a/arch/arm/kernel/vmlinux.lds.S
+++ b/arch/arm/kernel/vmlinux.lds.S
@@ -65,11 +65,11 @@ SECTIONS
65 __init_end = .; 65 __init_end = .;
66#endif 66#endif
67 67
68 /DISCARD/ : { /* Exit code and data */ 68 /*
69 EXIT_TEXT 69 * unwind exit sections must be discarded before the rest of the
70 EXIT_DATA 70 * unwind sections get included.
71 *(.exitcall.exit) 71 */
72 *(.discard) 72 /DISCARD/ : {
73 *(.ARM.exidx.exit.text) 73 *(.ARM.exidx.exit.text)
74 *(.ARM.extab.exit.text) 74 *(.ARM.extab.exit.text)
75#ifndef CONFIG_HOTPLUG_CPU 75#ifndef CONFIG_HOTPLUG_CPU
@@ -238,6 +238,9 @@ SECTIONS
238 238
239 STABS_DEBUG 239 STABS_DEBUG
240 .comment 0 : { *(.comment) } 240 .comment 0 : { *(.comment) }
241
242 /* Default discards */
243 DISCARDS
241} 244}
242 245
243/* 246/*
diff --git a/arch/blackfin/Kconfig b/arch/blackfin/Kconfig
index ae6a60f10120..2180433213b7 100644
--- a/arch/blackfin/Kconfig
+++ b/arch/blackfin/Kconfig
@@ -5,6 +5,10 @@
5 5
6mainmenu "Blackfin Kernel Configuration" 6mainmenu "Blackfin Kernel Configuration"
7 7
8config SYMBOL_PREFIX
9 string
10 default "_"
11
8config MMU 12config MMU
9 def_bool n 13 def_bool n
10 14
diff --git a/arch/blackfin/include/asm/module.h b/arch/blackfin/include/asm/module.h
index 9c1cfffddd9b..4282b169ead9 100644
--- a/arch/blackfin/include/asm/module.h
+++ b/arch/blackfin/include/asm/module.h
@@ -7,8 +7,6 @@
7#ifndef _ASM_BFIN_MODULE_H 7#ifndef _ASM_BFIN_MODULE_H
8#define _ASM_BFIN_MODULE_H 8#define _ASM_BFIN_MODULE_H
9 9
10#define MODULE_SYMBOL_PREFIX "_"
11
12#define Elf_Shdr Elf32_Shdr 10#define Elf_Shdr Elf32_Shdr
13#define Elf_Sym Elf32_Sym 11#define Elf_Sym Elf32_Sym
14#define Elf_Ehdr Elf32_Ehdr 12#define Elf_Ehdr Elf32_Ehdr
diff --git a/arch/blackfin/kernel/vmlinux.lds.S b/arch/blackfin/kernel/vmlinux.lds.S
index 10e12539000e..f39707c6590d 100644
--- a/arch/blackfin/kernel/vmlinux.lds.S
+++ b/arch/blackfin/kernel/vmlinux.lds.S
@@ -4,8 +4,6 @@
4 * Licensed under the GPL-2 or later 4 * Licensed under the GPL-2 or later
5 */ 5 */
6 6
7#define VMLINUX_SYMBOL(_sym_) _##_sym_
8
9#include <asm-generic/vmlinux.lds.h> 7#include <asm-generic/vmlinux.lds.h>
10#include <asm/mem_map.h> 8#include <asm/mem_map.h>
11#include <asm/page.h> 9#include <asm/page.h>
diff --git a/arch/h8300/Kconfig b/arch/h8300/Kconfig
index 9420648352b8..53cc669e6d59 100644
--- a/arch/h8300/Kconfig
+++ b/arch/h8300/Kconfig
@@ -10,6 +10,10 @@ config H8300
10 default y 10 default y
11 select HAVE_IDE 11 select HAVE_IDE
12 12
13config SYMBOL_PREFIX
14 string
15 default "_"
16
13config MMU 17config MMU
14 bool 18 bool
15 default n 19 default n
diff --git a/arch/h8300/include/asm/module.h b/arch/h8300/include/asm/module.h
index de23231f3196..8e46724b7c09 100644
--- a/arch/h8300/include/asm/module.h
+++ b/arch/h8300/include/asm/module.h
@@ -8,6 +8,4 @@ struct mod_arch_specific { };
8#define Elf_Sym Elf32_Sym 8#define Elf_Sym Elf32_Sym
9#define Elf_Ehdr Elf32_Ehdr 9#define Elf_Ehdr Elf32_Ehdr
10 10
11#define MODULE_SYMBOL_PREFIX "_"
12
13#endif /* _ASM_H8/300_MODULE_H */ 11#endif /* _ASM_H8/300_MODULE_H */
diff --git a/arch/h8300/kernel/vmlinux.lds.S b/arch/h8300/kernel/vmlinux.lds.S
index b9e24907e6ea..03d356d96e5d 100644
--- a/arch/h8300/kernel/vmlinux.lds.S
+++ b/arch/h8300/kernel/vmlinux.lds.S
@@ -1,4 +1,3 @@
1#define VMLINUX_SYMBOL(_sym_) _##_sym_
2#include <asm-generic/vmlinux.lds.h> 1#include <asm-generic/vmlinux.lds.h>
3#include <asm/page.h> 2#include <asm/page.h>
4 3
diff --git a/arch/powerpc/include/asm/module.h b/arch/powerpc/include/asm/module.h
index 08454880a2c0..0192a4ee2bc2 100644
--- a/arch/powerpc/include/asm/module.h
+++ b/arch/powerpc/include/asm/module.h
@@ -87,5 +87,10 @@ struct exception_table_entry;
87void sort_ex_table(struct exception_table_entry *start, 87void sort_ex_table(struct exception_table_entry *start,
88 struct exception_table_entry *finish); 88 struct exception_table_entry *finish);
89 89
90#ifdef CONFIG_MODVERSIONS
91#define ARCH_RELOCATES_KCRCTAB
92
93extern const unsigned long reloc_start[];
94#endif
90#endif /* __KERNEL__ */ 95#endif /* __KERNEL__ */
91#endif /* _ASM_POWERPC_MODULE_H */ 96#endif /* _ASM_POWERPC_MODULE_H */
diff --git a/arch/powerpc/kernel/vmlinux.lds.S b/arch/powerpc/kernel/vmlinux.lds.S
index 27735a7ac12b..dcd01c82e701 100644
--- a/arch/powerpc/kernel/vmlinux.lds.S
+++ b/arch/powerpc/kernel/vmlinux.lds.S
@@ -38,6 +38,9 @@ jiffies = jiffies_64 + 4;
38#endif 38#endif
39SECTIONS 39SECTIONS
40{ 40{
41 . = 0;
42 reloc_start = .;
43
41 . = KERNELBASE; 44 . = KERNELBASE;
42 45
43/* 46/*
diff --git a/arch/sparc/kernel/pci.c b/arch/sparc/kernel/pci.c
index b85374f7cf94..539e83f8e087 100644
--- a/arch/sparc/kernel/pci.c
+++ b/arch/sparc/kernel/pci.c
@@ -1064,7 +1064,6 @@ int pci64_dma_supported(struct pci_dev *pdev, u64 device_mask)
1064 1064
1065 return (device_mask & dma_addr_mask) == dma_addr_mask; 1065 return (device_mask & dma_addr_mask) == dma_addr_mask;
1066} 1066}
1067EXPORT_SYMBOL(pci_dma_supported);
1068 1067
1069void pci_resource_to_user(const struct pci_dev *pdev, int bar, 1068void pci_resource_to_user(const struct pci_dev *pdev, int bar,
1070 const struct resource *rp, resource_size_t *start, 1069 const struct resource *rp, resource_size_t *start,
diff --git a/arch/sparc/kernel/sparc_ksyms_64.c b/arch/sparc/kernel/sparc_ksyms_64.c
index 0f26066a08d9..372ad59c4cba 100644
--- a/arch/sparc/kernel/sparc_ksyms_64.c
+++ b/arch/sparc/kernel/sparc_ksyms_64.c
@@ -38,17 +38,5 @@ EXPORT_SYMBOL(sun4v_niagara_setperf);
38EXPORT_SYMBOL(sun4v_niagara2_getperf); 38EXPORT_SYMBOL(sun4v_niagara2_getperf);
39EXPORT_SYMBOL(sun4v_niagara2_setperf); 39EXPORT_SYMBOL(sun4v_niagara2_setperf);
40 40
41#ifdef CONFIG_PCI
42/* inline functions in asm/pci_64.h */
43EXPORT_SYMBOL(pci_alloc_consistent);
44EXPORT_SYMBOL(pci_free_consistent);
45EXPORT_SYMBOL(pci_map_single);
46EXPORT_SYMBOL(pci_unmap_single);
47EXPORT_SYMBOL(pci_map_sg);
48EXPORT_SYMBOL(pci_unmap_sg);
49EXPORT_SYMBOL(pci_dma_sync_single_for_cpu);
50EXPORT_SYMBOL(pci_dma_sync_sg_for_cpu);
51#endif
52
53/* Exporting a symbol from /init/main.c */ 41/* Exporting a symbol from /init/main.c */
54EXPORT_SYMBOL(saved_command_line); 42EXPORT_SYMBOL(saved_command_line);
diff --git a/arch/x86/kernel/x8664_ksyms_64.c b/arch/x86/kernel/x8664_ksyms_64.c
index a1029769b6f2..084c1adc45f5 100644
--- a/arch/x86/kernel/x8664_ksyms_64.c
+++ b/arch/x86/kernel/x8664_ksyms_64.c
@@ -56,4 +56,6 @@ EXPORT_SYMBOL(__memcpy);
56 56
57EXPORT_SYMBOL(empty_zero_page); 57EXPORT_SYMBOL(empty_zero_page);
58EXPORT_SYMBOL(init_level4_pgt); 58EXPORT_SYMBOL(init_level4_pgt);
59EXPORT_SYMBOL(load_gs_index); 59#ifndef CONFIG_PARAVIRT
60EXPORT_SYMBOL(native_load_gs_index);
61#endif