From owner-freebsd-current Fri Jul 5 23:25:27 2002 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 468FE37B400 for ; Fri, 5 Jul 2002 23:25:24 -0700 (PDT) Received: from harrier.mail.pas.earthlink.net (harrier.mail.pas.earthlink.net [207.217.120.12]) by mx1.FreeBSD.org (Postfix) with ESMTP id EA32943E09 for ; Fri, 5 Jul 2002 23:25:23 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from pool0156.cvx40-bradley.dialup.earthlink.net ([216.244.42.156] helo=mindspring.com) by harrier.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 17Qj0L-0005uX-00; Sat, 06 Jul 2002 02:25:14 -0400 Message-ID: <3D268D1F.D96BC3F9@mindspring.com> Date: Fri, 05 Jul 2002 23:24:31 -0700 From: Terry Lambert X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: David Xu Cc: Julian Elischer , Peter Wemm , FreeBSD current users Subject: Re: i386 trap code References: <20020706030306.96129.qmail@web20905.mail.yahoo.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG David Xu wrote: > > testl $PSL_VM,TF_EFLAGS(%esp) /* are we in vm86 mode? */ > > jz doreti_notvm86 > > cmpl $1,in_vm86call /* are we in a vm86 call? */ > > sorry for a bit OT, does anyone see this in_vm86call crazy global variable? > it prevents two CPUs to trap into VM86 model :( > if you have interest in fixing this problem, please have a look at PR : This is on purpose. Most BIOS implementations are non-reentrant, and if you allocate resources in the bus space to BIOS based I/O, you end up contending for it without locks. This is "crossing the beams" bad... 8-). > http://www.freebsd.org/cgi/query-pr.cgi?pr=i386/38223 > > I have also fixed the problem that VM86 call is preempted by interrupt > threads and causes system crash. newest patch can always be gotten from : > http://opensource.zjonline.com.cn/freebsd/vm86patch.tgz I saw the fix. I like it, though it doesn't fix the handling using an interrupt gate to take interrupts in VM86() mode (the FreeBSD code doesn't do this at present, but it's a problem if you run under VMWare, I think). -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message