]>
Commit | Line | Data |
---|---|---|
1815bff5 A |
1 | ## |
2 | # Copyright (c) 1999 Apple Computer, Inc. All rights reserved. | |
3 | # | |
4 | # @APPLE_LICENSE_HEADER_START@ | |
5 | # | |
6 | # "Portions Copyright (c) 1999 Apple Computer, Inc. All Rights | |
7 | # Reserved. This file contains Original Code and/or Modifications of | |
8 | # Original Code as defined in and that are subject to the Apple Public | |
9 | # Source License Version 1.0 (the 'License'). You may not use this file | |
10 | # except in compliance with the License. Please obtain a copy of the | |
11 | # License at http://www.apple.com/publicsource and read it before using | |
12 | # this file. | |
13 | # | |
14 | # The Original Code and all software distributed under the License are | |
15 | # distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER | |
16 | # EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, | |
17 | # INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, | |
18 | # FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the | |
19 | # License for the specific language governing rights and limitations | |
20 | # under the License." | |
21 | # | |
22 | # @APPLE_LICENSE_HEADER_END@ | |
23 | ## | |
24 | # Version: 1.2.0 Date: 8-17-2000 | |
25 | use-nvramrc? true | |
26 | load-base 600000 | |
27 | diag-device | |
28 | nvramrc hex\ | |
29 | : $D find-device ;\ | |
30 | : $E device-end ;\ | |
31 | : $L BLpatch ; : $R BRpatch ;\ | |
32 | : $X execute ;\ | |
33 | : $p 0 to my-self property ;\ | |
34 | : $a " /chosen" $D $p $E ;\ | |
35 | : &c " ata-enable" $call-parent ;\ | |
36 | 10 buffer: km\ | |
37 | dev kbd\ | |
38 | get-key-map km swap move\ | |
39 | $E\ | |
40 | : ck 0 do swap dup 3 >> km + c@ 1 rot 7 and << and or loop ;\ | |
41 | : bootr 0d word count encode-string " machargs" $a\ | |
42 | 0 0 1 ck if 0 and else dup 1 = if 3d 0 1 else f 3d 0 2 then ck if 40 or then then\ | |
43 | 40 and if bye else 1e 0 do ['] boot catch drop 1f4 ms loop then bye ;\ | |
44 | : myboot boot-command eval ;\ | |
45 | dev enet\ | |
46 | ' open constant $M\ | |
47 | : $M2 $M 710 - $X ;\ | |
48 | : rl@ -7D9D40 $X ;\ | |
49 | : chstat begin $M2 $M 14f8 - $X -7D6C20 $X rl@ 400 and 0= until ;\ | |
50 | : bmstat begin $M2 $M 13F0 - $X rl@ 100 and until ;\ | |
51 | : xmt1 get-msecs $M 720 - ! chstat $M A00 - $X bmstat chstat ;\ | |
52 | ' xmt1 ' WRITE 10 + l!\ | |
53 | 62 ' READ 7 - c!\ | |
54 | : READ { _p _n ; _a } begin _p _n bead -> _a _a 2+\ | |
55 | if _p c@ 80 and 0= else 1 then until _a ;\ | |
56 | $E\ | |
57 | dev /packages/obp-tftp\ | |
58 | : $M over + ['] noop $L ;\ | |
59 | : $O ['] open + ;\ | |
60 | : $M1 dup 24 - -1720 $O $X 6 move 14 + ;\ | |
61 | -5BC $O ' $M1 $L\ | |
62 | 0 $O E8 $M EC $M F0 $M F4 $M F8 + ' true $L\ | |
63 | $E\ | |
64 | dev /packages/mac-parts\ | |
65 | : $M -7E89E0 $X 8000 alloc-mem 7F00 + 4 -7E89E0 $X ;\ | |
66 | ' load 268 - ' $M $L\ | |
67 | ' load 160 + ' 0 $L\ | |
68 | $E\ | |
69 | dev ide0\ | |
70 | : open use-ata-interface 0 &c -1 ;\ | |
71 | : set-device-ID set-drive-select ;\ | |
72 | : reset-atapi-bus reset-ata-bus ;\ | |
73 | ' reset-ata-bus 2c + ' 2 $L\ | |
74 | $E\ | |
75 | dev ide1\ | |
76 | : open use-ata-interface 0 &c -1 ;\ | |
77 | : set-device-ID set-drive-select ;\ | |
78 | : reset-atapi-bus reset-ata-bus ;\ | |
79 | ' reset-ata-bus 2c + ' 2 $L\ | |
80 | $E\ | |
81 | dev scsi\ | |
82 | : $M ['] do-cmd + ;\ | |
83 | : $M2 5 us -5f0 $M $X ;\ | |
84 | : $M3 -710 $M f over $X $X ;\ | |
85 | : $M4 1 ms ;\ | |
86 | -1AC $M ' $M2 $L\ | |
87 | 100 $M ' $M3 $L\ | |
88 | 120 $M ' $M4 $L\ | |
89 | 124 $M ' 1 $L\ | |
90 | $E\ | |
91 | ff000000 dup dup 400 28 do-map 4+ w@ 10 and 0=\ | |
92 | if 90b7 f3000032 w! then\ | |
93 | unselect-dev |