Your message dated Tue, 28 Jun 2016 20:23:04 +0000
with message-id <[email protected]>
and subject line Bug#825189: fixed in kexec-tools 1:2.0.12-1
has caused the Debian Bug report #825189,
regarding kexec-tools: Fix kexec failure when compiled with gcc > v5 (see LP: 
#1546260)
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)


-- 
825189: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=825189
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: kexec-tools
Version: 1:2.0.10-1
Severity: important
Tags: patch
User: [email protected]
Usertags: origin-ubuntu yakkety ubuntu-patch

Dear Maintainer,

The following bug was reported and fixed in the latest ubuntu version
(16.04 Xenial) :

 https://bugs.launchpad.net/ubuntu/+source/kexec-tools/+bug/1546260

Would you please consider it for inclusion into the latest kexec-tools
package ? Detailed analysis and test results are described in the cited
bug above.


*** /tmp/tmpAyQrrj/bug_body

In Ubuntu, the attached patch was applied to achieve the following:



  * [PowerPC64] Fix failure in purgatory when compiled with gcc5
    Application of upstream fixes so kexec-tools work with gcc5 on PowerPC64

    commit 4a2ae3a39c64dc43e9d094be9541253234ff4822,
    1e423dc297d10eb7ff25c829d2856ef12fc81d77,
    3debb8cf3272216119cb2e59a4963ce3c18fe8e3
    [lp: #1546260]
   

Thanks for considering the patch.


-- System Information:
Debian Release: stretch/sid
  APT prefers yakkety
  APT policy: (500, 'yakkety')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.4.0-22-generic (SMP w/4 CPU cores)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
diff -Nru kexec-tools-2.0.10/debian/control kexec-tools-2.0.10/debian/control
--- kexec-tools-2.0.10/debian/control	2015-12-03 21:44:02.000000000 +0100
+++ kexec-tools-2.0.10/debian/control	2016-05-24 14:17:39.000000000 +0200
@@ -2,8 +2,7 @@
 Section: admin
 Homepage: http://kernel.org/pub/linux/utils/kernel/kexec/
 Priority: optional
-Maintainer: Ubuntu Developers <[email protected]>
-XSBC-Original-Maintainer: Khalid Aziz <[email protected]>
+Maintainer: Khalid Aziz <[email protected]>
 Build-Depends: debhelper (>= 7.0.0), dh-autoreconf, gnu-efi (>=3.0a-4)[ia64], libz-dev[ia64], po-debconf
 Standards-Version: 3.9.6
 
diff -Nru kexec-tools-2.0.10/debian/patches/lp1546260-fix-purgatory-fail-gcc5.patch kexec-tools-2.0.10/debian/patches/lp1546260-fix-purgatory-fail-gcc5.patch
--- kexec-tools-2.0.10/debian/patches/lp1546260-fix-purgatory-fail-gcc5.patch	1970-01-01 01:00:00.000000000 +0100
+++ kexec-tools-2.0.10/debian/patches/lp1546260-fix-purgatory-fail-gcc5.patch	2016-03-25 16:55:53.000000000 +0100
@@ -0,0 +1,265 @@
+Description: [PowerPC64] Fix failure in purgatory when compiled with gcc5
+ Application of upstream fixes so kexec-tools work with gcc5 on PowerPC64
+
+ commit	4a2ae3a39c64dc43e9d094be9541253234ff4822
+ Pass struct mem_sym into machine_apply_elf_rel()
+ On PowerPC64 ABIv2 we need to look at the symbol to determine
+ if it has a local entry point. Pass struct mem_sym into
+ machine_apply_elf_rel() so we can.
+
+ commit	1e423dc297d10eb7ff25c829d2856ef12fc81d77
+ ppc64: purgatory: Handle local symbols in ELF ABIv2
+ The PowerPC64 ELF ABIv2 has the concept of global and local symbols
+ and information on this is encoded in sym->st_other. When doing a
+ R_PPC64_REL24 branch we want to hit the local entry point, so adjust
+ it as necessary.
+
+ commit	3debb8cf3272216119cb2e59a4963ce3c18fe8e3
+ Properly align powerpc64 .toc
+ gcc leaves .toc byte aligned, relying on the linker to align the section.
+ 	* kexec/arch/ppc64/kexec-elf-rel-ppc64.c (machine_verify_elf_rel):
+	  Fudge alignment of .toc section.
+
+Author: Anton Blanchard <[email protected]>, Alan Modra <[email protected]>
+Origin: <upstream>
+Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/kexec-tools/+bug/1546260
+--- a/kexec/arch/arm/kexec-elf-rel-arm.c
++++ b/kexec/arch/arm/kexec-elf-rel-arm.c
+@@ -18,8 +18,9 @@
+ 	return 1;
+ }
+ 
+-void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr), unsigned long r_type,
+-	void *location, unsigned long address, unsigned long value)
++void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
++	struct mem_sym *UNUSED(sym), unsigned long r_type, void *location,
++	unsigned long address, unsigned long value)
+ {
+ 	switch(r_type) {
+ 	case R_ARM_ABS32:
+--- a/kexec/arch/cris/kexec-elf-rel-cris.c
++++ b/kexec/arch/cris/kexec-elf-rel-cris.c
+@@ -29,8 +29,9 @@
+ 	return 1;
+ }
+ 
+-void machine_apply_elf_rel(struct mem_ehdr *ehdr, unsigned long r_type,
+-	void *location, unsigned long address, unsigned long value)
++void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
++	struct mem_sym *UNUSED(sym), unsigned long r_type, void *location,
++	unsigned long address, unsigned long value)
+ {
+ 	switch(r_type) {
+ 
+--- a/kexec/arch/i386/kexec-elf-rel-x86.c
++++ b/kexec/arch/i386/kexec-elf-rel-x86.c
+@@ -18,8 +18,9 @@
+ 	return 1;
+ }
+ 
+-void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr), unsigned long r_type,
+-	void *location, unsigned long address, unsigned long value)
++void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
++	struct mem_sym *UNUSED(sym), unsigned long r_type, void *location,
++	unsigned long address, unsigned long value)
+ {
+ 	switch(r_type) {
+ 	case R_386_32:
+--- a/kexec/arch/ia64/kexec-elf-rel-ia64.c
++++ b/kexec/arch/ia64/kexec-elf-rel-ia64.c
+@@ -72,8 +72,9 @@
+         return insn & ~0xfUL;
+ }
+ 
+-void machine_apply_elf_rel(struct mem_ehdr *ehdr, unsigned long r_type,
+-	void *location, unsigned long address, unsigned long value)
++void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
++	struct mem_sym *UNUSED(sym), unsigned long r_type, void *location,
++	unsigned long address, unsigned long value)
+ {
+ 	uint64_t gp_value = ehdr->rel_addr + 0x200000;
+ 	switch(r_type) {
+--- a/kexec/arch/m68k/kexec-elf-rel-m68k.c
++++ b/kexec/arch/m68k/kexec-elf-rel-m68k.c
+@@ -23,7 +23,9 @@
+ 	return 1;
+ }
+ 
+-void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr), unsigned long r_type,
++void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
++			   struct mem_sym *UNUSED(sym),
++			   unsigned long r_type,
+ 			   void *UNUSED(location),
+ 			   unsigned long UNUSED(address),
+ 			   unsigned long UNUSED(value))
+--- a/kexec/arch/mips/kexec-elf-rel-mips.c
++++ b/kexec/arch/mips/kexec-elf-rel-mips.c
+@@ -29,7 +29,9 @@
+ 	return 1;
+ }
+ 
+-void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr), unsigned long r_type,
++void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
++			   struct mem_sym *UNUSED(sym),
++			   unsigned long r_type,
+ 			   void *UNUSED(location),
+ 			   unsigned long UNUSED(address),
+ 			   unsigned long UNUSED(value))
+--- a/kexec/arch/ppc64/kexec-elf-rel-ppc64.c
++++ b/kexec/arch/ppc64/kexec-elf-rel-ppc64.c
+@@ -5,17 +5,23 @@
+ #include "../../kexec-elf.h"
+ #include "kexec-ppc64.h"
+ 
+-int machine_verify_elf_rel(struct mem_ehdr *ehdr)
+-{
+-	if (ehdr->ei_class != ELFCLASS64) {
+-		return 0;
+-	}
+-	if (ehdr->e_machine != EM_PPC64) {
+-		return 0;
+-	}
++#if defined(_CALL_ELF) && _CALL_ELF == 2
++#define STO_PPC64_LOCAL_BIT	5
++#define STO_PPC64_LOCAL_MASK	(7 << STO_PPC64_LOCAL_BIT)
++#define PPC64_LOCAL_ENTRY_OFFSET(other) \
++ (((1 << (((other) & STO_PPC64_LOCAL_MASK) >> STO_PPC64_LOCAL_BIT)) >> 2) << 2)
+ 
+-	return 1;
++static unsigned int local_entry_offset(struct mem_sym *sym)
++{
++	/* If this symbol has a local entry point, use it. */
++	return PPC64_LOCAL_ENTRY_OFFSET(sym->st_other);
+ }
++#else
++static unsigned int local_entry_offset(struct mem_sym *UNUSED(sym))
++{
++	return 0;
++}
++#endif
+ 
+ static struct mem_shdr *toc_section(const struct mem_ehdr *ehdr)
+ {
+@@ -34,6 +40,24 @@
+ 	return NULL;
+ }
+ 
++int machine_verify_elf_rel(struct mem_ehdr *ehdr)
++{
++	struct mem_shdr *toc;
++
++	if (ehdr->ei_class != ELFCLASS64) {
++		return 0;
++	}
++	if (ehdr->e_machine != EM_PPC64) {
++		return 0;
++	}
++
++	/* Ensure .toc is sufficiently aligned.  */
++	toc = toc_section(ehdr);
++	if (toc && toc->sh_addralign < 256)
++		toc->sh_addralign = 256;
++	return 1;
++}
++
+ /* r2 is the TOC pointer: it actually points 0x8000 into the TOC (this
+    gives the value maximum span in an instruction which uses a signed
+    offset) */
+@@ -63,8 +87,9 @@
+ 	*location = (*location & ~mask) | (value & mask);
+ }
+ 
+-void machine_apply_elf_rel(struct mem_ehdr *ehdr, unsigned long r_type,
+-	void *location, unsigned long address, unsigned long value)
++void machine_apply_elf_rel(struct mem_ehdr *ehdr, struct mem_sym *sym,
++	unsigned long r_type, void *location, unsigned long address,
++	unsigned long value)
+ {
+ 	switch(r_type) {
+ 	case R_PPC64_ADDR32:
+@@ -113,6 +138,7 @@
+ 		break;
+ 
+ 	case R_PPC64_REL24:
++		value += local_entry_offset(sym);
+ 		/* Convert value to relative */
+ 		value -= address;
+ 		if (value + 0x2000000 > 0x3ffffff || (value & 3) != 0) {
+--- a/kexec/arch/ppc/kexec-elf-rel-ppc.c
++++ b/kexec/arch/ppc/kexec-elf-rel-ppc.c
+@@ -17,8 +17,9 @@
+ 	return 1;
+ }
+ 
+-void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr), unsigned long r_type,
+-	void *location, unsigned long address, unsigned long value)
++void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
++	struct mem_sym *UNUSED(sym), unsigned long r_type, void *location,
++	unsigned long address, unsigned long value)
+ {
+ 	switch(r_type) {
+ 	case R_PPC_ADDR32:
+--- a/kexec/arch/s390/kexec-elf-rel-s390.c
++++ b/kexec/arch/s390/kexec-elf-rel-s390.c
+@@ -23,7 +23,8 @@
+ 	return 1;
+ }
+ 
+-void machine_apply_elf_rel(struct mem_ehdr *ehdr,
++void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
++			   struct mem_sym *UNUSED(sym),
+ 			   unsigned long r_type,
+ 			   void *loc,
+ 			   unsigned long address,
+--- a/kexec/arch/sh/kexec-elf-rel-sh.c
++++ b/kexec/arch/sh/kexec-elf-rel-sh.c
+@@ -28,8 +28,9 @@
+ 	return 1;
+ }
+ 
+-void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr), unsigned long r_type,
+-	void *orig_loc, unsigned long UNUSED(address), unsigned long relocation)
++void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
++	struct mem_sym *UNUSED(sym), unsigned long r_type, void *orig_loc,
++	unsigned long UNUSED(address), unsigned long relocation)
+ {
+ 	uint32_t *location = orig_loc;
+ 	uint32_t value;
+--- a/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
++++ b/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
+@@ -57,8 +57,9 @@
+ 	return name;
+ }
+ 
+-void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr), unsigned long r_type,
+-	void *location, unsigned long address, unsigned long value)
++void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
++	struct mem_sym *UNUSED(sym), unsigned long r_type, void *location,
++	unsigned long address, unsigned long value)
+ {
+ 	dbgprintf("%s\n", reloc_name(r_type));
+ 	switch(r_type) {
+--- a/kexec/kexec-elf.h
++++ b/kexec/kexec-elf.h
+@@ -129,7 +129,8 @@
+ 
+ /* Architecture specific helper functions */
+ extern int machine_verify_elf_rel(struct mem_ehdr *ehdr);
+-extern void machine_apply_elf_rel(struct mem_ehdr *ehdr, unsigned long r_type, 
+-	void *location, unsigned long address, unsigned long value);
++extern void machine_apply_elf_rel(struct mem_ehdr *ehdr, struct mem_sym *sym,
++	unsigned long r_type, void *location, unsigned long address,
++	unsigned long value);
+ #endif /* KEXEC_ELF_H */
+ 
+--- a/kexec/kexec-elf-rel.c
++++ b/kexec/kexec-elf-rel.c
+@@ -408,7 +408,7 @@
+ 			dbgprintf("sym: %s value: %lx addr: %lx\n",
+ 				name, value, address);
+ 
+-			machine_apply_elf_rel(ehdr, rel.r_type,
++			machine_apply_elf_rel(ehdr, &sym, rel.r_type,
+ 				(void *)location, address, value);
+ 		}
+ 	}
diff -Nru kexec-tools-2.0.10/debian/patches/series kexec-tools-2.0.10/debian/patches/series
--- kexec-tools-2.0.10/debian/patches/series	2015-12-03 21:44:14.000000000 +0100
+++ kexec-tools-2.0.10/debian/patches/series	2016-03-25 16:55:53.000000000 +0100
@@ -7,3 +7,4 @@
 # const_string_warning.patch - use format-security.patch instead
 powerpcspe_support.patch
 format-security.patch
+lp1546260-fix-purgatory-fail-gcc5.patch

--- End Message ---
--- Begin Message ---
Source: kexec-tools
Source-Version: 1:2.0.12-1

We believe that the bug you reported is fixed in the latest version of
kexec-tools, which is due to be installed in the Debian FTP archive.

A summary of the changes between this version and the previous one is
attached.

Thank you for reporting the bug, which will now be closed.  If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.

Debian distribution maintenance software
pp.
Khalid Aziz <[email protected]> (supplier of updated kexec-tools package)

(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512

Format: 1.8
Date: Fri, 24 Jun 2016 14:22:01 -0600
Source: kexec-tools
Binary: kexec-tools kexec-tools-udeb
Architecture: source amd64
Version: 1:2.0.12-1
Distribution: unstable
Urgency: medium
Maintainer: Khalid Aziz <[email protected]>
Changed-By: Khalid Aziz <[email protected]>
Description:
 kexec-tools - tools to support fast kexec reboots
 kexec-tools-udeb - tools to support fast kexec reboots (udeb) (udeb)
Closes: 752790 783239 819601 821073 821441 825189
Changes:
 kexec-tools (1:2.0.12-1) unstable; urgency=medium
 .
   * New upstream release
   * Upstream release no longer uses build date in version
     (Closes: #783239)
   * Fix kexec failures when compiled with gcc > v5 (Closes: #825189)
   * Add support for scripts in /etc/defauls/kexec.d (Closes: #752790)
   * Update japaneses translation (Closes: #819601)
   * Update french translation (Closes: #821073)
   * Update dutch translation (Closes: #821441)
Checksums-Sha1:
 e281694a3031b3cd4fc5047db5a01918eec53755 2192 kexec-tools_2.0.12-1.dsc
 cd2c84512e5d8a82e4e6fef717369210f2d6c058 383768 kexec-tools_2.0.12.orig.tar.gz
 be1daabe6d037e5e18477ded1c2d0323649db531 22252 
kexec-tools_2.0.12-1.debian.tar.xz
 cc2e83feb280c942bf5407b15c04d8ae75edbde5 162070 
kexec-tools-dbgsym_2.0.12-1_amd64.deb
 4c4e731530c3952a3f9daad2227892158a8570a2 53038 
kexec-tools-udeb_2.0.12-1_amd64.udeb
 fb40edcc287e664bffd4163026d30a4d6b1574cd 81352 kexec-tools_2.0.12-1_amd64.deb
Checksums-Sha256:
 0bb8b5d2b2d48f0b2a286ad4650fca18d3f262da9e59025a9531ae790aa4dc37 2192 
kexec-tools_2.0.12-1.dsc
 cc7b60dad0da202004048a6179d8a53606943062dd627a2edba45a8ea3a85135 383768 
kexec-tools_2.0.12.orig.tar.gz
 d443c3e6b22dc8028cc853b74869d7b2c6fb911ade03af88508ec4aefde42941 22252 
kexec-tools_2.0.12-1.debian.tar.xz
 b0a4157577828f77b72c48847b08f3de88baf14ca474076cf4c952a43ff9b60c 162070 
kexec-tools-dbgsym_2.0.12-1_amd64.deb
 14b2360e472886a6f9d141d729a91487d97d8e4e41119941a5a475521460a8fc 53038 
kexec-tools-udeb_2.0.12-1_amd64.udeb
 09c43a91fad51aa02715ccbd53d9071c2f30866db28c39bb0cd09ac709bd61b5 81352 
kexec-tools_2.0.12-1_amd64.deb
Files:
 72e6c4f4245179a96de2984a1b2447f6 2192 admin optional kexec-tools_2.0.12-1.dsc
 10ddaae0e86af54407b164a1f5a39cc3 383768 admin optional 
kexec-tools_2.0.12.orig.tar.gz
 1d8804cbca8fcd0ee472ddc80a3e879b 22252 admin optional 
kexec-tools_2.0.12-1.debian.tar.xz
 1904853584f813d24a22055d75a2e0e9 162070 debug extra 
kexec-tools-dbgsym_2.0.12-1_amd64.deb
 fd413f4cf8b122b1032202616d10d8e6 53038 debian-installer optional 
kexec-tools-udeb_2.0.12-1_amd64.udeb
 ca132dd83f1ac867c1ad15bad097006a 81352 admin optional 
kexec-tools_2.0.12-1_amd64.deb
Package-Type: udeb

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1

iQIcBAEBCgAGBQJXcscBAAoJEM1YobF+0DP6mW0QAJnBe+SVRSmFhcsUFh0L3LgV
86dv7/AD9BG13GAtPibfRossi8M/UjxZIP6HsKEB+FJDtXUlaps6RYo7QxGnFQp3
e7jIg7nSwugr/tkanJWbC1sEO9C5DfIrgIntWBqL/eniy5hXUho914yW3/An6vr3
I4IRyywlTH4ZELlPIcpcAkNvASHny1sxxvZkiZQK8KlWLwl2kDrBn3aswh/O2/4N
0rd1dGQoWEK/OpHX2OJt1Uzp8l8SC2NhoFX5FHxE3X5UJll27cLNVD/hyyMThb98
4pZozherprtVB1qV8qTCKVhXiLYsdZaNrHcPbvv9Y6Txy4wz8dX1NRG60o7yY2MY
MKVsdPKqQPFxWDDxQHCJjcgO7p61buYQgk0c85dk657dhy/zL3kGxV+CTwTLBlpe
nfSUTDtLwSckGH+qDkxvL8TckXG3rzhzVrlXE0jLD1uz5SEWoHHNZUg/ebBtW8f1
Evp92HlUJwCs+kVzdMGhCUr4Wz1zms6qZI3bR9/SiymtfjTgbs8+z/yGbM+89vVd
Z/DNukO5BTfN815k8lkzB4AYoJAOJBPJDzl46uuIIdfUGvr4cm/Aei1f7mw7069T
ywxbBLnA1Zsf28qSwTh5oX+kJivOkI3c7hFUSwI6vWT7ZIZLDrvDtLmZ8lKcO7Oa
rCIomCoGY2d4kesmx6Sc
=j5uH
-----END PGP SIGNATURE-----

--- End Message ---

Reply via email to