]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/commit
MFC 313407,313449: Copy ELF machine/flags from binaries to core dumps.
authorjhb <jhb@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Thu, 11 May 2017 17:26:34 +0000 (17:26 +0000)
committerjhb <jhb@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Thu, 11 May 2017 17:26:34 +0000 (17:26 +0000)
commitbf166f0b5e0f2e95dfe7a2aa068a52448b72a087
tree31703f6ddfe436a85364333924064706de2ab5fe
parent97a382691166f6eabd7efe5d6b6b1d762278f92a
MFC 313407,313449: Copy ELF machine/flags from binaries to core dumps.

313407:
Copy the e_machine and e_flags fields from the binary into an ELF core dump.

In the kernel, cache the machine and flags fields from ELF header to use in
the ELF header of a core dump. For gcore, the copy these fields over from
the ELF header in the binary.

This matters for platforms which encode ABI information in the flags field
(such as o32 vs n32 on MIPS).

313449:
Trim trailing whitespace (mostly introduced in r313407).

Sponsored by: DARPA / AFRL

git-svn-id: svn://svn.freebsd.org/base/stable/10@318192 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
sys/kern/imgact_elf.c
sys/kern/kern_fork.c
sys/sys/proc.h
usr.bin/gcore/elfcore.c