Related: bz 257201
This commit is contained in:
parent
c26c250e40
commit
bce0de7184
@ -3,3 +3,4 @@ makedumpfile.tar.gz
|
|||||||
makedumpfile-1.1.1.tar.gz
|
makedumpfile-1.1.1.tar.gz
|
||||||
kexec-tools-po.tar.gz
|
kexec-tools-po.tar.gz
|
||||||
makedumpfile-1.1.5.tar.gz
|
makedumpfile-1.1.5.tar.gz
|
||||||
|
kexec-tools-testing-20070330.tar.bz2
|
||||||
|
34
kexec-tools-1.102pre-bzimage-options.patch
Normal file
34
kexec-tools-1.102pre-bzimage-options.patch
Normal file
@ -0,0 +1,34 @@
|
|||||||
|
--- kexec-tools-testing-20070330/kexec/arch/i386/kexec-bzImage.c.orig 2007-03-30 00:34:36.000000000 -0400
|
||||||
|
+++ kexec-tools-testing-20070330/kexec/arch/i386/kexec-bzImage.c 2007-08-27 15:30:42.000000000 -0400
|
||||||
|
@@ -326,6 +326,9 @@
|
||||||
|
#define OPT_APPEND (OPT_ARCH_MAX+0)
|
||||||
|
#define OPT_RAMDISK (OPT_ARCH_MAX+1)
|
||||||
|
#define OPT_REAL_MODE (OPT_ARCH_MAX+2)
|
||||||
|
+#define OPT_ARGS_ELF (OPT_ARCH_MAX+3)
|
||||||
|
+#define OPT_ARGS_LINUX (OPT_ARCH_MAX+4)
|
||||||
|
+#define OPT_ARGS_NONE (OPT_ARCH_MAX+5)
|
||||||
|
static const struct option options[] = {
|
||||||
|
KEXEC_ARCH_OPTIONS
|
||||||
|
{ "debug", 0, 0, OPT_DEBUG },
|
||||||
|
@@ -334,6 +337,9 @@
|
||||||
|
{ "initrd", 1, 0, OPT_RAMDISK },
|
||||||
|
{ "ramdisk", 1, 0, OPT_RAMDISK },
|
||||||
|
{ "real-mode", 0, 0, OPT_REAL_MODE },
|
||||||
|
+ { "args-elf", 0, NULL, OPT_ARGS_ELF },
|
||||||
|
+ { "args-linux", 0, NULL, OPT_ARGS_LINUX },
|
||||||
|
+ { "args-none", 0, NULL, OPT_ARGS_NONE },
|
||||||
|
{ 0, 0, 0, 0 },
|
||||||
|
};
|
||||||
|
static const char short_options[] = KEXEC_ARCH_OPT_STR "d";
|
||||||
|
@@ -368,6 +374,11 @@
|
||||||
|
case OPT_REAL_MODE:
|
||||||
|
real_mode_entry = 1;
|
||||||
|
break;
|
||||||
|
+ case OPT_ARGS_ELF:
|
||||||
|
+ case OPT_ARGS_LINUX:
|
||||||
|
+ case OPT_ARGS_NONE:
|
||||||
|
+ /* we can ignore these options */
|
||||||
|
+ break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
command_line_len = 0;
|
13
kexec-tools-1.102pre-disable-kexec-test.patch
Normal file
13
kexec-tools-1.102pre-disable-kexec-test.patch
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
--- kexec-tools-testing-20070330/Makefile.old 2007-08-27 15:18:35.000000000 -0400
|
||||||
|
+++ kexec-tools-testing-20070330/Makefile 2007-08-27 15:18:52.000000000 -0400
|
||||||
|
@@ -44,8 +44,8 @@
|
||||||
|
|
||||||
|
MAN_PAGES:= kexec/kexec.8
|
||||||
|
MAN_PAGES+= kdump/kdump.8
|
||||||
|
-BINARIES_i386:= $(SBINDIR)/kexec $(PKGLIBDIR)/kexec_test
|
||||||
|
-BINARIES_x86_64:=$(SBINDIR)/kexec $(PKGLIBDIR)/kexec_test
|
||||||
|
+BINARIES_i386:= $(SBINDIR)/kexec
|
||||||
|
+BINARIES_x86_64:=$(SBINDIR)/kexec
|
||||||
|
BINARIES:=$(SBINDIR)/kexec $(SBINDIR)/kdump $(BINARIES_$(ARCH))
|
||||||
|
|
||||||
|
TARGETS:=$(BINARIES) $(MAN_PAGES)
|
11
kexec-tools-1.102pre-elf-core-type.patch
Normal file
11
kexec-tools-1.102pre-elf-core-type.patch
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
--- kexec-tools-1.101/kexec/arch/i386/kexec-x86.c.orig 2006-11-15 16:28:04.000000000 -0500
|
||||||
|
+++ kexec-tools-1.101/kexec/arch/i386/kexec-x86.c 2006-11-15 16:28:13.000000000 -0500
|
||||||
|
@@ -145,7 +145,7 @@
|
||||||
|
.serial_baud = 0,
|
||||||
|
.console_vga = 0,
|
||||||
|
.console_serial = 0,
|
||||||
|
- .core_header_type = CORE_TYPE_ELF64,
|
||||||
|
+ .core_header_type = CORE_TYPE_ELF32,
|
||||||
|
};
|
||||||
|
|
||||||
|
int arch_process_options(int argc, char **argv)
|
22
kexec-tools-1.102pre-elf-format.patch
Normal file
22
kexec-tools-1.102pre-elf-format.patch
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
--- kexec-tools-1.101/kexec/arch/x86_64/kexec-elf-x86_64.c.fix 2006-08-29 20:07:34.000000000 -0400
|
||||||
|
+++ kexec-tools-1.101/kexec/arch/x86_64/kexec-elf-x86_64.c 2006-08-29 20:08:03.000000000 -0400
|
||||||
|
@@ -120,7 +120,7 @@ int elf_x86_64_load(int argc, char **arg
|
||||||
|
/*
|
||||||
|
* Parse the command line arguments
|
||||||
|
*/
|
||||||
|
- arg_style = ARG_STYLE_ELF;
|
||||||
|
+ arg_style = ARG_STYLE_LINUX;
|
||||||
|
command_line = 0;
|
||||||
|
modified_cmdline = 0;
|
||||||
|
modified_cmdline_len = 0;
|
||||||
|
--- kexec-tools-1.101/kexec/arch/i386/kexec-elf-x86.c.fix 2006-08-29 20:07:14.000000000 -0400
|
||||||
|
+++ kexec-tools-1.101/kexec/arch/i386/kexec-elf-x86.c 2006-08-29 20:07:24.000000000 -0400
|
||||||
|
@@ -121,7 +121,7 @@ int elf_x86_load(int argc, char **argv,
|
||||||
|
/*
|
||||||
|
* Parse the command line arguments
|
||||||
|
*/
|
||||||
|
- arg_style = ARG_STYLE_ELF;
|
||||||
|
+ arg_style = ARG_STYLE_LINUX;
|
||||||
|
command_line = 0;
|
||||||
|
modified_cmdline = 0;
|
||||||
|
modified_cmdline_len = 0;
|
81
kexec-tools-1.102pre-makedumpfile-xen-syms.patch
Normal file
81
kexec-tools-1.102pre-makedumpfile-xen-syms.patch
Normal file
@ -0,0 +1,81 @@
|
|||||||
|
--- kexec-tools-1.101/makedumpfile/makedumpfile.c.orig 2007-07-27 13:16:28.000000000 -0400
|
||||||
|
+++ kexec-tools-1.101/makedumpfile/makedumpfile.c 2007-08-22 13:20:04.000000000 -0400
|
||||||
|
@@ -5195,6 +5195,9 @@
|
||||||
|
int i;
|
||||||
|
struct pt_load_segment *pls;
|
||||||
|
int ret = FALSE;
|
||||||
|
+ unsigned long long paddr;
|
||||||
|
+ off_t offset_page;
|
||||||
|
+ unsigned char *buf = NULL;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* NOTE: the first half of bitmap is not used for Xen extraction
|
||||||
|
@@ -5211,6 +5214,11 @@
|
||||||
|
strerror(errno));
|
||||||
|
goto out;
|
||||||
|
}
|
||||||
|
+ if ((buf = malloc(info->page_size)) == NULL) {
|
||||||
|
+ ERRMSG("Can't allocate memory for the page. %s\n",
|
||||||
|
+ strerror(errno));
|
||||||
|
+ goto out;
|
||||||
|
+ }
|
||||||
|
|
||||||
|
pfn = 0;
|
||||||
|
for (i = 0; i < info->num_load_memory; i++) {
|
||||||
|
@@ -5255,11 +5263,35 @@
|
||||||
|
* - xen heap area, or
|
||||||
|
* - selected domain page
|
||||||
|
*/
|
||||||
|
- if (_domain == 0 ||
|
||||||
|
+ if (!(_domain == 0 ||
|
||||||
|
(info->xen_heap_start <= pfn && pfn < info->xen_heap_end) ||
|
||||||
|
- ((count_info & 0xffff) && is_select_domain(info, _domain))) {
|
||||||
|
- set_bitmap(bm2.buf, pfn%PFN_BUFBITMAP, 1);
|
||||||
|
+ ((count_info & 0xffff) && is_select_domain(info, _domain)))) {
|
||||||
|
+ continue;
|
||||||
|
+ }
|
||||||
|
+ if (info->dump_level & DL_EXCLUDE_ZERO) {
|
||||||
|
+ paddr = (unsigned long long)pfn * info->page_size;
|
||||||
|
+ offset_page = paddr_to_offset(info, paddr);
|
||||||
|
+ if (!offset_page) {
|
||||||
|
+ ERRMSG("Can't convert physaddr(%llx) to a offset.\n",
|
||||||
|
+ paddr);
|
||||||
|
+ goto out;
|
||||||
|
+ }
|
||||||
|
+ if (lseek(info->fd_memory, offset_page,
|
||||||
|
+ SEEK_SET) == (off_t)-1) {
|
||||||
|
+ ERRMSG("Can't seek the dump memory(%s). %s\n",
|
||||||
|
+ info->name_memory, strerror(errno));
|
||||||
|
+ goto out;
|
||||||
|
+ }
|
||||||
|
+ if (read(info->fd_memory, buf, info->page_size)
|
||||||
|
+ != info->page_size) {
|
||||||
|
+ ERRMSG("Can't read the dump memory(%s). %s\n",
|
||||||
|
+ info->name_memory, strerror(errno));
|
||||||
|
+ goto out;
|
||||||
|
+ }
|
||||||
|
+ if (is_zero_page(buf, info->page_size))
|
||||||
|
+ continue;
|
||||||
|
}
|
||||||
|
+ set_bitmap(bm2.buf, pfn%PFN_BUFBITMAP, 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -5275,6 +5307,8 @@
|
||||||
|
out:
|
||||||
|
if (bm2.buf != NULL)
|
||||||
|
free(bm2.buf);
|
||||||
|
+ if (buf != NULL)
|
||||||
|
+ free(buf);
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
@@ -5546,7 +5580,7 @@
|
||||||
|
MSG("-E must be specified with --xen-syms or --xen-vmcoreinfo.\n");
|
||||||
|
goto out;
|
||||||
|
}
|
||||||
|
- info->dump_level = DL_EXCLUDE_XEN;
|
||||||
|
+ info->dump_level |= DL_EXCLUDE_XEN;
|
||||||
|
return handle_xen(info);
|
||||||
|
|
||||||
|
} else if (info->flag_rearrange) {
|
10
kexec-tools-1.102pre-ppc-fixup.patch
Normal file
10
kexec-tools-1.102pre-ppc-fixup.patch
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
--- kexec-tools-1.101/kexec/arch/ppc/kexec-ppc.c.orig 2006-07-05 16:21:50.000000000 -0400
|
||||||
|
+++ kexec-tools-1.101/kexec/arch/ppc/kexec-ppc.c 2006-07-05 16:22:01.000000000 -0400
|
||||||
|
@@ -33,7 +33,6 @@ int get_memory_ranges(struct memory_rang
|
||||||
|
memory_range[memory_ranges].type = RANGE_RAM;
|
||||||
|
memory_ranges++;
|
||||||
|
#else
|
||||||
|
-#error Please, fix this for your platform
|
||||||
|
const char iomem[] = "/proc/iomem";
|
||||||
|
char line[MAX_LINE];
|
||||||
|
FILE *fp;
|
13
kexec-tools-1.102pre-ppc64_rmo_top.patch
Normal file
13
kexec-tools-1.102pre-ppc64_rmo_top.patch
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
--- kexec-tools-testing-20070330/kexec/arch/ppc64/kexec-ppc64.c.orig 2007-03-30 00:34:36.000000000 -0400
|
||||||
|
+++ kexec-tools-testing-20070330/kexec/arch/ppc64/kexec-ppc64.c 2007-08-27 15:35:47.000000000 -0400
|
||||||
|
@@ -454,8 +454,8 @@
|
||||||
|
}
|
||||||
|
rmo_base = ((unsigned long long *)buf)[0];
|
||||||
|
rmo_top = rmo_base + ((unsigned long long *)buf)[1];
|
||||||
|
- if (rmo_top > 0x30000000UL)
|
||||||
|
- rmo_top = 0x30000000UL;
|
||||||
|
+ if (rmo_top > 0x07C00000UL)
|
||||||
|
+ rmo_top = 0x07C00000UL;
|
||||||
|
|
||||||
|
fclose(file);
|
||||||
|
closedir(cdir);
|
60
kexec-tools-1.102pre-x86-add_buffer_retry.patch
Normal file
60
kexec-tools-1.102pre-x86-add_buffer_retry.patch
Normal file
@ -0,0 +1,60 @@
|
|||||||
|
--- kexec-tools-testing-20070330/kexec/arch/i386/crashdump-x86.c.orig 2007-03-30 00:34:36.000000000 -0400
|
||||||
|
+++ kexec-tools-testing-20070330/kexec/arch/i386/crashdump-x86.c 2007-08-27 15:40:22.000000000 -0400
|
||||||
|
@@ -497,6 +497,7 @@
|
||||||
|
unsigned long sz, elfcorehdr;
|
||||||
|
int nr_ranges, align = 1024;
|
||||||
|
struct memory_range *mem_range, *memmap_p;
|
||||||
|
+ int i;
|
||||||
|
|
||||||
|
if (get_crash_memory_ranges(&mem_range, &nr_ranges) < 0)
|
||||||
|
return -1;
|
||||||
|
@@ -543,8 +544,13 @@
|
||||||
|
* elf core header segment to 16K to avoid being placed in such gaps.
|
||||||
|
* This is a makeshift solution until it is fixed in kernel.
|
||||||
|
*/
|
||||||
|
- elfcorehdr = add_buffer(info, tmp, sz, 16*1024, align, min_base,
|
||||||
|
- max_addr, -1);
|
||||||
|
+ for (i=0;i<KEXEC_MAX_SEGMENTS;i++) {
|
||||||
|
+ if ((memmap_p[i].start == 0) &&
|
||||||
|
+ (memmap_p[i].end == 0))
|
||||||
|
+ break;
|
||||||
|
+ }
|
||||||
|
+ elfcorehdr = add_buffer(info, tmp, sz, 16*1024, align, min_base,
|
||||||
|
+ memmap_p[i-1].end, -1);
|
||||||
|
dfprintf(stdout, "Created elf header segment at 0x%lx\n", elfcorehdr);
|
||||||
|
if (delete_memmap(memmap_p, elfcorehdr, sz) < 0)
|
||||||
|
return -1;
|
||||||
|
--- kexec-tools-testing-20070330/kexec/kexec.c.orig 2007-03-30 00:34:36.000000000 -0400
|
||||||
|
+++ kexec-tools-testing-20070330/kexec/kexec.c 2007-08-27 15:40:22.000000000 -0400
|
||||||
|
@@ -336,6 +336,7 @@
|
||||||
|
unsigned long base;
|
||||||
|
int result;
|
||||||
|
int pagesize;
|
||||||
|
+ int i;
|
||||||
|
|
||||||
|
result = sort_segments(info);
|
||||||
|
if (result < 0) {
|
||||||
|
@@ -345,11 +346,22 @@
|
||||||
|
/* Round memsz up to a multiple of pagesize */
|
||||||
|
pagesize = getpagesize();
|
||||||
|
memsz = (memsz + (pagesize - 1)) & ~(pagesize - 1);
|
||||||
|
-
|
||||||
|
+retry:
|
||||||
|
base = locate_hole(info, memsz, buf_align, buf_min, buf_max, buf_end);
|
||||||
|
if (base == ULONG_MAX) {
|
||||||
|
die("locate_hole failed\n");
|
||||||
|
}
|
||||||
|
+
|
||||||
|
+ for (i = 0; i < info->nr_segments; i++) {
|
||||||
|
+ if ((base < (info->segment[i].mem + info->segment[i].memsz)) &&
|
||||||
|
+ ((base+memsz) > info->segment[i].mem)) {
|
||||||
|
+ /*
|
||||||
|
+ *we have an overlap, bump down buf_max
|
||||||
|
+ */
|
||||||
|
+ buf_max = (unsigned long)info->segment[i].mem;
|
||||||
|
+ goto retry;
|
||||||
|
+ }
|
||||||
|
+ }
|
||||||
|
|
||||||
|
add_segment(info, buf, bufsz, base, memsz);
|
||||||
|
return base;
|
@ -31,8 +31,8 @@ Obsoletes: diskdumputils netdump
|
|||||||
# Patches 0 through 100 are meant for x86 kexec-tools enablement
|
# Patches 0 through 100 are meant for x86 kexec-tools enablement
|
||||||
#
|
#
|
||||||
Patch1: kexec-tools-1.101-kdump.patch
|
Patch1: kexec-tools-1.101-kdump.patch
|
||||||
Patch2: kexec-tools-1.101-elf-core-type.patch
|
Patch2: kexec-tools-1.102pre-elf-core-type.patch
|
||||||
Patch3: kexec-tools-1.101-bzimage-options.patch
|
Patch3: kexec-tools-1.102pre-bzimage-options.patch
|
||||||
Patch4: kexec-tools-1.101-relocatable-bzimage.patch
|
Patch4: kexec-tools-1.101-relocatable-bzimage.patch
|
||||||
|
|
||||||
#
|
#
|
||||||
@ -64,7 +64,7 @@ Patch303: kexec-tools-1.101-ppc64-cliargs.patch
|
|||||||
Patch304: kexec-tools-1.101-ppc64-platform-fix.patch
|
Patch304: kexec-tools-1.101-ppc64-platform-fix.patch
|
||||||
Patch305: kexec-tools-1.101-ppc64-64k-pages.patch
|
Patch305: kexec-tools-1.101-ppc64-64k-pages.patch
|
||||||
Patch306: kexec-tools-1.101-ppc64-memory_regions.patch
|
Patch306: kexec-tools-1.101-ppc64-memory_regions.patch
|
||||||
Patch307: kexec-tools-1.101-ppc64_rmo_top.patch
|
Patch307: kexec-tools-1.102pre-ppc64_rmo_top.patch
|
||||||
Patch308: kexec-tools-1.101-ppc-boots-ppc64.patch
|
Patch308: kexec-tools-1.101-ppc-boots-ppc64.patch
|
||||||
Patch309: kexec-tools-1.101-ppc64-align-dtstruct.patch
|
Patch309: kexec-tools-1.101-ppc64-align-dtstruct.patch
|
||||||
Patch310: kexec-tools-1.101-ppc64-bootargs-align.patch
|
Patch310: kexec-tools-1.101-ppc64-bootargs-align.patch
|
||||||
@ -77,7 +77,7 @@ Patch401: kexec-tools-1.101-s390-fixup.patch
|
|||||||
#
|
#
|
||||||
# Patches 501 through 600 are meant for ppc kexec-tools enablement
|
# Patches 501 through 600 are meant for ppc kexec-tools enablement
|
||||||
#
|
#
|
||||||
Patch501: kexec-tools-1.101-ppc-fixup.patch
|
Patch501: kexec-tools-1.102pre-ppc-fixup.patch
|
||||||
|
|
||||||
#
|
#
|
||||||
# Patches 601 onward are generic patches
|
# Patches 601 onward are generic patches
|
||||||
@ -85,11 +85,12 @@ Patch501: kexec-tools-1.101-ppc-fixup.patch
|
|||||||
Patch601: kexec-tools-1.101-Makefile.patch
|
Patch601: kexec-tools-1.101-Makefile.patch
|
||||||
Patch602: kexec-tools-1.101-et-dyn.patch
|
Patch602: kexec-tools-1.101-et-dyn.patch
|
||||||
Patch603: kexec-tools-1.101-page_h.patch
|
Patch603: kexec-tools-1.101-page_h.patch
|
||||||
Patch604: kexec-tools-1.101-elf-format.patch
|
Patch604: kexec-tools-1.102pre-elf-format.patch
|
||||||
Patch605: kexec-tools-1.101-ifdown.patch
|
Patch605: kexec-tools-1.101-ifdown.patch
|
||||||
Patch606: kexec-tools-1.101-reloc-update.patch
|
Patch606: kexec-tools-1.101-reloc-update.patch
|
||||||
Patch607: kexec-tools-1.101-x86-add_buffer_retry.patch
|
Patch607: kexec-tools-1.102pre-x86-add_buffer_retry.patch
|
||||||
Patch608: kexec-tools-1.101-makedumpfile-xen-syms.patch
|
Patch608: kexec-tools-1.102pre-makedumpfile-xen-syms.patch
|
||||||
|
Patch609: kexec-tools-1.102pre-disable-kexec-test.patch
|
||||||
|
|
||||||
%description
|
%description
|
||||||
kexec-tools provides /sbin/kexec binary that facilitates a new
|
kexec-tools provides /sbin/kexec binary that facilitates a new
|
||||||
@ -144,6 +145,7 @@ tar -z -x -v -f %{SOURCE9}
|
|||||||
#%patch606 -p1
|
#%patch606 -p1
|
||||||
%patch607 -p1
|
%patch607 -p1
|
||||||
%patch608 -p1
|
%patch608 -p1
|
||||||
|
%patch609 -p1
|
||||||
|
|
||||||
tar -z -x -v -f %{SOURCE13}
|
tar -z -x -v -f %{SOURCE13}
|
||||||
|
|
||||||
@ -246,9 +248,6 @@ rm -f %{_datadir}/firstboot/modules/firstboot_kdump.py
|
|||||||
%config(noreplace,missingok) %{_sysconfdir}/kdump.conf
|
%config(noreplace,missingok) %{_sysconfdir}/kdump.conf
|
||||||
%config %{_sysconfdir}/rc.d/init.d/kdump
|
%config %{_sysconfdir}/rc.d/init.d/kdump
|
||||||
%dir %{_localstatedir}/crash
|
%dir %{_localstatedir}/crash
|
||||||
%ifarch %{ix86} x86_64
|
|
||||||
%{_libdir}/kexec-tools
|
|
||||||
%endif
|
|
||||||
%{_mandir}/man8/*
|
%{_mandir}/man8/*
|
||||||
%doc News
|
%doc News
|
||||||
%doc COPYING
|
%doc COPYING
|
||||||
|
2
sources
2
sources
@ -1,3 +1,3 @@
|
|||||||
b4f7ffcc294d41a6a4c40d6e44b7734d kexec-tools-1.101.tar.gz
|
|
||||||
68f68403304c5c89c7087b07563911f8 kexec-tools-po.tar.gz
|
68f68403304c5c89c7087b07563911f8 kexec-tools-po.tar.gz
|
||||||
dbf062772132ccb43d47920df89a3cf9 makedumpfile-1.1.5.tar.gz
|
dbf062772132ccb43d47920df89a3cf9 makedumpfile-1.1.5.tar.gz
|
||||||
|
ec7cb260d6b708e14acbc74a45356d27 kexec-tools-testing-20070330.tar.bz2
|
||||||
|
Loading…
Reference in New Issue
Block a user