From owner-cvs-src@FreeBSD.ORG Tue Apr 22 11:50:49 2003 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 0999C37B407 for ; Tue, 22 Apr 2003 11:50:49 -0700 (PDT) Received: from mail.speakeasy.net (mail14.speakeasy.net [216.254.0.214]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9A2A043FDF for ; Tue, 22 Apr 2003 11:50:46 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Received: (qmail 26669 invoked from network); 22 Apr 2003 18:50:52 -0000 Received: from unknown (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender )encrypted SMTP for ; 22 Apr 2003 18:50:52 -0000 Received: from laptop.baldwin.cx (gw1.twc.weather.com [216.133.140.1]) by server.baldwin.cx (8.12.8/8.12.8) with ESMTP id h3MIofOv093626; Tue, 22 Apr 2003 14:50:41 -0400 (EDT) (envelope-from jhb@FreeBSD.org) Message-ID: X-Mailer: XFMail 1.5.4 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <200304220745.h3M7jljW086690@repoman.freebsd.org> Date: Tue, 22 Apr 2003 14:50:44 -0400 (EDT) From: John Baldwin To: David Xu cc: cvs-src@FreeBSD.org cc: src-committers@FreeBSD.org cc: cvs-all@FreeBSD.org Subject: RE: cvs commit: src/sys/i386/i386 trap.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Apr 2003 18:50:49 -0000 On 22-Apr-2003 David Xu wrote: > davidxu 2003/04/22 00:45:47 PDT > > FreeBSD src repository > > Modified files: > sys/i386/i386 trap.c > Log: > Fix some problems for cpu_switch_load_gs. when fault address is at > cpu_switch_load_gs, cpu is in context switch, so don't enable interrupt. > because it is in context switch, it is expected sched_lock was held, > so don't PROC_LOCK(p) and psignal, it is LOR, probably we can > set a P_XSIGBUS like flag in p_sflags, and set TDF_ASTPENDING in > td_flags, in ast(), post a SIGBUS to process if P_XSIGBUS was set. If we are in cpu_switch(), then PCPU_GET(spinlocks) should not be NULL. Oh, hmm, that only works when witness is on. :( Probably that should be 'td->td_critnest != 0'. That should remove the need for the eip check at least. Using an ast flag for to defer the SIGBUS might be the best thing to do in that case, yes. -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/