Changeset View
Changeset View
Standalone View
Standalone View
head/sys/kern/imgact_elf.c
Show First 20 Lines • Show All 114 Lines • ▼ Show 20 Lines | |||||
static int elf_legacy_coredump = 0; | static int elf_legacy_coredump = 0; | ||||
SYSCTL_INT(_debug, OID_AUTO, __elfN(legacy_coredump), CTLFLAG_RW, | SYSCTL_INT(_debug, OID_AUTO, __elfN(legacy_coredump), CTLFLAG_RW, | ||||
&elf_legacy_coredump, 0, | &elf_legacy_coredump, 0, | ||||
"include all and only RW pages in core dumps"); | "include all and only RW pages in core dumps"); | ||||
int __elfN(nxstack) = | int __elfN(nxstack) = | ||||
#if defined(__amd64__) || defined(__powerpc64__) /* both 64 and 32 bit */ || \ | #if defined(__amd64__) || defined(__powerpc64__) /* both 64 and 32 bit */ || \ | ||||
(defined(__arm__) && __ARM_ARCH >= 7) || defined(__aarch64__) | (defined(__arm__) && __ARM_ARCH >= 7) || defined(__aarch64__) || \ | ||||
defined(__riscv) | |||||
1; | 1; | ||||
#else | #else | ||||
0; | 0; | ||||
#endif | #endif | ||||
SYSCTL_INT(__CONCAT(_kern_elf, __ELF_WORD_SIZE), OID_AUTO, | SYSCTL_INT(__CONCAT(_kern_elf, __ELF_WORD_SIZE), OID_AUTO, | ||||
nxstack, CTLFLAG_RW, &__elfN(nxstack), 0, | nxstack, CTLFLAG_RW, &__elfN(nxstack), 0, | ||||
__XSTRING(__CONCAT(ELF, __ELF_WORD_SIZE)) ": enable non-executable stack"); | __XSTRING(__CONCAT(ELF, __ELF_WORD_SIZE)) ": enable non-executable stack"); | ||||
▲ Show 20 Lines • Show All 2,353 Lines • Show Last 20 Lines |