1 " ***********************************************************
 2 " *                                                         *
 3 " * Copyright, (C) Honeywell Bull Inc., 1987                *
 4 " *                                                         *
 5 " * Copyright, (C) Honeywell Information Systems Inc., 1982 *
 6 " *                                                         *
 7 " ***********************************************************
 8 
 9 " BOOTLOAD_0 -- First program to run appended in Bootload Multics
10 " This program is derived variously from FWLOAD and bootstrap1.
11 " 10/03/80, W. Olin Sibert
12 " 04/21/81, Chris Jones
13 " 1982-06-29 BIM
14 " 1982-11-17 CAH
15 " 84-05-17 KPL renamed from bootload_1
16 
17           name      bootload_0
18 
19           include   bootload_equs
20 " ^L
21 " Here is storage for a stack for calls in the collection 0 environment.
22 " The Bentry and Breturn macros in bootload_equs.incl.alm manage it,
23 " using id and di modifiers. Max depth is entry_stack_size.
24 " The segdef is provided for debuggers.
25 
26           equ       entry_stack_size,16
27 
28           segdef    entry_stack,entry_stack_ptr
29 
30           arg       -1                            " make sure no one pops this
31 entry_stack:
32           bss       ,entry_stack_size
33 
34 entry_stack_ptr:
35           vfd       18/entry_stack,12/entry_stack_size,6/0
36 " ^L
37 " Here begins the main portion of collection 0 bootload. It basically falls
38 " through a set of subroutine calls until it is finally done and then
39 " transfers to bootload_1 to get the environment set up. Most of the real
40 " work is done outside this program -- bootload_0 is mostly just a driver.
41 
42           segdef    begin
43 
44 begin:
45           tsx2      bootload_io$preinit           " make sense of the bootload program
46 
47           tsx2      bootload_flagbox$preinit      " Make BOS work with us, not against us.
48 
49           tsx2      bootload_faults$init          " Set up fault_vector
50 
51           tsx2      bootload_slt_manager$init_slt " set up an initial SLT,
52 
53           tsx2      bootload_io$init              " Set up primitive I/O mechanism
54 
55           tsx2      bootload_console$init         " and the console
56 
57           tsx2      bootload_loader$init          " we can now initialize it
58 
59           tsx2      bootload_tape_fw$boot         " boot tape F/W if needed
60 
61           tsx2      bootload_loader$load_collection " Load collection 1.0
62 
63           tsx2      bootload_loader$finish        " clean up linkage
64 
65           tsx2      bootload_linker$prelink       " snap all the links
66 
67 " copy bootload_info
68 
69           sdbr      bootload_info$bce_dbr
70 
71           epbp6     bootload_info$sys_boot_info_ptr,*
72           epp5      bootload_info$structure_start
73           lda       bootload_info$structure_size
74           als       2                             " Convert to character count
75           mlr       (pr,rl),(pr,rl)               " Move the contents
76           desc9a    pr5|0,al
77           desc9a    pr6|0,al
78 
79           epplb     bootload_info$lot_ptr,*       " this is the one thing it can't do
80           tra       bootload_info$bootload_1_ptr,* " Prepare to go on to the next segment
81 
82           end       bootload_0