Skip to contentSkip to conversation

Announce: kdb v4.2 is available for kernel 2.4.20, i386 and ia64

DISCUSSION Keith Owens 2 participants 3 messages May 2, 2003 – May 5, 2003 KGDB / KDB /debug_core

lore
Share & tools
lore
#0 lore raw

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Content-Type: text/plain; charset=us-ascii

ftp://oss.sgi.com/projects/kdb/download/v4.2/

kdb-v4.2-2.4.20-common-1.bz2
kdb-v4.2-2.4.20-i386-1.bz2
kdb-v4.2-2.4.20-ia64-021210-1.bz2

Changelog extracts since v4.1.

2003-05-02 Keith Owens <[email protected]>

* Some architectures have problems with the initial empty kallsyms section so revert to three kallsyms passes.
* Flush buffered input at startup and at 'more' prompt.
* Only print 'more' prompt when longjmp data is available.
* Print more data for buffers and inodes.
* Disable kill command when O(1) scheduler is installed, the code needs to be redone for O(1).
* The kernel has an undocumented assumption that enable_bh() is always called with interrupts enabled, make it so.
* Print trailing punctuation even for symbols that are not in kernel.
* Add read/write access to user pages. Vamsi Krishna S., IBM
* Rename cpu_is_online to cpu_online, as in 2.5.
* O(1) scheduler removes init_task so kdb maintains its own list of active tasks.
* Delete btp 0 <cpuid> option, it needed init_tasks.
* Clean up USB keyboard support. Steven Dake.
* Sync with XFS 2.4.20 tree.
* kdb v4.2-2.4.20-common-1.

2.4.20-i386-1

2003-05-02 Keith Owens <[email protected]>

* Add kdba_fp_value().
* Limit backtrace size to catch loops.
* Add read/write access to user pages. Vamsi Krishna S., IBM
* Clean up USB keyboard support. Steven Dake.
* kdb v4.2-2.4.20-i386-1.

2.4.20-ia64-020821-1

2003-05-02 Keith Owens <[email protected]>

* Add kdba_fp_value().
* Limit backtrace size to catch loops.
* Print spinlock name in ia64_spinlock_contention.
* Tweak INIT slave stack lock and handler.
* Add read/write access to user pages. Vamsi Krishna S., IBM
* Rename cpu_is_online to cpu_online, as in 2.5.
* Clean up USB keyboard support.
* Clean up serial console support.
* kdb v4.2-2.4.20-ia64-020821-1.

v4.2/README

Starting with kdb v2.0 there is a common patch against each kernel which contains all the architecture independent code plus separate architecture dependent patches. Apply the common patch for your kernel plus at least one architecture dependent patch, the architecture patches activate kdb.

The naming convention for kdb patches is :-

vx.y The version of kdb. x.y is updated as new features are added to kdb.
-v.p.s The kernel version that the patch applies to. 's' may include -pre,
-rc or whatever numbering system the kernel keepers have thought up this week.
-common The common kdb code. Everybody needs this.

 -i386   Architecture dependent code for i386.
 -ia64   Architecture dependent code for ia64, etc.
 -n      If there are multiple kdb patches against the same kernel version then

the last number is incremented.

To build kdb for your kernel, apply the common kdb patch which is less than or equal to the kernel v.p.s, taking the highest value of '-n' if there is more than one. Apply the relevant arch dependent patch with the same value of 'vx.y-v.p.s-', taking the highest value of '-n' if there is more than one.

For example, to use kdb for i386 on kernel 2.4.20, apply
kdb-v4.2-2.4.20-common-<n> (use highest value of <n>)
kdb-v4.2-2.4.20-i386-<n> (use highest value of <n>)
in that order. To use kdb for ia64-021210 on kernel 2.4.20, apply
kdb-v4.2-2.4.20-common-<n> (use highest value of <n>)
kdb-v4.2-2.4.20-ia64-021210-<n> (use highest value of <n>)
in that order.

Use patch -p1 for all patches.

I do not have any time to work on 2.5, so there are no patches available for 2.5 kernels. If somebody wants to port the latest kdb patches to 2.5 kernels and send patches to [email protected] then I will put them up in this directory.

The kdb-smphdr* patches in the v4.0 directory are Sonic Zhang's changes to improve hardware breakpoint handling on i386 and ia64. They are not official kdb patches yet, they are available for review. They will probably fit v4.2.

