reset upstream subtrees to yocto 2.6

Reset the following subtrees on thud HEAD:

  poky: 87e3a9739d
  meta-openembedded: 6094ae18c8
  meta-security: 31dc4e7532
  meta-raspberrypi: a48743dc36
  meta-xilinx: c42016e2e6

Also re-apply backports that didn't make it into thud:
  poky:
    17726d0 systemd-systemctl-native: handle Install wildcards

  meta-openembedded:
    4321a5d libtinyxml2: update to 7.0.1
    042f0a3 libcereal: Add native and nativesdk classes
    e23284f libcereal: Allow empty package
    030e8d4 rsyslog: curl-less build with fmhttp PACKAGECONFIG
    179a1b9 gtest: update to 1.8.1

Squashed OpenBMC subtree compatibility updates:
  meta-aspeed:
    Brad Bishop (1):
          aspeed: add yocto 2.6 compatibility

  meta-ibm:
    Brad Bishop (1):
          ibm: prepare for yocto 2.6

  meta-ingrasys:
    Brad Bishop (1):
          ingrasys: set layer compatibility to yocto 2.6

  meta-openpower:
    Brad Bishop (1):
          openpower: set layer compatibility to yocto 2.6

  meta-phosphor:
    Brad Bishop (3):
          phosphor: set layer compatibility to thud
          phosphor: libgpg-error: drop patches
          phosphor: react to fitimage artifact rename

    Ed Tanous (4):
          Dropbear: upgrade options for latest upgrade
          yocto2.6: update openssl options
          busybox: remove upstream watchdog patch
          systemd: Rebase CONFIG_CGROUP_BPF patch

