Path: utzoo!attcan!uunet!mcsun!ukc!edcastle!aipna!almond!awb From: awb@almond.ed.ac.uk (Alan W Black) Newsgroups: comp.os.minix Subject: Re: Receiving General Protection panic from 386 Minix Keywords: general protection 386 Message-ID: <3070@aipna.ed.ac.uk> Date: 23 Sep 90 14:21:06 GMT References: <1990Sep22.055445.15470@dsuvax.uucp> Sender: news@aipna.ed.ac.uk Reply-To: awb@almond.UUCP (Alan W Black) Organization: Dept of AI, Edinburgh, UK Lines: 52 In article <1990Sep22.055445.15470@dsuvax.uucp> ghelmer@dsuvax.uucp (Guy Helmer) writes: >I just built the 386 version of MINIX, and I've been searching for >the source of this error for several hours now. I receive a >general protection from process number 1, pc = 0x0007:0x00000385 >and the friendly "Kernel panic: exception in kernel, mm, or fs" >message immediately after pressing the '=' key at the boot menu. >I'm trying to run this without shoelace or db. > > [details deleted] > >Guy Helmer >work: DSU Computing Services, Business & Education Institute (605) 256-5315 >play: MidIX System Support Services (605) 256-2788 >helmer@sdnet.bitnet, ghelmer@dsuvax.uucp, uunet!loft386!dsuvax!ghelmer I recently did this on a 386 machine. After a lot of searching and debugging we discovered that the system corrupts itself when booting. We basically we had two problem one ours and one caused by a problem in bootblok.s (as distributed -- I got mine from plains.nodak.edu) If the size of the kernel is one sector bigger that the number of tracks being loaded, it misses the last sector. The fix is something like (sorry I don't have the actual bootblok.s here) at the end of the loop where it is loading sectors mov ax,disksec | see if we are done loading cmp ax,final | ditto jb load | jump if there is more to load You should (I believe) decrement disksec before doing the test. I can't remember if this is right but it definately in this area and after we changed this it worked. Now it happens that if you build a kernel with the small number of disk buffers (in minix/config.h) i.e. not the INTEL_32BITS default but the old default. It will work without the above change. The other problem (which I actually think is what you are getting first). There were no instructions on how to build the default db (x386_1.1/tools/db.s) I originally simply bcc'd it but it seems it should be that you build the .o file then ld it on its own without the library. (thanks to Richard Tobin for doing most of this debugging) Hope this doesn't just confuse the issue Alan Alan W Black 80 South Bridge, Edinburgh, UK Dept of Artificial Intelligence tel: (+44) -31 225 7774 x228 or x223 University of Edinburgh email: awb@ed.ac.uk