summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Morton <akpm@osdl.org>2003-08-31 04:32:09 -0700
committerLinus Torvalds <torvalds@home.osdl.org>2003-08-31 04:32:09 -0700
commite23a122041c7feff126ad59934f7108be95f4af8 (patch)
treea303fe672fb83ce4c3d265cb5d469e9dc1a0634c
parent09952a581aae48a700e0b49ab3bffc41f3ee140a (diff)
[PATCH] kill CONFIG_KCORE_AOUT
From: Adrian Bunk <bunk@fs.tum.de> Remove CONFIG_KCORE_AOUT: the ability to present /proc/kcore in a.out format. I've checked with various arch maintainers. It won't be missed.
-rw-r--r--arch/alpha/Kconfig34
-rw-r--r--arch/arm/Kconfig33
-rw-r--r--arch/arm26/Kconfig33
-rw-r--r--arch/h8300/Kconfig7
-rw-r--r--arch/i386/Kconfig34
-rw-r--r--arch/ia64/Kconfig23
-rw-r--r--arch/m68k/Kconfig34
-rw-r--r--arch/m68knommu/Kconfig8
-rw-r--r--arch/mips/Kconfig25
-rw-r--r--arch/parisc/Kconfig5
-rw-r--r--arch/ppc/Kconfig16
-rw-r--r--arch/ppc64/Kconfig16
-rw-r--r--arch/s390/Kconfig4
-rw-r--r--arch/sh/Kconfig34
-rw-r--r--arch/sparc/Kconfig23
-rw-r--r--arch/sparc64/Kconfig23
-rw-r--r--arch/v850/Kconfig8
-rw-r--r--arch/x86_64/Kconfig5
-rw-r--r--fs/proc/kcore.c70
-rw-r--r--include/linux/proc_fs.h2
20 files changed, 2 insertions, 435 deletions
diff --git a/arch/alpha/Kconfig b/arch/alpha/Kconfig
index 1124b016ce55..bf147bdeb45b 100644
--- a/arch/alpha/Kconfig
+++ b/arch/alpha/Kconfig
@@ -597,40 +597,6 @@ config HOTPLUG
source "drivers/pcmcia/Kconfig"
-choice
- prompt "Kernel core (/proc/kcore) format"
- depends on PROC_FS
- default KCORE_ELF
-
-config KCORE_ELF
- bool "ELF"
- ---help---
- If you enabled support for /proc file system then the file
- /proc/kcore will contain the kernel core image. This can be used
- in gdb:
-
- $ cd /usr/src/linux ; gdb vmlinux /proc/kcore
-
- You have two choices here: ELF and A.OUT. Selecting ELF will make
- /proc/kcore appear in ELF core format as defined by the Executable
- and Linking Format specification. Selecting A.OUT will choose the
- old "a.out" format which may be necessary for some old versions
- of binutils or on some architectures.
-
- This is especially useful if you have compiled the kernel with the
- "-g" option to preserve debugging information. It is mainly used
- for examining kernel data structures on the live kernel so if you
- don't understand what this means or are not a kernel hacker, just
- leave it at its default value ELF.
-
-config KCORE_AOUT
- bool "A.OUT"
- help
- Not necessary unless you're using a very out-of-date binutils
- version. You probably want KCORE_ELF.
-
-endchoice
-
config SRM_ENV
tristate "SRM environment through procfs"
depends on PROC_FS
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
index caa0fdeee295..f4846273df06 100644
--- a/arch/arm/Kconfig
+++ b/arch/arm/Kconfig
@@ -654,39 +654,6 @@ config FPE_FASTFPE
If you do not feel you need a faster FP emulation you should better
choose NWFPE.
-choice
- prompt "Kernel core (/proc/kcore) format"
- default KCORE_ELF
-
-config KCORE_ELF
- bool "ELF"
- ---help---
- If you enabled support for /proc file system then the file
- /proc/kcore will contain the kernel core image. This can be used
- in gdb:
-
- $ cd /usr/src/linux ; gdb vmlinux /proc/kcore
-
- You have two choices here: ELF and A.OUT. Selecting ELF will make
- /proc/kcore appear in ELF core format as defined by the Executable
- and Linking Format specification. Selecting A.OUT will choose the
- old "a.out" format which may be necessary for some old versions
- of binutils or on some architectures.
-
- This is especially useful if you have compiled the kernel with the
- "-g" option to preserve debugging information. It is mainly used
- for examining kernel data structures on the live kernel so if you
- don't understand what this means or are not a kernel hacker, just
- leave it at its default value ELF.
-
-config KCORE_AOUT
- bool "A.OUT"
- help
- Not necessary unless you're using a very out-of-date binutils
- version. You probably want KCORE_ELF.
-
-endchoice
-
source "fs/Kconfig.binfmt"
source "drivers/base/Kconfig"
diff --git a/arch/arm26/Kconfig b/arch/arm26/Kconfig
index 6eb60d5cffff..847cc6441f61 100644
--- a/arch/arm26/Kconfig
+++ b/arch/arm26/Kconfig
@@ -146,39 +146,6 @@ config FPE_NWFPE
You may say N here if you are going to load the Acorn FPEmulator
early in the bootup.
-choice
- prompt "Kernel core (/proc/kcore) format"
- default KCORE_ELF
-
-config KCORE_ELF
- bool "ELF"
- ---help---
- If you enabled support for /proc file system then the file
- /proc/kcore will contain the kernel core image. This can be used
- in gdb:
-
- $ cd /usr/src/linux ; gdb vmlinux /proc/kcore
-
- You have two choices here: ELF and A.OUT. Selecting ELF will make
- /proc/kcore appear in ELF core format as defined by the Executable
- and Linking Format specification. Selecting A.OUT will choose the
- old "a.out" format which may be necessary for some old versions
- of binutils or on some architectures.
-
- This is especially useful if you have compiled the kernel with the
- "-g" option to preserve debugging information. It is mainly used
- for examining kernel data structures on the live kernel so if you
- don't understand what this means or are not a kernel hacker, just
- leave it at its default value ELF.
-
-config KCORE_AOUT
- bool "A.OUT"
- help
- Not necessary unless you're using a very out-of-date binutils
- version. You probably want KCORE_ELF.
-
-endchoice
-
source "fs/Kconfig.binfmt"
config PREEMPT
diff --git a/arch/h8300/Kconfig b/arch/h8300/Kconfig
index 2037d74a96c5..181e65ae964f 100644
--- a/arch/h8300/Kconfig
+++ b/arch/h8300/Kconfig
@@ -177,13 +177,6 @@ endmenu
menu "Executable file formats"
-config KCORE_AOUT
- bool
- default y
-
-config KCORE_ELF
- default y
-
source "fs/Kconfig.binfmt"
endmenu
diff --git a/arch/i386/Kconfig b/arch/i386/Kconfig
index d6062319d10e..e6c54aa3e1af 100644
--- a/arch/i386/Kconfig
+++ b/arch/i386/Kconfig
@@ -1156,40 +1156,6 @@ endmenu
menu "Executable file formats"
-choice
- prompt "Kernel core (/proc/kcore) format"
- depends on PROC_FS
- default KCORE_ELF
-
-config KCORE_ELF
- bool "ELF"
- ---help---
- If you enabled support for /proc file system then the file
- /proc/kcore will contain the kernel core image. This can be used
- in gdb:
-
- $ cd /usr/src/linux ; gdb vmlinux /proc/kcore
-
- You have two choices here: ELF and A.OUT. Selecting ELF will make
- /proc/kcore appear in ELF core format as defined by the Executable
- and Linking Format specification. Selecting A.OUT will choose the
- old "a.out" format which may be necessary for some old versions
- of binutils or on some architectures.
-
- This is especially useful if you have compiled the kernel with the
- "-g" option to preserve debugging information. It is mainly used
- for examining kernel data structures on the live kernel so if you
- don't understand what this means or are not a kernel hacker, just
- leave it at its default value ELF.
-
-config KCORE_AOUT
- bool "A.OUT"
- help
- Not necessary unless you're using a very out-of-date binutils
- version. You probably want KCORE_ELF.
-
-endchoice
-
source "fs/Kconfig.binfmt"
endmenu
diff --git a/arch/ia64/Kconfig b/arch/ia64/Kconfig
index f91b22562166..9e48635abb5f 100644
--- a/arch/ia64/Kconfig
+++ b/arch/ia64/Kconfig
@@ -297,29 +297,6 @@ config IA64_SGI_SN_SIM
If you are compiling a kernel that will run under SGI's IA-64
simulator (Medusa) then say Y, otherwise say N.
-# On IA-64, we always want an ELF /proc/kcore.
-config KCORE_ELF
- bool
- default y
- ---help---
- If you enabled support for /proc file system then the file
- /proc/kcore will contain the kernel core image. This can be used
- in gdb:
-
- $ cd /usr/src/linux ; gdb vmlinux /proc/kcore
-
- You have two choices here: ELF and A.OUT. Selecting ELF will make
- /proc/kcore appear in ELF core format as defined by the Executable
- and Linking Format specification. Selecting A.OUT will choose the
- old "a.out" format which may be necessary for some old versions
- of binutils or on some architectures.
-
- This is especially useful if you have compiled the kernel with the
- "-g" option to preserve debugging information. It is mainly used
- for examining kernel data structures on the live kernel so if you
- don't understand what this means or are not a kernel hacker, just
- leave it at its default value ELF.
-
config FORCE_MAX_ZONEORDER
int
default "18"
diff --git a/arch/m68k/Kconfig b/arch/m68k/Kconfig
index 2a3c72bc00b6..11566d62e86d 100644
--- a/arch/m68k/Kconfig
+++ b/arch/m68k/Kconfig
@@ -342,40 +342,6 @@ endmenu
menu "General setup"
-choice
- prompt "Kernel core (/proc/kcore) format"
- depends on PROC_FS
- default KCORE_ELF
-
-config KCORE_ELF
- bool "ELF"
- ---help---
- If you enabled support for /proc file system then the file
- /proc/kcore will contain the kernel core image. This can be used
- in gdb:
-
- $ cd /usr/src/linux ; gdb vmlinux /proc/kcore
-
- You have two choices here: ELF and A.OUT. Selecting ELF will make
- /proc/kcore appear in ELF core format as defined by the Executable
- and Linking Format specification. Selecting A.OUT will choose the
- old "a.out" format which may be necessary for some old versions
- of binutils or on some architectures.
-
- This is especially useful if you have compiled the kernel with the
- "-g" option to preserve debugging information. It is mainly used
- for examining kernel data structures on the live kernel so if you
- don't understand what this means or are not a kernel hacker, just
- leave it at its default value ELF.
-
-config KCORE_AOUT
- bool "A.OUT"
- help
- Not necessary unless you're using a very out-of-date binutils
- version. You probably want KCORE_ELF.
-
-endchoice
-
source "fs/Kconfig.binfmt"
config ZORRO
diff --git a/arch/m68knommu/Kconfig b/arch/m68knommu/Kconfig
index b35c9c03ec55..7a2d588d799c 100644
--- a/arch/m68knommu/Kconfig
+++ b/arch/m68knommu/Kconfig
@@ -490,14 +490,6 @@ endmenu
menu "Executable file formats"
-config KCORE_AOUT
- bool
- default y
-
-config KCORE_ELF
- bool
- default y
-
source "fs/Kconfig.binfmt"
endmenu
diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
index 034328497da8..84c57063e08c 100644
--- a/arch/mips/Kconfig
+++ b/arch/mips/Kconfig
@@ -1126,31 +1126,6 @@ endmenu
menu "Executable file formats"
-config KCORE_ELF
- bool
- default y
- ---help---
- If you enabled support for /proc file system then the file
- /proc/kcore will contain the kernel core image. This can be used
- in gdb:
-
- $ cd /usr/src/linux ; gdb vmlinux /proc/kcore
-
- You have two choices here: ELF and A.OUT. Selecting ELF will make
- /proc/kcore appear in ELF core format as defined by the Executable
- and Linking Format specification. Selecting A.OUT will choose the
- old "a.out" format which may be necessary for some old versions
- of binutils or on some architectures.
-
- This is especially useful if you have compiled the kernel with the
- "-g" option to preserve debugging information. It is mainly used
- for examining kernel data structures on the live kernel so if you
- don't understand what this means or are not a kernel hacker, just
- leave it at its default value ELF.
-
-config KCORE_AOUT
- bool
-
source "fs/Kconfig.binfmt"
config TRAD_SIGNALS
diff --git a/arch/parisc/Kconfig b/arch/parisc/Kconfig
index 4a78de54598d..6142becdc73a 100644
--- a/arch/parisc/Kconfig
+++ b/arch/parisc/Kconfig
@@ -161,11 +161,6 @@ source "drivers/parisc/Kconfig"
menu "Executable file formats"
-config KCORE_ELF
- bool
- depends on PROC_FS
- default y
-
source "fs/Kconfig.binfmt"
endmenu
diff --git a/arch/ppc/Kconfig b/arch/ppc/Kconfig
index 8c7e94d7fe5a..22d91c235e70 100644
--- a/arch/ppc/Kconfig
+++ b/arch/ppc/Kconfig
@@ -795,22 +795,6 @@ config PCI_PERMEDIA
bool "PCI for Permedia2"
depends on !4xx && !8xx && APUS
-# only elf supported, a.out is not -- Cort
-config KCORE_ELF
- bool
- depends on PROC_FS
- default y
- help
- If you enabled support for /proc file system then the file
- /proc/kcore will contain the kernel core image in ELF format. This
- can be used in gdb:
-
- $ cd /usr/src/linux ; gdb vmlinux /proc/kcore
-
- This is especially useful if you have compiled the kernel with the
- "-g" option to preserve debugging information. It is mainly used
- for examining kernel data structures on the live kernel.
-
config KERNEL_ELF
bool
default y
diff --git a/arch/ppc64/Kconfig b/arch/ppc64/Kconfig
index 4b2f7f1f51ac..c983a5051bb0 100644
--- a/arch/ppc64/Kconfig
+++ b/arch/ppc64/Kconfig
@@ -175,22 +175,6 @@ config PCI_DOMAINS
bool
default PCI
-# only elf supported, a.out is not -- Cort
-config KCORE_ELF
- bool
- depends on PROC_FS
- default y
- help
- If you enabled support for /proc file system then the file
- /proc/kcore will contain the kernel core image in ELF format. This
- can be used in gdb:
-
- $ cd /usr/src/linux ; gdb vmlinux /proc/kcore
-
- This is especially useful if you have compiled the kernel with the
- "-g" option to preserve debugging information. It is mainly used
- for examining kernel data structures on the live kernel.
-
source "fs/Kconfig.binfmt"
source "drivers/pci/Kconfig"
diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig
index 39636e4bf66e..bd1369d1f635 100644
--- a/arch/s390/Kconfig
+++ b/arch/s390/Kconfig
@@ -217,10 +217,6 @@ config IPL_VM
endchoice
-config KCORE_ELF
- bool
- default y
-
source "fs/Kconfig.binfmt"
config PROCESS_DEBUG
diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig
index c86058afcecb..27472a4e6ef6 100644
--- a/arch/sh/Kconfig
+++ b/arch/sh/Kconfig
@@ -729,40 +729,6 @@ endmenu
menu "Executable file formats"
-choice
- prompt "Kernel core (/proc/kcore) format"
- depends on PROC_FS
- default KCORE_ELF
-
-config KCORE_ELF
- bool "ELF"
- ---help---
- If you enabled support for /proc file system then the file
- /proc/kcore will contain the kernel core image. This can be used
- in gdb:
-
- $ cd /usr/src/linux ; gdb vmlinux /proc/kcore
-
- You have two choices here: ELF and A.OUT. Selecting ELF will make
- /proc/kcore appear in ELF core format as defined by the Executable
- and Linking Format specification. Selecting A.OUT will choose the
- old "a.out" format which may be necessary for some old versions
- of binutils or on some architectures.
-
- This is especially useful if you have compiled the kernel with the
- "-g" option to preserve debugging information. It is mainly used
- for examining kernel data structures on the live kernel so if you
- don't understand what this means or are not a kernel hacker, just
- leave it at its default value ELF.
-
-config KCORE_AOUT
- bool "A.OUT"
- help
- Not necessary unless you're using a very out-of-date binutils
- version. You probably want KCORE_ELF.
-
-endchoice
-
source "fs/Kconfig.binfmt"
endmenu
diff --git a/arch/sparc/Kconfig b/arch/sparc/Kconfig
index 7b8fd9695044..e9874e031e3a 100644
--- a/arch/sparc/Kconfig
+++ b/arch/sparc/Kconfig
@@ -254,29 +254,6 @@ config SUN_OPENPROMFS
<file:Documentation/modules.txt>.
The module will be called openpromfs. If unsure, say M.
-config KCORE_ELF
- bool
- depends on PROC_FS
- default y
- ---help---
- If you enabled support for /proc file system then the file
- /proc/kcore will contain the kernel core image. This can be used
- in gdb:
-
- $ cd /usr/src/linux ; gdb vmlinux /proc/kcore
-
- You have two choices here: ELF and A.OUT. Selecting ELF will make
- /proc/kcore appear in ELF core format as defined by the Executable
- and Linking Format specification. Selecting A.OUT will choose the
- old "a.out" format which may be necessary for some old versions
- of binutils or on some architectures.
-
- This is especially useful if you have compiled the kernel with the
- "-g" option to preserve debugging information. It is mainly used
- for examining kernel data structures on the live kernel so if you
- don't understand what this means or are not a kernel hacker, just
- leave it at its default value ELF.
-
source "fs/Kconfig.binfmt"
config SUNOS_EMUL
diff --git a/arch/sparc64/Kconfig b/arch/sparc64/Kconfig
index db794423cff4..ee6c1ce5a972 100644
--- a/arch/sparc64/Kconfig
+++ b/arch/sparc64/Kconfig
@@ -363,29 +363,6 @@ config SUN_OPENPROMFS
<file:Documentation/modules.txt>.
The module will be called openpromfs. If unsure, say M.
-config KCORE_ELF
- bool
- depends on PROC_FS
- default y
- ---help---
- If you enabled support for /proc file system then the file
- /proc/kcore will contain the kernel core image. This can be used
- in gdb:
-
- $ cd /usr/src/linux ; gdb vmlinux /proc/kcore
-
- You have two choices here: ELF and A.OUT. Selecting ELF will make
- /proc/kcore appear in ELF core format as defined by the Executable
- and Linking Format specification. Selecting A.OUT will choose the
- old "a.out" format which may be necessary for some old versions
- of binutils or on some architectures.
-
- This is especially useful if you have compiled the kernel with the
- "-g" option to preserve debugging information. It is mainly used
- for examining kernel data structures on the live kernel so if you
- don't understand what this means or are not a kernel hacker, just
- leave it at its default value ELF.
-
config SPARC32_COMPAT
bool "Kernel support for Linux/Sparc 32bit binary compatibility"
help
diff --git a/arch/v850/Kconfig b/arch/v850/Kconfig
index 5c785bca09d8..37fe8943275d 100644
--- a/arch/v850/Kconfig
+++ b/arch/v850/Kconfig
@@ -262,14 +262,6 @@ endmenu
menu "Executable file formats"
-config KCORE_AOUT
- bool
- default y
-
-config KCORE_ELF
- bool
- default y
-
source "fs/Kconfig.binfmt"
endmenu
diff --git a/arch/x86_64/Kconfig b/arch/x86_64/Kconfig
index 46d6829586a6..0bafd4c4e3e8 100644
--- a/arch/x86_64/Kconfig
+++ b/arch/x86_64/Kconfig
@@ -370,11 +370,6 @@ endmenu
menu "Executable file formats / Emulations"
-config KCORE_ELF
- bool
- depends on PROC_FS
- default y
-
source "fs/Kconfig.binfmt"
config IA32_EMULATION
diff --git a/fs/proc/kcore.c b/fs/proc/kcore.c
index 8ef4a48002b3..93551065f4cf 100644
--- a/fs/proc/kcore.c
+++ b/fs/proc/kcore.c
@@ -1,5 +1,5 @@
/*
- * fs/proc/kcore.c kernel ELF/AOUT core dumper
+ * fs/proc/kcore.c kernel ELF core dumper
*
* Modelled on fs/exec.c:aout_core_dump()
* Jeremy Fitzhardinge <jeremy@sw.oz.au>
@@ -34,73 +34,6 @@ struct file_operations proc_kcore_operations = {
.open = open_kcore,
};
-#ifdef CONFIG_KCORE_AOUT
-static ssize_t read_kcore(struct file *file, char *buf,
- size_t count, loff_t *ppos)
-{
- loff_t p = *ppos, memsize;
- ssize_t read;
- ssize_t count1;
- char * pnt;
- struct user dump;
-#if defined (__i386__) || defined (__mc68000__) || defined(__x86_64__)
-# define FIRST_MAPPED PAGE_SIZE /* we don't have page 0 mapped on x86.. */
-#else
-# define FIRST_MAPPED 0
-#endif
-
- memset(&dump, 0, sizeof(struct user));
- dump.magic = CMAGIC;
- dump.u_dsize = (virt_to_phys(high_memory) >> PAGE_SHIFT);
-#if defined (__i386__) || defined(__x86_64__)
- dump.start_code = PAGE_OFFSET;
-#endif
-#ifdef __alpha__
- dump.start_data = PAGE_OFFSET;
-#endif
-
- memsize = virt_to_phys(high_memory);
- if (p >= memsize)
- return 0;
- if (count > memsize - p)
- count = memsize - p;
- read = 0;
-
- if (p < sizeof(struct user) && count > 0) {
- count1 = count;
- if (p + count1 > sizeof(struct user))
- count1 = sizeof(struct user)-p;
- pnt = (char *) &dump + p;
- if (copy_to_user(buf,(void *) pnt, count1))
- return -EFAULT;
- buf += count1;
- p += count1;
- count -= count1;
- read += count1;
- }
-
- if (count > 0 && p < PAGE_SIZE + FIRST_MAPPED) {
- count1 = PAGE_SIZE + FIRST_MAPPED - p;
- if (count1 > count)
- count1 = count;
- if (clear_user(buf, count1))
- return -EFAULT;
- buf += count1;
- p += count1;
- count -= count1;
- read += count1;
- }
- if (count > 0) {
- if (copy_to_user(buf,
- (void *)(PAGE_OFFSET + (long)p - PAGE_SIZE), count))
- return -EFAULT;
- read += count;
- }
- *ppos += read;
- return read;
-}
-#else /* CONFIG_KCORE_AOUT */
-
#ifndef kc_vaddr_to_offset
#define kc_vaddr_to_offset(v) ((v) - PAGE_OFFSET)
#endif
@@ -482,4 +415,3 @@ static ssize_t read_kcore(struct file *file, char *buffer, size_t buflen, loff_t
return acc;
}
-#endif /* CONFIG_KCORE_AOUT */
diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h
index 254ae163c628..cbe2e5719506 100644
--- a/include/linux/proc_fs.h
+++ b/include/linux/proc_fs.h
@@ -219,7 +219,7 @@ extern struct proc_dir_entry proc_root;
#endif /* CONFIG_PROC_FS */
-#if !defined(CONFIG_PROC_FS) || defined(CONFIG_KCORE_AOUT)
+#if !defined(CONFIG_PROC_FS)
static inline void kclist_add(struct kcore_list *new, void *addr, size_t size)
{
}