Hello community,
here is the log from the commit of package crash
checked in at Fri May 16 13:29:23 CEST 2008.
--------
--- crash/crash.changes 2008-04-30 18:37:02.000000000 +0200
+++ /mounts/work_src_done/STABLE/crash/crash.changes 2008-05-14 22:59:54.000000000 +0200
@@ -1,0 +2,20 @@
+Wed May 14 22:59:37 CEST 2008 - bwalle@suse.de
+
+- print the correct kernel image name in case automatic
+ decompression is used
+
+-------------------------------------------------------------------
+Wed May 14 20:29:05 CEST 2008 - bwalle@suse.de
+
+- use the patch that went upstream for the bnc#389907 fix below
+ (http://article.gmane.org/gmane.linux.kernel.crash-dump.crash-utility/1148)
+
+-------------------------------------------------------------------
+Tue May 13 20:31:21 CEST 2008 - bwalle@suse.de
+
+- Fix "crash" crashes on SLERT crashdump when running "kmem -i"
+ (bnc#389907)
+ o Use backtrace() instead of __builtin_return_address()
+ o Use address_space.__nrpages for RT kernel
+
+-------------------------------------------------------------------
New:
----
crash-builtin-return-addr
crash-rt-nrpages
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ crash.spec ++++++
--- /var/tmp/diff_new_pack.f18151/_old 2008-05-16 13:29:08.000000000 +0200
+++ /var/tmp/diff_new_pack.f18151/_new 2008-05-16 13:29:08.000000000 +0200
@@ -20,7 +20,7 @@
Url: http://people.redhat.com/anderson/
Summary: Crash utility for live systems; netdump, diskdump, LKCD or mcore dumpfiles
Version: 4.0.6.3
-Release: 1
+Release: 5
%define crash_version %(echo %{version} | cut -d . -f 1-2)
%define crash_subversion %(echo %{version} | cut -d . -f 3-4)
%define whitepaper_version 2003
@@ -40,6 +40,8 @@
Patch4: crash-fixed-uninitialised
Patch5: crash-sles9-time.patch
Patch6: crash-compressed-kernel
+Patch7: crash-builtin-return-addr
+Patch8: crash-rt-nrpages
BuildRequires: bison flex ncurses-devel zlib-devel
%description
@@ -121,6 +123,8 @@
%patch4 -p1
%patch5 -p1
%patch6 -p1
+%patch7 -p0
+%patch8 -p1
## SIAL patches
# cd sial-scripts-%{scripts_version}
## Patch here
@@ -183,6 +187,17 @@
%endif
%changelog
+* Thu May 15 2008 bwalle@suse.de
+- print the correct kernel image name in case automatic
+ decompression is used
+* Wed May 14 2008 bwalle@suse.de
+- use the patch that went upstream for the bnc#389907 fix below
+ (http://article.gmane.org/gmane.linux.kernel.crash-dump.crash-utility/1148)
+* Tue May 13 2008 bwalle@suse.de
+- Fix "crash" crashes on SLERT crashdump when running "kmem -i"
+ (bnc#389907)
+ o Use backtrace() instead of __builtin_return_address()
+ o Use address_space.__nrpages for RT kernel
* Wed Apr 30 2008 bwalle@suse.de
- update to crash 4.0-6.3
o Support for Fedora FC9 kernels containing the
++++++ crash-builtin-return-addr ++++++
Index: defs.h
===================================================================
RCS file: /nfs/projects/cvs/crash/defs.h,v
retrieving revision 1.347
diff -u -r1.347 defs.h
--- defs.h 23 Apr 2008 19:54:00 -0000 1.347
+++ defs.h 14 May 2008 15:40:40 -0000
@@ -46,6 +46,7 @@
#include
#include
#include
+#include /* backtrace() */
#define BASELEVEL_REVISION "4.0"
@@ -1797,18 +1798,18 @@
char argbuf[1];
};
-static inline void
-save_return_address(ulong *retaddr)
-{
- retaddr[0] = (ulong) __builtin_return_address(0);
-#if defined(X86) || defined(PPC) || defined(X86_64) || defined(PPC64)
- if (__builtin_frame_address(1))
- retaddr[1] = (ulong) __builtin_return_address(1);
- if (__builtin_frame_address(2))
- retaddr[2] = (ulong) __builtin_return_address(2);
- if (__builtin_frame_address(3))
- retaddr[3] = (ulong) __builtin_return_address(3);
-#endif
+#define NUMBER_STACKFRAMES 4
+
+#define SAVE_RETURN_ADDRESS(retaddr) \
+{ \
+ int i; \
+ int saved_stacks; \
+ \
+ saved_stacks = backtrace((void **)retaddr, NUMBER_STACKFRAMES); \
+ \
+ /* explicitely zero out the invalid addresses */ \
+ for (i = saved_stacks; i < NUMBER_STACKFRAMES; i++) \
+ retaddr[i] = 0; \
}
#endif /* !GDB_COMMON */
Index: symbols.c
===================================================================
RCS file: /nfs/projects/cvs/crash/symbols.c,v
retrieving revision 1.162
diff -u -r1.162 symbols.c
--- symbols.c 14 Apr 2008 17:54:56 -0000 1.162
+++ symbols.c 14 May 2008 15:55:01 -0000
@@ -8913,8 +8913,8 @@
return offset2;
if (pc->flags & DATADEBUG) {
- ulong retaddr[4] = { 0 };
- save_return_address(retaddr);
+ ulong retaddr[NUMBER_STACKFRAMES] = { 0 };
+ SAVE_RETURN_ADDRESS(retaddr);
sprintf(errmsg,
"invalid (optional) structure member offsets: %s or %s",
item1, item2);
@@ -8936,8 +8936,8 @@
return size2;
if (pc->flags & DATADEBUG) {
- ulong retaddr[4] = { 0 };
- save_return_address(retaddr);
+ ulong retaddr[NUMBER_STACKFRAMES] = { 0 };
+ SAVE_RETURN_ADDRESS(retaddr);
sprintf(errmsg, "invalid (optional) structure sizes: %s or %s",
item1, item2);
datatype_error(retaddr, errmsg, func, file, line);
@@ -8964,8 +8964,8 @@
return offset;
if (offset < 0) {
- ulong retaddr[4] = { 0 };
- save_return_address(retaddr);
+ ulong retaddr[NUMBER_STACKFRAMES] = { 0 };
+ SAVE_RETURN_ADDRESS(retaddr);
sprintf(errmsg, "invalid structure member offset: %s",
item);
datatype_error(retaddr, errmsg, func, file, line);
@@ -8982,8 +8982,8 @@
return size;
if (size < 0) {
- ulong retaddr[4] = { 0 };
- save_return_address(retaddr);
+ ulong retaddr[NUMBER_STACKFRAMES] = { 0 };
+ SAVE_RETURN_ADDRESS(retaddr);
sprintf(errmsg, "invalid structure size: %s", item);
datatype_error(retaddr, errmsg, func, file, line);
}
@@ -9051,7 +9051,7 @@
thisfile = get_thisfile();
fprintf(stderr, "[%s] error trace: ", thisfile);
- for (i = 3; i >= 0; i--) {
+ for (i = (NUMBER_STACKFRAMES-1); i >= 0; i--) {
if (retaddr[i])
fprintf(stderr, "%s%lx%s",
i == 3 ? "" : "=> ",
@@ -9065,7 +9065,7 @@
return;
}
- for (i = 0; i < 4; i++) {
+ for (i = 0; i < NUMBER_STACKFRAMES; i++) {
if (!(lookfor = retaddr[i]))
continue;
Index: tools.c
===================================================================
RCS file: /nfs/projects/cvs/crash/tools.c,v
retrieving revision 1.60
diff -u -r1.60 tools.c
--- tools.c 2 Jan 2008 14:15:13 -0000 1.60
+++ tools.c 14 May 2008 15:58:23 -0000
@@ -41,11 +41,11 @@
{
int end_of_line, new_line;
char buf[BUFSIZE];
- ulong retaddr[4] = { 0 };
+ ulong retaddr[NUMBER_STACKFRAMES] = { 0 };
va_list ap;
if (CRASHDEBUG(1) || (pc->flags & DROP_CORE)) {
- save_return_address(retaddr);
+ SAVE_RETURN_ADDRESS(retaddr);
console("error() trace: %lx => %lx => %lx => %lx\n",
retaddr[3], retaddr[2], retaddr[1], retaddr[0]);
}
++++++ crash-compressed-kernel ++++++
--- /var/tmp/diff_new_pack.f18151/_old 2008-05-16 13:29:08.000000000 +0200
+++ /var/tmp/diff_new_pack.f18151/_new 2008-05-16 13:29:08.000000000 +0200
@@ -21,9 +21,10 @@
---
defs.h | 5 +
+ kernel.c | 4 -
main.c | 24 ++++---
symbols.c | 207 ++++++++++++++++++++++++++++++++++++++++++++++++++++++--------
- 3 files changed, 202 insertions(+), 34 deletions(-)
+ 4 files changed, 204 insertions(+), 36 deletions(-)
--- a/defs.h
+++ b/defs.h
@@ -45,7 +46,7 @@
char *dumpfile; /* dumpfile or /dev/kmem */
char *live_memsrc; /* live memory driver */
char *system_map; /* get symbol values from System.map */
-@@ -3286,6 +3288,7 @@ void dump_offset_table(char *, ulong);
+@@ -3295,6 +3297,7 @@ void dump_offset_table(char *, ulong);
int is_elf_file(char *);
int is_elf_file_in_dir(const char *file, const char *dir);
int is_kernel(char *);
@@ -53,9 +54,24 @@
int file_elf_version(char *);
int is_system_map(char *);
int select_namelist(char *);
+--- a/kernel.c
++++ b/kernel.c
+@@ -3466,10 +3466,10 @@ display_sys_stats(void)
+ if (pc->system_map) {
+ fprintf(fp, " SYSTEM MAP: %s\n", pc->system_map);
+ fprintf(fp, "DEBUG KERNEL: %s %s\n",
+- pc->namelist,
++ pc->orig_namelist,
+ debug_kernel_version(pc->namelist));
+ } else
+- fprintf(fp, " KERNEL: %s\n", pc->namelist);
++ fprintf(fp, " KERNEL: %s\n", pc->orig_namelist);
+ }
+
+ if (pc->debuginfo_file)
--- a/main.c
+++ b/main.c
-@@ -305,6 +305,7 @@ main(int argc, char **argv)
+@@ -309,6 +309,7 @@ main(int argc, char **argv)
* Take the kernel and dumpfile arguments in either order.
*/
while (argv[optind]) {
@@ -63,7 +79,7 @@
if (is_remote_daemon(argv[optind])) {
if (pc->flags & DUMPFILE_TYPES) {
-@@ -317,21 +318,28 @@ main(int argc, char **argv)
+@@ -321,21 +322,28 @@ main(int argc, char **argv)
continue;
}
@@ -364,7 +380,7 @@
if (!STRNEQ(eheader, ELFMAG) || eheader[EI_VERSION] != EV_CURRENT)
return FALSE;
-@@ -2583,9 +2714,35 @@ is_kernel(char *file)
+@@ -2593,9 +2724,35 @@ is_kernel(char *file)
}
bailout:
++++++ crash-rt-nrpages ++++++
From: Bernhard Walle
Subject: [PATCH] Use address_space.__nrpages for RT kernel
References: bnc#389907
To: crash-utility@redhat.com
The patch mapping_nrpages.patch from RT kernel
Subject: mm/fs: abstract address_space::nrpages
Currently the tree_lock protects mapping->nrpages, this will not be
possible much longer. Hence abstract the access to this variable so that
it can be easily replaced by an atomic_ulong_t.
Signed-off-by: Peter Zijlstra
renames address_space.nrpages to address_space.__nrpages. This patch implements
that renaming for crash if address_space.nrpages is invalid.
Signed-off-by: Bernhard Walle
---
memory.c | 3 +++
1 file changed, 3 insertions(+)
--- a/memory.c
+++ b/memory.c
@@ -320,6 +320,9 @@ vm_init(void)
MEMBER_OFFSET_INIT(block_device_bd_disk, "block_device", "bd_disk");
MEMBER_OFFSET_INIT(inode_i_mapping, "inode", "i_mapping");
MEMBER_OFFSET_INIT(address_space_nrpages, "address_space", "nrpages");
+ if (INVALID_MEMBER(address_space_nrpages))
+ MEMBER_OFFSET_INIT(address_space_nrpages, "address_space", "__nrpages");
+
MEMBER_OFFSET_INIT(gendisk_major, "gendisk", "major");
MEMBER_OFFSET_INIT(gendisk_fops, "gendisk", "fops");
MEMBER_OFFSET_INIT(gendisk_disk_name, "gendisk", "disk_name");
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Remember to have fun...
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org
For additional commands, e-mail: opensuse-commit+help@opensuse.org