Re: Oopses trace report... (repost, wrong attachment format, sorry!)

Manfred Spraul (manfreds@colorfullife.com)
Fri, 31 Dec 1999 10:03:29 +0100


This is a multi-part message in MIME format.
--------------D448DB697FDBAE7DF7F5332F
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Agus Budy Wuysang wrote:
> Trace; c01acf90 <lk_lockmsg+1199/1221>
^^^^^^^^^
You are running an SMP kernel.

> >>EIP; c014a312 <sockfd_lookup+4a/98> <=====
> >>EIP; c012912f <get_empty_filp+2b/114> <=====
> [...]
And the filp table got corrupted.

Could you try the attached patch? It's a known problem of
ibcs-2.1-981105.

--
	Manfred
--------------D448DB697FDBAE7DF7F5332F
Content-Type: text/plain; charset=us-ascii;
 name="patch_ibcs-2.1-981105"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="patch_ibcs-2.1-981105"

Only in current: INFO.SMP diff -u -r 2.1-981105/iBCSemul/emulate.c current/iBCSemul/emulate.c --- 2.1-981105/iBCSemul/emulate.c Mon Jun 29 23:52:38 1998 +++ current/iBCSemul/emulate.c Sun May 2 17:18:57 1999 @@ -24,6 +24,13 @@ * the Linux TCP/IP stack. * -- Mike Jagdis (jaggy@purplet.demon.co.uk) * + * May 01 1999 + * Bugfix for Linux 2.2.x: + * You must own the kernel lock if you use fget(), fput() etc. + * I added lock_kernel() and unlock_kernel() to the main entry + * point. + * -- Manfred Spraul (masp0008@stud.uni-sb.de) + * * $Id: emulate.c,v 1.41 1998/06/29 21:52:38 jaggy Exp $ * $Source: /u/CVS/ibcs/iBCSemul/emulate.c,v $ */ @@ -54,6 +61,7 @@ #include <ibcs/ibcs.h> #include <ibcs/abi4.h> #include <ibcs/xnx.h> +#include <asm/smplock.h> #ifdef EMU_SVR4 #include <ibcs/svr4.h> @@ -139,6 +147,7 @@ #ifdef IBCS_TRACE int id = ++ibcs_id; #endif + lock_kernel(); /* First decide which personality map we should be looking * at by looking at the personality of this process. @@ -155,6 +164,7 @@ #endif regs->eflags |= 1; /* Set carry flag */ regs->eax = iABI_errors(EINVAL); + unlock_kernel(); return; } @@ -180,6 +190,7 @@ #endif regs->eflags |= 1; /* Set carry flag */ regs->eax = iABI_errors(EINVAL); + unlock_kernel(); return; } @@ -256,6 +267,7 @@ signr+1, sig_names[signr]); } #endif + unlock_kernel(); return; case Spl: rvalue = ((sysfun_p)kfunc)(regs); @@ -344,6 +356,7 @@ current->signal.sig[0]); } #endif + unlock_kernel(); } diff -u -r 2.1-981105/iBCSemul/solaris.c current/iBCSemul/solaris.c --- 2.1-981105/iBCSemul/solaris.c Tue Jun 9 23:57:27 1998 +++ current/iBCSemul/solaris.c Sun May 2 17:19:46 1999 @@ -28,6 +28,13 @@ * Linux/SPARC Solaris emulation * Separated from main program to avoid ifdef mania. * + * May 01 1999 + * Bugfix for Linux 2.2.x: + * You must own the kernel lock if you use fget(), fput() etc. + * I added lock_kernel() and unlock_kernel() to the main entry + * point. THIS CODE IS UNTESTED. + * -- Manfred Spraul (masp0008@stud.uni-sb.de) + * * $Id: solaris.c,v 1.7 1998/06/09 21:57:27 jaggy Exp $ * $Source: /u/CVS/ibcs/iBCSemul/solaris.c,v $ */ @@ -60,6 +67,7 @@ #include <ibcs/xnx.h> #include <ibcs/svr4.h> +#include <asm/smplock.h> #ifdef IBCS_TRACE #include <ibcs/trace.h> @@ -134,6 +142,7 @@ #ifdef IBCS_TRACE int id = ++ibcs_id; #endif + lock_kernel(); syscall = regs->u_regs [UREG_G1]; #if 0 @@ -141,6 +150,7 @@ #endif if (syscall > ELEMENTS(Solaris_funcs)){ send_sig(SIGSEGV, current, 1); + unlock_kernel(); return; } #if 0 @@ -204,6 +214,7 @@ signr+1, sig_names[signr]); } #endif + unlock_kernel(); return; case Spl: rvalue = ((sysfun_p)kfunc)(regs); @@ -256,6 +267,7 @@ rvalue, rvalue); #endif set_result (regs, rvalue); + unlock_kernel(); }

--------------D448DB697FDBAE7DF7F5332F--

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/