Date: Wed, 10 Mar 2004 10:52:13 -0500 From: John Baldwin <jhb@FreeBSD.org> To: Jason Dictos <jason.dictos@yosemitetech.com> Cc: "'freebsd-hardware@freebsd.org'" <freebsd-hardware@freebsd.org> Subject: Re: How to use int 13 while BSD is running Message-ID: <200403101052.13098.jhb@FreeBSD.org> In-Reply-To: <E50A109EE98AA049BAA09D725DB0714F01AD3BA1@mail.tapeware.com> References: <E50A109EE98AA049BAA09D725DB0714F01AD3BA1@mail.tapeware.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tuesday 09 March 2004 04:24 pm, Jason Dictos wrote: > Hello, > > I'm investigating what resources are out there for accessing bios > addressable devices while BSD is up and running. The situation is this, > currently we licenses Caldera DOS for a program we wrote which uses the > int13 extensions to manipulate the systems hard drive (i.e. to recover > partition tables and what not). This forces our application to be written > in 16 bit mode, but it does allows us to not have to worry about loading > any driver which would be hardware specific to access the hard drive. Is > there any way to write a driver for BSD which would put the processor into > real mode, therefore allowing us to use the int 13 api of the bios to read > and write hard drives? That way we could package a stripped down BSD kernel > which loaded our driver and gave our application access to hard disks > without having to load any device driver. > > Apologies in advance if this is the wrong mailing list, Look at the loader in src/sys/boot. It is a 32-bit C app that uses BIOS calls to access the disk. It uses a psuedo-kernel called BTX to manage interrupts in vm86 mode and run BIOS code in vm86 mode. You can probably port your software to being a custom loader that uses boot2 to boot off of a floppy. You can also use cdboot to boot a loader off of a CD or pxeboot to boot a loader image over the network. The loader uses libstand which provides several useful things like malloc/free, some basic filesystem support, etc. -- John Baldwin <jhb@FreeBSD.org> <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" = http://www.FreeBSD.org
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200403101052.13098.jhb>
