/joh'liks/ n.,adj. 386BSD

Porting Unix to the 386: A Practical Approach



William & Lynne Jolitz


Started open source UNIX.

Appeared in part as a 17 article magazine series in 1991-1992.

Documented the "how, what, why, who, when" of porting BSD to the 386.

Done while BSD was becoming "open source".





Porting Unix to the 386: A Practical Approach - protected mode

protected mode:

Porting Unix to the 386: Three Initial PC Utilities

The second article in the "PORTING UNIX TO THE 386" series discussed the utilities we had to build to test the port on an actual 80386 PC.
By far, the most popular article.

Consistency Checks

Its not enough just to load the kernel and go, you need to insure its the kernel bit-for-bit by the time you run it.

The First PC Utility: boot.exe

Requirements for a DOS PC Utility to boot a 386BSD UNIX kernel.

Entering Protected Mode

After loading the kernel program, we enter protected mode to start up the 386BSD kernel, itself a protected mode program like its own applications.

Porting Unix to the 386: Designing the Software Specification

This, the first article, is the first published mention of 386BSD. By this time, the project had been operational for 18 months, and William Jolitz was at Berkeley working on the Net/2 release.
In this installment, we discussed the beginning of our project and the initial framework that guided our efforts, in particular, the development of the 386BSD specification.

386 Memory Management Vitals

Most popular microprocessors use either segmentation or paging to manage memory address space access. The 386 is rare in that it possesses both. In fact, since segmentation, (see Figure 3(a)), is placed on top of paging (see Figure 3(b)), you are expected to use segmentation in some form any time memory is paged. And, most important, BSD relies on paging.

Microprocessor Idiosyncrasies

Sometimes you're forced to use processor features - like hardware context switching. Origionally, the earliest versions of 386BSD didn't use the hardware context switch TSS feature - but you still had to have one anyways.

Bootstrap Operation

How to bootstrap the system from hardware, loading the kernel program, itself a protected mode executable from secondary / nonvolatile / disk storage.

Porting Unix to the 386: The Standalone System

This article, last of the original three done altogether in 1990, on getting the critical pieces functioning independantly that we needed to do the port. Once these we obtained, the kernel was inevitable.

The First Step

We stepwise proved out the running environment of program tools, program loading and execution, trap handling, stack, and support of high level language. Our project moved from fragile to substantive.

Standalone Keyboard Driver

Since we had a program running in an empty PC, we needed primative input with a keyboard driver for polled input. Used by standalone programs to boot and test parts of the kernel.

Processor Support -- i386.c

We initialized the processor with initial descriptor and page tables - one needs to run with the tables before activating memory/interrupt kernel functions.

Porting Unix to the 386: Language Tools Cross Support

We describe the need and use of a cross-support environment to create 386 code from a non-386 machine, so as to create the initial binarys before our port can generate them.

What's in the Tool Chest?

The tool chest for 386BSD cross support included compiler, assembler, loader, libraries and include files. It did not include an emulation environment.





Copyright 2006 TeleMuse Partners, William Jolitz and Lynne Jolitz