-- Boot.mesa (last edited by: Forrest on: July 15, 1980 10:10 PM)
DIRECTORY
Device USING [Type],
File USING [ID, nullID, PageNumber],
Mopcodes USING [zEXCH, zLI1, zLP, zPOP],
Volume USING [Type];
Boot: DEFINITIONS =
BEGIN
-- Basic request to germ
Request: TYPE = MACHINE DEPENDENT RECORD [
action: Action, location: Location];
pRequest: POINTER TO Request = LOOPHOLE[1360B]; -- relative to germ’s MDS
-- NOTE: pRequest+SIZE[Request] must not be greater than 1400B, the start of the GFT.
Action: TYPE = RECORD [CARDINAL];
inLoad: Action = [0]; -- restore volatile processor state from BootFile-format snapshot
outLoad: Action = [1]; -- save volatile processor state in BootFile-format snapshot
bootPhysicalVolume: Action = [2]; -- do inLoad using Location specified indirectly in pilot entry of PVBootFiles array of physical volume root page of disk specified by accompanying Location
teledebug: Action = [3];
noOp: Action = [4]; -- simply Enter and Exit germ
pInitialLink: POINTER--TO ControlDefs.ControlLink-- = LOOPHOLE[1376B]; -- itself an indirect control link within germ MDS
-- Description of boot file location
Location: TYPE = MACHINE DEPENDENT RECORD [
deviceType: Device.Type, -- e.g. diablo31, sa4000, ethernet
deviceOrdinal: CARDINAL, -- position of device within all those of same type
vp: SELECT OVERLAID * FROM
disk => [diskFileID: DiskFileID],
ethernet => [bootFileNumber: CARDINAL, net, host: CARDINAL ← 0],
any => [a, b, c, d, e, f, g, h: UNSPECIFIED],
ENDCASE];
-- NOTE: The notion of a device ordinal is intended to be a function purely of a hardware configuration, and not of the microcode or heads running on that configuration. This eases the problem of microcode swapping.
DiskFileID: TYPE = MACHINE DEPENDENT RECORD [
fID: File.ID,
firstPage: File.PageNumber,
da: DiskAddress];
DiskAddress: TYPE = PRIVATE RECORD [UNSPECIFIED, UNSPECIFIED];
-- Convention: a DiskFileID is null if its fID is null
nullDiskFileID: DiskFileID = [File.nullID, 0, [0, 0]]; -- delete this
-- Description of boot files pointed to from root pages of physical and logical volumes
-- The following cannot be changed without invalidating all Pilot volumes
BootFileType: TYPE = {hardMicrocode, softMicrocode, germ, pilot, debugger, debuggee};
PVBootFiles: TYPE = ARRAY BootFileType[hardMicrocode..pilot] OF DiskFileID;
LVBootFiles: TYPE = ARRAY BootFileType OF DiskFileID;
VolumeType: TYPE = Volume.Type;
-- Miscellaneous useful definitions
LP: PROCEDURE [lowbits, highbits: UNSPECIFIED] RETURNS [LONG POINTER] =
MACHINE CODE BEGIN END;
MDSIndex: TYPE = [0..256);
ReadMDS: PROCEDURE RETURNS [MDSIndex] = -- HighHalf[LONG[LOOPHOLE[1, POINTER]]] triggers compiler bug
MACHINE CODE BEGIN Mopcodes.zLI1; Mopcodes.zLP; Mopcodes.zEXCH; Mopcodes.zPOP END;
END.
LOG
Time: September 13, 1979 6:03 PMBy: McJonesAction: Create file
Time: January 25, 1980 4:22 PMBy: McJonesAction: Add bootPhysicalVolume and noOp Request’s and ethernet Location
Time: January 25, 1980 6:37 PMBy: McJonesAction: Replace Location.device with Location.deviceType and .deviceOrdinal
Time: April 17, 1980 12:41 AMBy: ForrestAction: Added teledebug
Time: April 17, 1980 10:39 AMBy: LuniewskiAction: Added net and host to Location.ethernet
Time: July 15, 1980 10:09 PMBy: ForrestAction: Add NoOp; refer to Volume.Type