The next step is to integrate Sonic Zhang's breakpoint changes into kdb and to change the kdb entry logic to cope with multiple cpus doing concurrent entry into kdb. At the moment kdb tries to serialize so it only processes one event at a time. The bad news is that this does not work well with IA64 SAL interrupts so kdb has to change. The good news is that the change will remove the deadlock when two cpus hit a breakpoint at the same time.

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: Exmh version 2.1.1 10/15/1999

iD8DBQE+shrti4UHNye0ZOoRAo/BAKCHWwL0LSjoEawaYCWT/sMVMR0FkQCgtulL 3V3BdZ5k5IuW0RL9mkSMp10=
=b/1W
-----END PGP SIGNATURE-----

#1 lore raw
Quoted 10 lines · Keith Owens

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Content-Type: text/plain; charset=us-ascii

ftp://oss.sgi.com/projects/kdb/download/v4.2/

kdb-v4.2-2.4.20-common-1.bz2
kdb-v4.2-2.4.20-i386-1.bz2
kdb-v4.2-2.4.20-ia64-021210-1.bz2

REPOST

This patch is needed as part of kdb common to get sparc64 kdb to build.

* include/linux/kdb.h references task_struct, needs to include sched.h
* kdb/kdbmain.c #define's WRAP already defined in include/asm-sparc64/termbits.h

Signature · 1 line
Thomas Duffy <[email protected]>
include/linux/kdb.h +1 -0
diff -Nur -X /home/tduffy/dontdiff linux-2.4.20+kdb-v4.2/include/linux/kdb.h linux-2.4.20+kdb-v4.2+sparc64/include/linux/kdb.h
@@ -38,6 +38,7 @@
 
 #include <linux/config.h>
 #include <linux/init.h>
+#include <linux/sched.h>
 #include <asm/kdb.h>
 
 #define KDB_MAJOR_VERSION	4
kdb/kdbmain.c +5 -5
diff -Nur -X /home/tduffy/dontdiff linux-2.4.20+kdb-v4.2/kdb/kdbmain.c linux-2.4.20+kdb-v4.2+sparc64/kdb/kdbmain.c
@@ -2570,17 +2570,17 @@
 	logsize = syslog_data[1] - syslog_data[0];
 	start = syslog_data[0] + (syslog_data[2] - syslog_data[0]) % logsize;
 	end = syslog_data[0] + (syslog_data[3] - syslog_data[0]) % logsize;
-#define WRAP(p) if (p < syslog_data[0]) p = syslog_data[1]-1; else if (p >= syslog_data[1]) p = syslog_data[0]
+#define KDB_WRAP(p) if (p < syslog_data[0]) p = syslog_data[1]-1; else if (p >= syslog_data[1]) p = syslog_data[0]
 	if (lines) {
 		char *p = end;
 		++lines;
 		do {
 			--p;
-			WRAP(p);
+			KDB_WRAP(p);
 			if (*p == '\n') {
 				if (--lines == 0) {
 					++p;
-					WRAP(p);
+					KDB_WRAP(p);
 					break;
 				}
 			}
@@ -2595,7 +2595,7 @@
 		if (!*start) {
 			while (!*start) {
 				++start;
-				WRAP(start);
+				KDB_WRAP(start);
 				if (start == end)
 					break;
 			}
@@ -2607,7 +2607,7 @@
 			c = *start;
 			++chars;
 			++start;
-			WRAP(start);
+			KDB_WRAP(start);
 			if (start == end || c == '\n')
 				break;
 		}
#2 lore raw

Re: Announce: kdb v4.2 is available for kernel 2.4.20, i386 and ia64 [and sparc64 now]

Quoted 5 lines · Thomas Duffy

This patch is needed as part of kdb common to get sparc64 kdb to build.

* include/linux/kdb.h references task_struct, needs to include sched.h
* kdb/kdbmain.c #define's WRAP already defined in include/asm-sparc64/termbits.h

Oops, guess original sent was too big for lists. This time, include link to patch.

Attached is a (link to a) forward port of the sparc64 kdb patch to v4.2 of kdb. It is still rough around the edges, but it at least builds and boots and is somewhat usable.

You must apply the kdb common patch and the patch to kdb common I sent earlier to get it to build properly.

Enjoy!

http://www.dslextreme.com/users/tomduffy/kdb-v4.2-2.4.20-sparc64-1.bz2

-tduffy

Signature · 1 line
Thomas Duffy <[email protected]>