From owner-freebsd-hardware@FreeBSD.ORG Thu Mar 11 10:06:01 2004 Return-Path: Delivered-To: freebsd-hardware@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E405516A52C for ; Thu, 11 Mar 2004 10:06:00 -0800 (PST) Received: from mail6.speakeasy.net (mail6.speakeasy.net [216.254.0.206]) by mx1.FreeBSD.org (Postfix) with ESMTP id BC4DF43D41 for ; Thu, 11 Mar 2004 10:06:00 -0800 (PST) (envelope-from jhb@FreeBSD.org) Received: (qmail 21294 invoked from network); 11 Mar 2004 18:05:59 -0000 Received: from dsl027-160-063.atl1.dsl.speakeasy.net (HELO server.baldwin.cx) ([216.27.160.63]) (envelope-sender ) encrypted SMTP for ; 11 Mar 2004 18:05:59 -0000 Received: from 10.50.40.205 (gw1.twc.weather.com [216.133.140.1]) by server.baldwin.cx (8.12.10/8.12.10) with ESMTP id i2BI5h2D036973; Thu, 11 Mar 2004 13:05:56 -0500 (EST) (envelope-from jhb@FreeBSD.org) From: John Baldwin To: Jason Dictos Date: Thu, 11 Mar 2004 12:32:42 -0500 User-Agent: KMail/1.6 References: In-Reply-To: MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <200403111232.42294.jhb@FreeBSD.org> X-Spam-Checker-Version: SpamAssassin 2.63 (2004-01-11) on server.baldwin.cx cc: "''freebsd-hardware@freebsd.org' '" Subject: Re: How to use int 13 while BSD is running X-BeenThere: freebsd-hardware@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: General discussion of FreeBSD hardware List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 11 Mar 2004 18:06:01 -0000 On Thursday 11 March 2004 12:55 am, Jason Dictos wrote: > Hello again. > > I did some reading on the pentium processor manual, and I think I > finally understand what the set of vm86 functions do. They use the intel > processors virtual 8086 processor compatability mode to issue virtual > interrups. My question is now, what prevents such int 13 type interrups > using the vm86 set of apis (as found in biosdisk.c, in the BTX loader code) > from working from working in a standard BSD running system? Well, for one thing, the BIOS drivers for your hardware are going to want working interrupts, and running in a full BSD kernel isn't going to give you that. Since BTX routes all interrupts via vm86 mode back to the original real mode interrupt handlers, it still works ok for any device that has a BIOS. It might be possible to achieve this with a BSD kernel but it would be a pain. One problem is that you don't know what IRQs the hardware is using. Note that the BTX user app has a mostly flat address space that allows it to get to everything above 0x10000 (I think that's the number, might be 0xa000). Trying to get multithreading plus vm86 interrupt handlers is going to require a good bit of work either way (either trying to let the kernel do vm86 interrupts or trying to extend BTX to allow multiple tasks). -- John Baldwin <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" = http://www.FreeBSD.org