1#include "ioconf.h"
2/*
3 * MACHINE GENERATED: DO NOT EDIT
4 *
5 * ioconf.c, from "XEN3_DOMU"
6 */
7
8#include <sys/param.h>
9#include <sys/conf.h>
10#include <sys/device.h>
11#include <sys/mount.h>
12
13static const struct cfiattrdata acpibuscf_iattrdata = {
14 "acpibus", 0, {
15 { NULL, NULL, 0 },
16 }
17};
18static const struct cfiattrdata ioapicbuscf_iattrdata = {
19 "ioapicbus", 1, {
20 { "apid", "-1", -1 },
21 }
22};
23static const struct cfiattrdata pcibuscf_iattrdata = {
24 "pcibus", 1, {
25 { "bus", "-1", -1 },
26 }
27};
28static const struct cfiattrdata xendevbuscf_iattrdata = {
29 "xendevbus", 0, {
30 { NULL, NULL, 0 },
31 }
32};
33static const struct cfiattrdata cpubuscf_iattrdata = {
34 "cpubus", 1, {
35 { "apid", "-1", -1 },
36 }
37};
38static const struct cfiattrdata isabuscf_iattrdata = {
39 "isabus", 0, {
40 { NULL, NULL, 0 },
41 }
42};
43static const struct cfiattrdata xenbuscf_iattrdata = {
44 "xenbus", 1, {
45 { "id", "-1", -1 },
46 }
47};
48static const struct cfiattrdata hypervisorbuscf_iattrdata = {
49 "hypervisorbus", 0, {
50 { NULL, NULL, 0 },
51 }
52};
53static const struct cfiattrdata hypervisorcf_iattrdata = {
54 "hypervisor", 1, {
55 { "apid", "-1", -1 },
56 }
57};
58static const struct cfiattrdata ipmibuscf_iattrdata = {
59 "ipmibus", 0, {
60 { NULL, NULL, 0 },
61 }
62};
63
64CFDRIVER_DECL(raid, DV_DISK, NULL);
65
66CFDRIVER_DECL(vnd, DV_DISK, NULL);
67
68CFDRIVER_DECL(cgd, DV_DISK, NULL);
69
70CFDRIVER_DECL(md, DV_DISK, NULL);
71
72CFDRIVER_DECL(fss, DV_DISK, NULL);
73
74CFDRIVER_DECL(tap, DV_IFNET, NULL);
75
76CFDRIVER_DECL(dm, DV_DULL, NULL);
77
78static const struct cfiattrdata * const mainbus_attrs[] = { &ipmibuscf_iattrdata, &hypervisorbuscf_iattrdata, &ioapicbuscf_iattrdata, &cpubuscf_iattrdata, NULL };
79CFDRIVER_DECL(mainbus, DV_DULL, mainbus_attrs);
80
81static const struct cfiattrdata * const hypervisor_attrs[] = { &hypervisorcf_iattrdata, &acpibuscf_iattrdata, &xendevbuscf_iattrdata, &pcibuscf_iattrdata, &isabuscf_iattrdata, NULL };
82CFDRIVER_DECL(hypervisor, DV_DULL, hypervisor_attrs);
83
84static const struct cfiattrdata * const xenbus_attrs[] = { &xenbuscf_iattrdata, NULL };
85CFDRIVER_DECL(xenbus, DV_DULL, xenbus_attrs);
86
87CFDRIVER_DECL(xencons, DV_TTY, NULL);
88
89CFDRIVER_DECL(xennet, DV_IFNET, NULL);
90
91CFDRIVER_DECL(xbd, DV_DISK, NULL);
92
93CFDRIVER_DECL(balloon, DV_DULL, NULL);
94
95CFDRIVER_DECL(vcpu, DV_DULL, NULL);
96
97
98struct cfdriver * const cfdriver_list_initial[] = {
99 &raid_cd,
100 &vnd_cd,
101 &cgd_cd,
102 &md_cd,
103 &fss_cd,
104 &tap_cd,
105 &dm_cd,
106 &mainbus_cd,
107 &hypervisor_cd,
108 &xenbus_cd,
109 &xencons_cd,
110 &xennet_cd,
111 &xbd_cd,
112 &balloon_cd,
113 &vcpu_cd,
114 NULL
115};
116
117extern struct cfattach mainbus_ca;
118extern struct cfattach hypervisor_ca;
119extern struct cfattach xenbus_ca;
120extern struct cfattach xencons_ca;
121extern struct cfattach xennet_ca;
122extern struct cfattach xbd_ca;
123extern struct cfattach balloon_ca;
124extern struct cfattach vcpu_ca;
125
126/* locators */
127static int loc[3] = {
128 -1, -1, -1,
129};
130
131static const struct cfparent pspec0 = {
132 "hypervisorbus", "mainbus", DVUNIT_ANY
133};
134static const struct cfparent pspec1 = {
135 "xendevbus", "hypervisor", DVUNIT_ANY
136};
137static const struct cfparent pspec2 = {
138 "xenbus", "xenbus", DVUNIT_ANY
139};
140
141#define NORM FSTATE_NOTFOUND
142#define STAR FSTATE_STAR
143
144struct cfdata cfdata[] = {
145 /* driver attachment unit state loc flags pspec */
146/* 0: mainbus0 at root */
147 { "mainbus", "mainbus", 0, NORM, NULL, 0, NULL },
148/* 1: hypervisor* at mainbus? */
149 { "hypervisor", "hypervisor", 0, STAR, NULL, 0, &pspec0 },
150/* 2: xenbus* at hypervisor? */
151 { "xenbus", "xenbus", 0, STAR, NULL, 0, &pspec1 },
152/* 3: xencons* at hypervisor? */
153 { "xencons", "xencons", 0, STAR, NULL, 0, &pspec1 },
154/* 4: xennet* at xenbus? id -1 */
155 { "xennet", "xennet", 0, STAR, loc+ 0, 0, &pspec2 },
156/* 5: xbd* at xenbus? id -1 */
157 { "xbd", "xbd", 0, STAR, loc+ 1, 0, &pspec2 },
158/* 6: balloon* at xenbus? id -1 */
159 { "balloon", "balloon", 0, STAR, loc+ 2, 0, &pspec2 },
160/* 7: vcpu* at hypervisor? */
161 { "vcpu", "vcpu", 0, STAR, NULL, 0, &pspec1 },
162 { NULL, NULL, 0, 0, NULL, 0, NULL }
163};
164
165static struct cfattach * const mainbus_cfattachinit[] = {
166 &mainbus_ca, NULL
167};
168static struct cfattach * const hypervisor_cfattachinit[] = {
169 &hypervisor_ca, NULL
170};
171static struct cfattach * const xenbus_cfattachinit[] = {
172 &xenbus_ca, NULL
173};
174static struct cfattach * const xencons_cfattachinit[] = {
175 &xencons_ca, NULL
176};
177static struct cfattach * const xennet_cfattachinit[] = {
178 &xennet_ca, NULL
179};
180static struct cfattach * const xbd_cfattachinit[] = {
181 &xbd_ca, NULL
182};
183static struct cfattach * const balloon_cfattachinit[] = {
184 &balloon_ca, NULL
185};
186static struct cfattach * const vcpu_cfattachinit[] = {
187 &vcpu_ca, NULL
188};
189
190const struct cfattachinit cfattachinit[] = {
191 { "mainbus", mainbus_cfattachinit },
192 { "hypervisor", hypervisor_cfattachinit },
193 { "xenbus", xenbus_cfattachinit },
194 { "xencons", xencons_cfattachinit },
195 { "xennet", xennet_cfattachinit },
196 { "xbd", xbd_cfattachinit },
197 { "balloon", balloon_cfattachinit },
198 { "vcpu", vcpu_cfattachinit },
199 { NULL, NULL }
200};
201
202const short cfroots[] = {
203 0 /* mainbus0 */,
204 -1
205};
206
207/* pseudo-devices */
208
209const struct pdevinit pdevinit[] = {
210 { cpuctlattach, 1 },
211 { rndattach, 1 },
212 { accf_dataattach, 1 },
213 { accf_httpattach, 1 },
214 { cryptoattach, 1 },
215 { swcryptoattach, 1 },
216 { ccdattach, 1 },
217 { cgdattach, 1 },
218 { raidattach, 1 },
219 { fssattach, 1 },
220 { putterattach, 1 },
221 { mdattach, 1 },
222 { vndattach, 1 },
223 { dmattach, 1 },
224 { bpfilterattach, 1 },
225 { ipfilterattach, 1 },
226 { loopattach, 1 },
227 { pppattach, 1 },
228 { pppoeattach, 1 },
229 { slattach, 1 },
230 { tapattach, 1 },
231 { tunattach, 1 },
232 { greattach, 1 },
233 { gifattach, 1 },
234 { stfattach, 1 },
235 { vlanattach, 1 },
236 { bridgeattach, 1 },
237 { ptyattach, 1 },
238 { clockctlattach, 1 },
239 { ksymsattach, 1 },
240 { vcodaattach, 1 },
241 { nsmbattach, 1 },
242 { drvctlattach, 1 },
243 { 0, 0 }
244};
245