Change-Id: I7b1fe71cca880d0372a82d94b5fd785323e3a9e7
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
diff --git a/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame-1.6.6/0001-symbol-Account-for-prelinked-shared-objects.patch b/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame-1.6.6/0001-symbol-Account-for-prelinked-shared-objects.patch
new file mode 100644
index 0000000..3eefc9c
--- /dev/null
+++ b/meta-openembedded/meta-python/recipes-devtools/python/python-pyflame-1.6.6/0001-symbol-Account-for-prelinked-shared-objects.patch
@@ -0,0 +1,134 @@
+From 007965d341349679607699d005c4af811b2c419a Mon Sep 17 00:00:00 2001
+From: Andrew Jeffery <andrew@aj.id.au>
+Date: Fri, 4 May 2018 11:23:53 +0930
+Subject: [PATCH] symbol: Account for prelinked shared objects
+
+Some projects, such as those derived from Yocto, tend to prelink their
+binaries and libraries to reduce runtime overhead. Currently this trips
+up pyflame in its symbol address calculations, and leads to ptrace
+failures due to spurious addresses:
+
+   $ pyflame -t python -c "print 'foo'"
+   Unexpected ptrace(2) exception: Failed to PTRACE_PEEKDATA (pid 1482, addr 0x9f9b1d70): Input/output error
+   Unexpected ptrace(2) exception: Failed to PTRACE_PEEKDATA (pid 1482, addr 0x9f9b1d70): Input/output error
+   Unexpected ptrace(2) exception: Failed to PTRACE_PEEKDATA (pid 1482, addr 0x9f9b1d70): Input/output error
+   Unexpected ptrace(2) exception: Failed to PTRACE_PEEKDATA (pid 1482, addr 0x9f9b1d70): Input/output error
+   Unexpected ptrace(2) exception: Failed to PTRACE_PEEKDATA (pid 1482, addr 0x9f9b1d70): Input/output error
+   ...
+
+Add support for reading a prelinked base p_vaddr out of the ELF and
+adjust the PyAddresses values accordingly.
+
+Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
+---
+ src/symbol.cc | 15 +++++++++++++++
+ src/symbol.h  | 29 ++++++++++++++++++++++++++++-
+ 2 files changed, 43 insertions(+), 1 deletion(-)
+
+diff --git a/src/symbol.cc b/src/symbol.cc
+index 125174efeeb5..39c3e8132dd1 100644
+--- a/src/symbol.cc
++++ b/src/symbol.cc
+@@ -166,6 +166,17 @@ PyABI ELF::WalkTable(int sym, int str, PyAddresses *addrs) {
+   return abi;
+ }
+ 
++addr_t ELF::GetBaseAddress() {
++  int32_t phnum = hdr()->e_phnum;
++  int32_t i;
++  for (i = 0; i < phnum && phdr(i)->p_type != PT_LOAD; i++) {
++  }
++  if (i == phnum) {
++    throw FatalException("Failed to find PT_LOAD entry in program headers");
++  }
++  return phdr(i)->p_vaddr;
++}
++
+ PyAddresses ELF::GetAddresses(PyABI *abi) {
+   PyAddresses addrs;
+   PyABI detected_abi = WalkTable(dynsym_, dynstr_, &addrs);
+@@ -176,6 +187,10 @@ PyAddresses ELF::GetAddresses(PyABI *abi) {
+   if (abi != nullptr) {
+     *abi = detected_abi;
+   }
++  // Handle prelinked shared objects
++  if (hdr()->e_type == ET_DYN) {
++    return addrs - GetBaseAddress();
++  }
+   return addrs;
+ }
+ }  // namespace pyflame
+diff --git a/src/symbol.h b/src/symbol.h
+index 124853bcc1c1..bb92b9a2604b 100644
+--- a/src/symbol.h
++++ b/src/symbol.h
+@@ -28,15 +28,19 @@
+ 
+ #if USE_ELF64
+ #define ehdr_t Elf64_Ehdr
++#define phdr_t Elf64_Phdr
+ #define shdr_t Elf64_Shdr
+ #define dyn_t Elf64_Dyn
+ #define sym_t Elf64_Sym
++#define addr_t Elf64_Addr
+ #define ARCH_ELFCLASS ELFCLASS64
+ #else
+ #define ehdr_t Elf32_Ehdr
++#define phdr_t Elf32_Phdr
+ #define shdr_t Elf32_Shdr
+ #define dyn_t Elf32_Dyn
+ #define sym_t Elf32_Sym
++#define addr_t Elf32_Addr
+ #define ARCH_ELFCLASS ELFCLASS32
+ #endif
+ 
+@@ -67,8 +71,18 @@ struct PyAddresses {
+         interp_head_hint(0),
+         pie(false) {}
+ 
++  PyAddresses operator-(const unsigned long base) const {
++    PyAddresses res(*this);
++    res.tstate_addr = this->tstate_addr == 0 ? 0 : this->tstate_addr - base;
++    res.interp_head_addr =
++        this->interp_head_addr == 0 ? 0 : this->interp_head_addr - base;
++    res.interp_head_fn_addr =
++        this->interp_head_fn_addr == 0 ? 0 : this->interp_head_fn_addr - base;
++    return res;
++  }
++
+   PyAddresses operator+(const unsigned long base) const {
+-    PyAddresses res;
++    PyAddresses res(*this);
+     res.tstate_addr = this->tstate_addr == 0 ? 0 : this->tstate_addr + base;
+     res.interp_head_addr =
+         this->interp_head_addr == 0 ? 0 : this->interp_head_addr + base;
+@@ -113,6 +127,9 @@ class ELF {
+   // ABI.
+   PyAddresses GetAddresses(PyABI *abi);
+ 
++  // Extract the base load address from the Program Header table
++  addr_t GetBaseAddress();
++
+  private:
+   void *addr_;
+   size_t length_;
+@@ -122,6 +139,16 @@ class ELF {
+     return reinterpret_cast<const ehdr_t *>(addr_);
+   }
+ 
++  inline const phdr_t *phdr(int idx) const {
++    if (idx < 0) {
++      std::ostringstream ss;
++      ss << "Illegal phdr index: " << idx;
++      throw FatalException(ss.str());
++    }
++    return reinterpret_cast<const phdr_t *>(p() + hdr()->e_phoff +
++                                            idx * hdr()->e_phentsize);
++  }
++
+   inline const shdr_t *shdr(int idx) const {
+     if (idx < 0) {
+       std::ostringstream ss;
+-- 
+2.14.1
+