Jim, I had tried this earlier, taking COMMON code
kdb-4.3-2.6.0-test11-common1.patch (by Keith) and i386 code from
your code on linux 2.6.0. I had encountered the same two problems
which you have mentioned and the fixes rightly said by you,are in
COMMON code itself. Attached below is the patch for those two
issues to be made to the COMMON code: Correct me if I am wrong.


1. local_bh_enable( ) is to be replaced with __local_bh_enable( ) since
in an SMP environment, all CPUs other than the intial CPU would
have their IRQs disabled. Because of this, they would dump
their stack when they encounter the WARN_ON check in
local_bh_enable( ) code.


2.  I think tasklist_lock comes into picture only in case of SMP and
    to check if this lock is acquired by any other process,
    rwlock_is_locked( ) routine is to be used.


Thanks Prashanth

Jim Houston wrote:

On Mon, 2004-01-19 at 08:14, Prashanth T wrote:


Jim,
I came accross your patches on kdb-4.3 for linux2.6 on i386 at
http://www.ccur.com/isd_oss.asp
I believe that your COMMON code patch (+ some other changes superceded)
are included in the common patch put by Keith
ftp://oss.sgi.com/projects/kdb/download/v4.3/kdb-v4.3-2.6.0-test11-common-1.bz2


I was wondering why your i386 patches are NOT seen there in the list?
Or is it under progress?



Hi Prashanth, Keith,


I had assumed that Keith Owen's release included the i386
support.  I guess I was premature in declaring my patch obsolete.

I spent this most of the day doing a "quick" merge to see if Keith's
common code would work with my i386 changes.  It does.
I'm working with a 2.6.1 kernel and have a couple problems which
are in the common code.

    -   This warning when I do a go command:
        "Badness in local_bh_enable at kernel/softirq.c:121"

- The kdb kill command has compile errors.

I hope to have a new patch on the web tomorrow.

Jim Houston - Concurrent Computer Corp.







--- linux-2.6.0-kdb-COMMON/kdb/kdbmain.c        2004-01-20 10:41:15.575577432 +0530
+++ linux-2.6.0-kdb-COMMON-mod/kdb/kdbmain.c    2004-01-19 13:40:53.000000000 +0530
@@ -1967,7 +1967,7 @@
                KDB_DEBUG_STATE("kdb 15", result);
                kdb_bp_install_local(regs);
                kdba_enable_lbr();
-               local_bh_enable();
+               __local_bh_enable();
                KDB_STATE_CLEAR(KDB_CONTROL);
        }
 
@@ -3168,11 +3168,13 @@
        }
        spin_unlock(&p->sighand->siglock);
        /* Where's read_trylock? */
-       if (tasklist_lock.write_lock) {
+#if defined(CONFIG_SMP)
+       if (rwlock_is_locked(&tasklist_lock)) {
                kdb_printf("Can't do kill command now.\n"
                        "The runqueue lock is held somewhere else in kernel, try again 
later\n");
                return 0;
        }
+#endif
        info.si_signo = sig;
        info.si_errno = 0;
        info.si_code = SI_USER;

Reply via email to