Commit | Line | Data |
---|---|---|
920dae64 AT |
1 | # ========== Copyright Header Begin ========================================== |
2 | # | |
3 | # Hypervisor Software File: dropins.src | |
4 | # | |
5 | # Copyright (c) 2006 Sun Microsystems, Inc. All Rights Reserved. | |
6 | # | |
7 | # - Do no alter or remove copyright notices | |
8 | # | |
9 | # - Redistribution and use of this software in source and binary forms, with | |
10 | # or without modification, are permitted provided that the following | |
11 | # conditions are met: | |
12 | # | |
13 | # - Redistribution of source code must retain the above copyright notice, | |
14 | # this list of conditions and the following disclaimer. | |
15 | # | |
16 | # - Redistribution in binary form must reproduce the above copyright notice, | |
17 | # this list of conditions and the following disclaimer in the | |
18 | # documentation and/or other materials provided with the distribution. | |
19 | # | |
20 | # Neither the name of Sun Microsystems, Inc. or the names of contributors | |
21 | # may be used to endorse or promote products derived from this software | |
22 | # without specific prior written permission. | |
23 | # | |
24 | # This software is provided "AS IS," without a warranty of any kind. | |
25 | # ALL EXPRESS OR IMPLIED CONDITIONS, REPRESENTATIONS AND WARRANTIES, | |
26 | # INCLUDING ANY IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A | |
27 | # PARTICULAR PURPOSE OR NON-INFRINGEMENT, ARE HEREBY EXCLUDED. SUN | |
28 | # MICROSYSTEMS, INC. ("SUN") AND ITS LICENSORS SHALL NOT BE LIABLE FOR | |
29 | # ANY DAMAGES SUFFERED BY LICENSEE AS A RESULT OF USING, MODIFYING OR | |
30 | # DISTRIBUTING THIS SOFTWARE OR ITS DERIVATIVES. IN NO EVENT WILL SUN | |
31 | # OR ITS LICENSORS BE LIABLE FOR ANY LOST REVENUE, PROFIT OR DATA, OR | |
32 | # FOR DIRECT, INDIRECT, SPECIAL, CONSEQUENTIAL, INCIDENTAL OR PUNITIVE | |
33 | # DAMAGES, HOWEVER CAUSED AND REGARDLESS OF THE THEORY OF LIABILITY, | |
34 | # ARISING OUT OF THE USE OF OR INABILITY TO USE THIS SOFTWARE, EVEN IF | |
35 | # SUN HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES. | |
36 | # | |
37 | # You acknowledge that this software is not designed, licensed or | |
38 | # intended for use in the design, construction, operation or maintenance of | |
39 | # any nuclear facility. | |
40 | # | |
41 | # ========== Copyright Header End ============================================ | |
42 | # id: @(#)dropins.src 1.1 07/04/30 | |
43 | # purpose: list the dropins required by this platform | |
44 | # copyright: Copyright 2007 Sun Microsystems, Inc. All rights reserved. | |
45 | # copyright: Use is subject to license terms. | |
46 | # | |
47 | # | |
48 | # Format: key <data> | |
49 | # build <command to run> | |
50 | # depend <file> | |
51 | # target <dropin-src> <dropin-name> | |
52 | # source{ [code] terminated by }source | |
53 | # include <file> | |
54 | # | |
55 | version2 | |
56 | ||
57 | # create the code to execute fcode dropins | |
58 | source{ | |
59 | caps off | |
60 | " /packages/SUNW,builtin-drivers" find-device | |
61 | ||
62 | headerless | |
63 | : load-driver ( str$ -- ) | |
64 | find-drop-in if ( adr,len ) | |
65 | >r dup >r 1 byte-load ( ) | |
66 | r> r> free-drop-in ( ) | |
67 | then ( ) | |
68 | ; | |
69 | headers | |
70 | ||
71 | : interrupt-property ( n -- ) " interrupts" integer-property ; | |
72 | ||
73 | : get-fcode ( adr1 len1 adr2 len2 -- true | false ) | |
74 | find-drop-in if | |
75 | 2dup >r >r | |
76 | rot min rot swap move | |
77 | r> r> free-drop-in | |
78 | true | |
79 | else 2drop false | |
80 | then | |
81 | ; | |
82 | ||
83 | headers | |
84 | ||
85 | }source | |
86 | ||
87 | build ${MAKEDI} | |
88 | ||
89 | target bootprom.bin bootprom | |
90 | ||
91 | depend ${BP}/dev/sun4v-devices/vnexus/depend.mk | |
92 | target vnexus.fc SUNW,vnexus | |
93 | source{ | |
94 | : onboard-devices ( -- ) | |
95 | diagnostic-mode? if | |
96 | ." Loading onboard drivers: " | |
97 | then | |
98 | 0 0 " 100" " /" begin-package | |
99 | " SUNW,vnexus" load-driver | |
100 | end-package | |
101 | ; | |
102 | }source | |
103 | ||
104 | # Fonts | |
105 | depend ${BP}/pkg/termemu/fonts.mk | |
106 | external font.di | |
107 | ||
108 | # Sunlogo | |
109 | depend ${BP}/pkg/sunlogo/logo.mk | |
110 | external sun-logo.di | |
111 | ||
112 | # Network boot support package | |
113 | depend ${BP}/pkg/dhcp/obptftp.mk | |
114 | external obptftp.di | |
115 | ||
116 | # legion disk | |
117 | depend ${BP}/dev/sun4v-devices/legion-disk/depend.mk | |
118 | target sim-disk.fc legion-disk | |
119 | source{ | |
120 | : disk ( -- ) " legion-disk" load-driver ; | |
121 | }source | |
122 | ||
123 | # legion NVRAM | |
124 | depend ${BP}/dev/sun4v-devices/legion-nvram/depend.mk | |
125 | target sim-nvram.fc legion-nvram | |
126 | source{ | |
127 | : nvram ( -- ) " legion-nvram" load-driver ; | |
128 | }source | |
129 | ||
130 | # virtual flashprom support | |
131 | depend ${BP}/dev/sun4v-devices/flashprom/depend.mk | |
132 | target flashprom.fc sun4v-flashprom | |
133 | source{ | |
134 | : flashprom ( -- ) " sun4v-flashprom" load-driver ; | |
135 | }source | |
136 | ||
137 | # virtual console | |
138 | depend ${BP}/dev/sun4v-devices/console/depend.mk | |
139 | target console.fc sun4v-console | |
140 | source{ | |
141 | : SUNW,sun4v-console ( -- ) " sun4v-console" load-driver ; | |
142 | }source | |
143 | ||
144 | # vchannel support | |
145 | depend ${BP}/dev/sun4v-devices/vchannel/depend.mk | |
146 | target vchannel.fc sun4v-chan-dev | |
147 | source{ | |
148 | : SUNW,sun4v-channel-devices ( -- ) " sun4v-chan-dev" load-driver ; | |
149 | }source | |
150 | ||
151 | # vNET support | |
152 | depend ${BP}/dev/sun4v-devices/vnet/depend.mk | |
153 | target vnet.fc sun4v-vnet | |
154 | source{ | |
155 | : SUNW,sun4v-network ( -- ) " sun4v-vnet" load-driver ; | |
156 | }source | |
157 | ||
158 | # vDisk support | |
159 | depend ${BP}/dev/sun4v-devices/vdisk/depend.mk | |
160 | target vdisk.fc sun4v-vdisk | |
161 | source{ | |
162 | : SUNW,sun4v-disk ( -- ) " sun4v-vdisk" load-driver ; | |
163 | }source | |
164 | ||
165 | # hypervisor TOD | |
166 | depend ${BP}/dev/sun4v-devices/tod/depend.mk | |
167 | target tod.fc sun4v-tod | |
168 | source{ | |
169 | : SUNW,sun4v-tod ( -- ) " sun4v-tod" load-driver ; | |
170 | }source | |
171 | ||
172 | # Sun4v PCI FCode driver | |
173 | depend ${BP}/dev/sun4v-devices/vpci/depend.mk | |
174 | target vpci.fc sun4v-vpci | |
175 | buildoptions vpci.fc:= FTHFLAGS += [define] 64BIT-ASSIGNED? | |
176 | source{ | |
177 | : pciex ( -- ) | |
178 | " sun4v-vpci" load-driver | |
179 | ; | |
180 | }source | |
181 | ||
182 | # Niagara2 performace counter driver | |
183 | depend ${BP}/dev/sun4v-devices/n2/perf-cntr/depend.mk | |
184 | target perf-cntr.fc sun4v-perf-cnt | |
185 | source{ | |
186 | : SUNW,n2piu-pr ( -- ) | |
187 | " sun4v-perf-cnt" load-driver | |
188 | ; | |
189 | }source | |
190 | ||
191 | # Niagara2 NIU nexus driver | |
192 | depend ${BP}/dev/sun4v-devices/niu-nexus/depend.mk | |
193 | target niu-nexus.fc niu-nexus | |
194 | source{ | |
195 | : SUNW,niumx ( -- ) | |
196 | " niu-nexus" load-driver | |
197 | ; | |
198 | }source | |
199 | ||
200 | # Niagara2 NIU network device driver | |
201 | depend ${BP}/dev/network/neptune/niu/depend.mk | |
202 | target niu.fc niu-network | |
203 | source{ | |
204 | : SUNW,niusl ( -- ) | |
205 | " niu-network" load-driver | |
206 | ; | |
207 | }source | |
208 | ||
209 | # finish the dropins | |
210 | source{ | |
211 | device-end | |
212 | caps on | |
213 | }source |