summaryrefslogtreecommitdiffstats
path: root/sys/vm/vm.h
diff options
context:
space:
mode:
authordillon <dillon@FreeBSD.org>2002-12-16 19:24:43 +0000
committerdillon <dillon@FreeBSD.org>2002-12-16 19:24:43 +0000
commitbe3db49c80fb516ad39e2306c2dd94eb57f1fe16 (patch)
tree62395793dfc1ca744a98bca2261e363d7c975367 /sys/vm/vm.h
parent1696b05046d85a2bd2206eddc6e04c79ac567c2b (diff)
downloadFreeBSD-src-be3db49c80fb516ad39e2306c2dd94eb57f1fe16.zip
FreeBSD-src-be3db49c80fb516ad39e2306c2dd94eb57f1fe16.tar.gz
Change the way ELF coredumps are handled. Instead of unconditionally
skipping read-only pages, which can result in valuable non-text-related data not getting dumped, the ELF loader and the dynamic loader now mark read-only text pages NOCORE and the coredump code only checks (primarily) for complete inaccessibility of the page or NOCORE being set. Certain applications which map large amounts of read-only data will produce much larger cores. A new sysctl has been added, debug.elf_legacy_coredump, which will revert to the old behavior. This commit represents collaborative work by all parties involved. The PR contains a program demonstrating the problem. PR: kern/45994 Submitted by: "Peter Edwards" <pmedwards@eircom.net>, Archie Cobbs <archie@dellroad.org> Reviewed by: jdp, dillon MFC after: 7 days
Diffstat (limited to 'sys/vm/vm.h')
-rw-r--r--sys/vm/vm.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/vm/vm.h b/sys/vm/vm.h
index ffbcd48..55818ef 100644
--- a/sys/vm/vm.h
+++ b/sys/vm/vm.h
@@ -81,6 +81,7 @@ typedef u_char vm_prot_t; /* protection codes */
#define VM_PROT_OVERRIDE_WRITE ((vm_prot_t) 0x08) /* copy-on-write */
#define VM_PROT_ALL (VM_PROT_READ|VM_PROT_WRITE|VM_PROT_EXECUTE)
+#define VM_PROT_RW (VM_PROT_READ|VM_PROT_WRITE)
#define VM_PROT_DEFAULT VM_PROT_ALL
union vm_map_object;
OpenPOWER on IntegriCloud