Accepting request 417886 from Kernel:kdump

1

OBS-URL: https://build.opensuse.org/request/show/417886
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/kexec-tools?expand=0&rev=115
This commit is contained in:
Dominique Leuenberger 2016-08-12 13:36:17 +00:00 committed by Git OBS Bridge
commit 3cfde08b27
5 changed files with 37 additions and 44 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:14ce67b6242426a7ded10f58b7d29d3cfef5c1379850e8ba3816bb42053f920d
size 274776

View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:874baf421171dbfca0084af2da71ccf5a67749dd2a27c3023da5f72460bae5cc
size 276824

View File

@ -9,11 +9,20 @@ Signed-off-by: Dirk Müller <dmueller@suse.com>
Signed-off-by: Geoff Levand <geoff@infradead.org> Signed-off-by: Geoff Levand <geoff@infradead.org>
diff --git a/configure.ac b/configure.ac ---
index 31d1bbe..c6e8bd6 100644 configure.ac | 3
kexec/Makefile | 1
kexec/arch/arm64/Makefile | 17 ++
kexec/arch/arm64/include/arch/options.h | 30 ++++
kexec/arch/arm64/kexec-arm64.c | 223 ++++++++++++++++++++++++++++++++
kexec/arch/arm64/kexec-arm64.h | 28 ++++
kexec/arch/arm64/kexec-elf-arm64.c | 147 +++++++++++++++++++++
kexec/kexec-syscall.h | 9 +
8 files changed, 456 insertions(+), 2 deletions(-)
--- a/configure.ac --- a/configure.ac
+++ b/configure.ac +++ b/configure.ac
@@ -35,6 +35,9 @@ case $target_cpu in @@ -34,6 +34,9 @@ case $target_cpu in
ARCH="ppc64" ARCH="ppc64"
SUBARCH="LE" SUBARCH="LE"
;; ;;
@ -23,11 +32,9 @@ index 31d1bbe..c6e8bd6 100644
arm* ) arm* )
ARCH="arm" ARCH="arm"
;; ;;
diff --git a/kexec/Makefile b/kexec/Makefile
index 7d3175b..9777ec3 100644
--- a/kexec/Makefile --- a/kexec/Makefile
+++ b/kexec/Makefile +++ b/kexec/Makefile
@@ -71,6 +71,7 @@ KEXEC_SRCS += $($(ARCH)_FS2DT) @@ -75,6 +75,7 @@ KEXEC_SRCS += $($(ARCH)_MEM_REGIONS)
include $(srcdir)/kexec/arch/alpha/Makefile include $(srcdir)/kexec/arch/alpha/Makefile
include $(srcdir)/kexec/arch/arm/Makefile include $(srcdir)/kexec/arch/arm/Makefile
@ -35,9 +42,6 @@ index 7d3175b..9777ec3 100644
include $(srcdir)/kexec/arch/i386/Makefile include $(srcdir)/kexec/arch/i386/Makefile
include $(srcdir)/kexec/arch/ia64/Makefile include $(srcdir)/kexec/arch/ia64/Makefile
include $(srcdir)/kexec/arch/m68k/Makefile include $(srcdir)/kexec/arch/m68k/Makefile
diff --git a/kexec/arch/arm64/Makefile b/kexec/arch/arm64/Makefile
new file mode 100644
index 0000000..8b7f8a5
--- /dev/null --- /dev/null
+++ b/kexec/arch/arm64/Makefile +++ b/kexec/arch/arm64/Makefile
@@ -0,0 +1,17 @@ @@ -0,0 +1,17 @@
@ -58,9 +62,6 @@ index 0000000..8b7f8a5
+ kexec/arch/arm64/kexec-arm64.h + kexec/arch/arm64/kexec-arm64.h
+ +
+LIBS += -lfdt +LIBS += -lfdt
diff --git a/kexec/arch/arm64/include/arch/options.h b/kexec/arch/arm64/include/arch/options.h
new file mode 100644
index 0000000..c9a0287
--- /dev/null --- /dev/null
+++ b/kexec/arch/arm64/include/arch/options.h +++ b/kexec/arch/arm64/include/arch/options.h
@@ -0,0 +1,30 @@ @@ -0,0 +1,30 @@
@ -94,12 +95,9 @@ index 0000000..c9a0287
+struct arm64_opts arm64_opts; +struct arm64_opts arm64_opts;
+ +
+#endif /* KEXEC_ARCH_ARM64_OPTIONS_H */ +#endif /* KEXEC_ARCH_ARM64_OPTIONS_H */
diff --git a/kexec/arch/arm64/kexec-arm64.c b/kexec/arch/arm64/kexec-arm64.c
new file mode 100644
index 0000000..e02c38d
--- /dev/null --- /dev/null
+++ b/kexec/arch/arm64/kexec-arm64.c +++ b/kexec/arch/arm64/kexec-arm64.c
@@ -0,0 +1,228 @@ @@ -0,0 +1,223 @@
+/* +/*
+ * ARM64 kexec support. + * ARM64 kexec support.
+ */ + */
@ -293,7 +291,7 @@ index 0000000..e02c38d
+ unsigned long kexec_flags) + unsigned long kexec_flags)
+{ +{
+ /* FIXME: Should get this info from device tree. */ + /* FIXME: Should get this info from device tree. */
+ +
+ return get_memory_ranges_1(range, ranges, kexec_flags); + return get_memory_ranges_1(range, ranges, kexec_flags);
+} +}
+ +
@ -310,27 +308,19 @@ index 0000000..e02c38d
+} +}
+ +
+ +
+int machine_verify_elf_rel(struct mem_ehdr *ehdr) +int machine_verify_elf_rel(struct mem_ehdr *UNUSED(ehdr))
+{ +{
+ (void)ehdr;
+
+ fprintf(stderr, "%s:%d: do\n", __func__, __LINE__); + fprintf(stderr, "%s:%d: do\n", __func__, __LINE__);
+ return 0; + return 0;
+} +}
+ +
+void machine_apply_elf_rel(struct mem_ehdr *ehdr, unsigned long r_type, +void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
+ void *location, unsigned long address, unsigned long value) + struct mem_sym *UNUSED(sym), unsigned long UNUSED(r_type),
+ void *UNUSED(location), unsigned long UNUSED(address),
+ unsigned long UNUSED(value))
+{ +{
+ (void)ehdr;
+ (void)r_type;
+ (void)location;
+ (void)address;
+ (void)value;
+ fprintf(stderr, "%s:%d: do\n", __func__, __LINE__); + fprintf(stderr, "%s:%d: do\n", __func__, __LINE__);
+} +}
diff --git a/kexec/arch/arm64/kexec-arm64.h b/kexec/arch/arm64/kexec-arm64.h
new file mode 100644
index 0000000..673d525
--- /dev/null --- /dev/null
+++ b/kexec/arch/arm64/kexec-arm64.h +++ b/kexec/arch/arm64/kexec-arm64.h
@@ -0,0 +1,28 @@ @@ -0,0 +1,28 @@
@ -362,9 +352,6 @@ index 0000000..673d525
+off_t initrd_size; +off_t initrd_size;
+ +
+#endif +#endif
diff --git a/kexec/arch/arm64/kexec-elf-arm64.c b/kexec/arch/arm64/kexec-elf-arm64.c
new file mode 100644
index 0000000..b267a15
--- /dev/null --- /dev/null
+++ b/kexec/arch/arm64/kexec-elf-arm64.c +++ b/kexec/arch/arm64/kexec-elf-arm64.c
@@ -0,0 +1,147 @@ @@ -0,0 +1,147 @@
@ -395,7 +382,7 @@ index 0000000..b267a15
+ struct mem_ehdr ehdr; + struct mem_ehdr ehdr;
+ +
+ fprintf(stderr, "%s:%d: ->\n", __func__, __LINE__); + fprintf(stderr, "%s:%d: ->\n", __func__, __LINE__);
+ +
+ result = build_elf_exec_info(buf, len, &ehdr, 0); + result = build_elf_exec_info(buf, len, &ehdr, 0);
+ +
+ if (result < 0) { + if (result < 0) {
@ -459,7 +446,7 @@ index 0000000..b267a15
+ char *buf; + char *buf;
+ +
+ buf = slurp_file(arm64_opts.ramdisk, &initrd_size); + buf = slurp_file(arm64_opts.ramdisk, &initrd_size);
+ +
+ if (!buf) + if (!buf)
+ fprintf(stderr, "kexec: empty ramdisk file\n"); + fprintf(stderr, "kexec: empty ramdisk file\n");
+ else { + else {
@ -483,7 +470,7 @@ index 0000000..b267a15
+ fdt32_to_cpu(*(uint32_t*)dtb_buf), *(uint32_t*)dtb_buf); + fdt32_to_cpu(*(uint32_t*)dtb_buf), *(uint32_t*)dtb_buf);
+ +
+ result = fdt_check_header(dtb_buf); + result = fdt_check_header(dtb_buf);
+ +
+ if (result) { + if (result) {
+ fprintf(stderr, "Invalid FDT.\n"); + fprintf(stderr, "Invalid FDT.\n");
+ return -1; + return -1;
@ -515,8 +502,6 @@ index 0000000..b267a15
+{ +{
+ fprintf(stderr, "%s:%d\n", __func__, __LINE__); + fprintf(stderr, "%s:%d\n", __func__, __LINE__);
+} +}
diff --git a/kexec/kexec-syscall.h b/kexec/kexec-syscall.h
index 6238044..ccca19c 100644
--- a/kexec/kexec-syscall.h --- a/kexec/kexec-syscall.h
+++ b/kexec/kexec-syscall.h +++ b/kexec/kexec-syscall.h
@@ -39,8 +39,8 @@ @@ -39,8 +39,8 @@
@ -530,7 +515,7 @@ index 6238044..ccca19c 100644
#endif #endif
#if defined(__mips__) #if defined(__mips__)
#define __NR_kexec_load 4311 #define __NR_kexec_load 4311
@@ -76,6 +76,8 @@ static inline long kexec_load(void *entry, unsigned long nr_segments, @@ -108,6 +108,8 @@ static inline long kexec_file_load(int k
#define KEXEC_ARCH_PPC64 (21 << 16) #define KEXEC_ARCH_PPC64 (21 << 16)
#define KEXEC_ARCH_IA_64 (50 << 16) #define KEXEC_ARCH_IA_64 (50 << 16)
#define KEXEC_ARCH_ARM (40 << 16) #define KEXEC_ARCH_ARM (40 << 16)
@ -539,7 +524,7 @@ index 6238044..ccca19c 100644
#define KEXEC_ARCH_S390 (22 << 16) #define KEXEC_ARCH_S390 (22 << 16)
#define KEXEC_ARCH_SH (42 << 16) #define KEXEC_ARCH_SH (42 << 16)
#define KEXEC_ARCH_MIPS_LE (10 << 16) #define KEXEC_ARCH_MIPS_LE (10 << 16)
@@ -121,5 +123,8 @@ static inline long kexec_load(void *entry, unsigned long nr_segments, @@ -153,5 +155,8 @@ static inline long kexec_file_load(int k
#ifdef __m68k__ #ifdef __m68k__
#define KEXEC_ARCH_NATIVE KEXEC_ARCH_68K #define KEXEC_ARCH_NATIVE KEXEC_ARCH_68K
#endif #endif

View File

@ -1,3 +1,11 @@
-------------------------------------------------------------------
Mon Aug 8 10:47:36 UTC 2016 - ptesarik@suse.com
- Update to version 2.0.13
Changelog: http://git.kernel.org/cgit/utils/kernel/kexec/kexec-tools.git/log/?id=refs/tags/v2.0.12..v2.0.13
- Refresh kexec-tools-enable-aarch64.patch
------------------------------------------------------------------- -------------------------------------------------------------------
Fri Jun 17 11:44:18 UTC 2016 - normand@linux.vnet.ibm.com Fri Jun 17 11:44:18 UTC 2016 - normand@linux.vnet.ibm.com

View File

@ -28,7 +28,7 @@ Requires(postun): coreutils
Summary: Tools for fast kernel loading Summary: Tools for fast kernel loading
License: GPL-2.0+ License: GPL-2.0+
Group: System/Kernel Group: System/Kernel
Version: 2.0.12 Version: 2.0.13
Release: 0 Release: 0
Source: ftp://kernel.org/pub/linux/utils/kernel/kexec/%{name}-%{version}.tar.xz Source: ftp://kernel.org/pub/linux/utils/kernel/kexec/%{name}-%{version}.tar.xz
Source1: kexec-bootloader Source1: kexec-bootloader