PupEtherBoot.mesa
Copyright © 1986 by Xerox Corporation. All rights reserved.
Hal Murray, December 22, 1986 12:05:28 pm PST
DIRECTORY
BootFile USING [Location],
Commander USING [CommandProc, Register],
Device USING [Ethernet, Type],
DeviceCleanup USING [Perform],
GermSwap USING [InLoad, Switches],
PrincOpsUtils USING [DisableInterrupts],
SystemVersion USING [machineType],
VMBacking USING [RecoverRealMemory];
PupEtherBoot:
CEDAR
PROGRAM
IMPORTS Commander, DeviceCleanup, GermSwap, PrincOpsUtils, SystemVersion, VMBacking
SHARES Device = {
Create: Commander.CommandProc = {
bootFileNumber: CARDINAL ← GetBootFileNumber[];
switches: GermSwap.Switches; -- defaults
location: BootFile.Location ← [
deviceType: Device.Type[FIRST[Device.Ethernet]], -- Want "ethernet"
deviceOrdinal: 0,
vp: ethernetBSP [bootFileNumber: bootFileNumber, net: [0], host: [0]] ];
switches[l] ← TRUE;
switches[f] ← TRUE;
TRUSTED {
PrincOpsUtils.DisableInterrupts[]; -- make it hold still first
VMBacking.RecoverRealMemory[]; -- so that the germ can find it for the next guy.
DeviceCleanup.Perform[turnOff];
GermSwap.InLoad[NIL, NIL, 0, @location, switches];
};
};
DontKnowAboutThisTypeOfMachine: ERROR = CODE;
GetBootFileNumber:
PROC
RETURNS [
CARDINAL] = {
Check /Indigo/Portola/BootDirectory.txt or /Dexter//Dexter.txt for more info.
SELECT SystemVersion.machineType
FROM
dorado => RETURN[45103B]; -- BasicCedarDorado.boot
dandelion => RETURN[5200B];-- BasicCedarDLion20.pb
ENDCASE => ERROR DontKnowAboutThisTypeOfMachine;
};
Commander.Register["PupEtherBoot", Create, "Pup Etherboot this machine."];
}.