From bee4a934bf8d0e7a069c84348757eed376e0231d Mon Sep 17 00:00:00 2001 From: deraadt Date: Mon, 14 Nov 2022 13:42:19 +0000 Subject: [PATCH] Recognize PT_OPENBSD_MUTABLE with LLVM's readobj / objdump. from brad --- gnu/llvm/llvm/tools/llvm-objdump/ELFDump.cpp | 3 +++ gnu/llvm/llvm/tools/llvm-readobj/ELFDumper.cpp | 1 + 2 files changed, 4 insertions(+) diff --git a/gnu/llvm/llvm/tools/llvm-objdump/ELFDump.cpp b/gnu/llvm/llvm/tools/llvm-objdump/ELFDump.cpp index da7415834c6..8ceb941ea41 100644 --- a/gnu/llvm/llvm/tools/llvm-objdump/ELFDump.cpp +++ b/gnu/llvm/llvm/tools/llvm-objdump/ELFDump.cpp @@ -246,6 +246,9 @@ static void printProgramHeaders(const ELFFile &Obj, StringRef FileName) { case ELF::PT_OPENBSD_BOOTDATA: outs() << " OPENBSD_BOOTDATA "; break; + case ELF::PT_OPENBSD_MUTABLE: + outs() << " OPENBSD_MUTABLE "; + break; case ELF::PT_OPENBSD_RANDOMIZE: outs() << " OPENBSD_RANDOMIZE "; break; diff --git a/gnu/llvm/llvm/tools/llvm-readobj/ELFDumper.cpp b/gnu/llvm/llvm/tools/llvm-readobj/ELFDumper.cpp index f221acba979..f0708a758dc 100644 --- a/gnu/llvm/llvm/tools/llvm-readobj/ELFDumper.cpp +++ b/gnu/llvm/llvm/tools/llvm-readobj/ELFDumper.cpp @@ -1369,6 +1369,7 @@ static StringRef segmentTypeToString(unsigned Arch, unsigned Type) { LLVM_READOBJ_ENUM_CASE(ELF, PT_GNU_RELRO); LLVM_READOBJ_ENUM_CASE(ELF, PT_GNU_PROPERTY); + LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_MUTABLE); LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_RANDOMIZE); LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_WXNEEDED); LLVM_READOBJ_ENUM_CASE(ELF, PT_OPENBSD_BOOTDATA); -- 2.20.1