]>
Commit | Line | Data |
---|---|---|
2d888c09 AF |
1 | /* |
2 | * QTest testcase for VirtIO 9P | |
3 | * | |
4 | * Copyright (c) 2014 SUSE LINUX Products GmbH | |
5 | * | |
6 | * This work is licensed under the terms of the GNU GPL, version 2 or later. | |
7 | * See the COPYING file in the top-level directory. | |
8 | */ | |
9 | ||
fbc04127 | 10 | #include "qemu/osdep.h" |
2d888c09 AF |
11 | #include "libqtest.h" |
12 | #include "qemu-common.h" | |
a980f7f2 | 13 | #include "libqos/libqos-pc.h" |
30ca440e | 14 | #include "libqos/libqos-spapr.h" |
557a4cc0 GK |
15 | #include "libqos/virtio.h" |
16 | #include "libqos/virtio-pci.h" | |
557a4cc0 GK |
17 | #include "standard-headers/linux/virtio_ids.h" |
18 | #include "standard-headers/linux/virtio_pci.h" | |
6cc9906b | 19 | #include "hw/9pfs/9p.h" |
2893ddd5 | 20 | #include "hw/9pfs/9p-synth.h" |
2d888c09 | 21 | |
65b70fc7 GK |
22 | #define QVIRTIO_9P_TIMEOUT_US (10 * 1000 * 1000) |
23 | ||
993f8054 | 24 | static const char mount_tag[] = "qtest"; |
2d888c09 | 25 | |
1211d81b GK |
26 | typedef struct { |
27 | QVirtioDevice *dev; | |
28 | QOSState *qs; | |
29 | QVirtQueue *vq; | |
1211d81b | 30 | } QVirtIO9P; |
a980f7f2 | 31 | |
1211d81b | 32 | static QVirtIO9P *qvirtio_9p_start(const char *driver) |
2d888c09 | 33 | { |
30ca440e | 34 | const char *arch = qtest_get_arch(); |
2893ddd5 | 35 | const char *cmd = "-fsdev synth,id=fsdev0 " |
1211d81b GK |
36 | "-device %s,fsdev=fsdev0,mount_tag=%s"; |
37 | QVirtIO9P *v9p = g_new0(QVirtIO9P, 1); | |
2d888c09 | 38 | |
30ca440e | 39 | if (strcmp(arch, "i386") == 0 || strcmp(arch, "x86_64") == 0) { |
2893ddd5 | 40 | v9p->qs = qtest_pc_boot(cmd, driver, mount_tag); |
1211d81b | 41 | } else if (strcmp(arch, "ppc64") == 0) { |
2893ddd5 | 42 | v9p->qs = qtest_spapr_boot(cmd, driver, mount_tag); |
1211d81b GK |
43 | } else { |
44 | g_printerr("virtio-9p tests are only available on x86 or ppc64\n"); | |
45 | exit(EXIT_FAILURE); | |
30ca440e LV |
46 | } |
47 | ||
1211d81b | 48 | return v9p; |
993f8054 GK |
49 | } |
50 | ||
1211d81b | 51 | static void qvirtio_9p_stop(QVirtIO9P *v9p) |
993f8054 | 52 | { |
1211d81b | 53 | qtest_shutdown(v9p->qs); |
1211d81b | 54 | g_free(v9p); |
993f8054 GK |
55 | } |
56 | ||
1211d81b | 57 | static QVirtIO9P *qvirtio_9p_pci_start(void) |
557a4cc0 | 58 | { |
1211d81b GK |
59 | QVirtIO9P *v9p = qvirtio_9p_start("virtio-9p-pci"); |
60 | QVirtioPCIDevice *dev = qvirtio_pci_device_find(v9p->qs->pcibus, | |
61 | VIRTIO_ID_9P); | |
557a4cc0 GK |
62 | g_assert_nonnull(dev); |
63 | g_assert_cmphex(dev->vdev.device_type, ==, VIRTIO_ID_9P); | |
64 | v9p->dev = (QVirtioDevice *) dev; | |
65 | ||
66 | qvirtio_pci_device_enable(dev); | |
6b9cdf4c LV |
67 | qvirtio_reset(v9p->dev); |
68 | qvirtio_set_acknowledge(v9p->dev); | |
69 | qvirtio_set_driver(v9p->dev); | |
557a4cc0 | 70 | |
a980f7f2 | 71 | v9p->vq = qvirtqueue_setup(v9p->dev, v9p->qs->alloc, 0); |
d8803b1a GK |
72 | |
73 | qvirtio_set_driver_ok(v9p->dev); | |
74 | ||
557a4cc0 GK |
75 | return v9p; |
76 | } | |
77 | ||
1211d81b | 78 | static void qvirtio_9p_pci_stop(QVirtIO9P *v9p) |
557a4cc0 | 79 | { |
a980f7f2 | 80 | qvirtqueue_cleanup(v9p->dev->bus, v9p->vq, v9p->qs->alloc); |
557a4cc0 | 81 | qvirtio_pci_device_disable(container_of(v9p->dev, QVirtioPCIDevice, vdev)); |
2b880bcd | 82 | qvirtio_pci_device_free((QVirtioPCIDevice *)v9p->dev); |
1211d81b | 83 | qvirtio_9p_stop(v9p); |
557a4cc0 GK |
84 | } |
85 | ||
1211d81b | 86 | static void pci_config(QVirtIO9P *v9p) |
557a4cc0 | 87 | { |
1211d81b | 88 | size_t tag_len = qvirtio_config_readw(v9p->dev, 0); |
557a4cc0 GK |
89 | char *tag; |
90 | int i; | |
557a4cc0 | 91 | |
557a4cc0 | 92 | g_assert_cmpint(tag_len, ==, strlen(mount_tag)); |
557a4cc0 GK |
93 | |
94 | tag = g_malloc(tag_len); | |
95 | for (i = 0; i < tag_len; i++) { | |
246fc0fb | 96 | tag[i] = qvirtio_config_readb(v9p->dev, i + 2); |
557a4cc0 GK |
97 | } |
98 | g_assert_cmpmem(tag, tag_len, mount_tag, tag_len); | |
99 | g_free(tag); | |
1211d81b GK |
100 | } |
101 | ||
6cc9906b GK |
102 | #define P9_MAX_SIZE 4096 /* Max size of a T-message or R-message */ |
103 | ||
104 | typedef struct { | |
105 | QVirtIO9P *v9p; | |
106 | uint16_t tag; | |
107 | uint64_t t_msg; | |
108 | uint32_t t_size; | |
109 | uint64_t r_msg; | |
110 | /* No r_size, it is hardcoded to P9_MAX_SIZE */ | |
111 | size_t t_off; | |
112 | size_t r_off; | |
65b70fc7 | 113 | uint32_t free_head; |
6cc9906b GK |
114 | } P9Req; |
115 | ||
116 | static void v9fs_memwrite(P9Req *req, const void *addr, size_t len) | |
117 | { | |
118 | memwrite(req->t_msg + req->t_off, addr, len); | |
119 | req->t_off += len; | |
120 | } | |
121 | ||
122 | static void v9fs_memskip(P9Req *req, size_t len) | |
123 | { | |
124 | req->r_off += len; | |
125 | } | |
126 | ||
6cc9906b GK |
127 | static void v9fs_memread(P9Req *req, void *addr, size_t len) |
128 | { | |
129 | memread(req->r_msg + req->r_off, addr, len); | |
130 | req->r_off += len; | |
131 | } | |
132 | ||
133 | static void v9fs_uint16_write(P9Req *req, uint16_t val) | |
134 | { | |
135 | uint16_t le_val = cpu_to_le16(val); | |
136 | ||
137 | v9fs_memwrite(req, &le_val, 2); | |
138 | } | |
139 | ||
140 | static void v9fs_uint16_read(P9Req *req, uint16_t *val) | |
141 | { | |
142 | v9fs_memread(req, val, 2); | |
143 | le16_to_cpus(val); | |
144 | } | |
145 | ||
146 | static void v9fs_uint32_write(P9Req *req, uint32_t val) | |
147 | { | |
148 | uint32_t le_val = cpu_to_le32(val); | |
149 | ||
150 | v9fs_memwrite(req, &le_val, 4); | |
151 | } | |
152 | ||
153 | static void v9fs_uint32_read(P9Req *req, uint32_t *val) | |
154 | { | |
155 | v9fs_memread(req, val, 4); | |
156 | le32_to_cpus(val); | |
157 | } | |
158 | ||
159 | /* len[2] string[len] */ | |
160 | static uint16_t v9fs_string_size(const char *string) | |
161 | { | |
162 | size_t len = strlen(string); | |
163 | ||
164 | g_assert_cmpint(len, <=, UINT16_MAX); | |
165 | ||
166 | return 2 + len; | |
167 | } | |
168 | ||
169 | static void v9fs_string_write(P9Req *req, const char *string) | |
170 | { | |
171 | int len = strlen(string); | |
172 | ||
173 | g_assert_cmpint(len, <=, UINT16_MAX); | |
174 | ||
175 | v9fs_uint16_write(req, (uint16_t) len); | |
176 | v9fs_memwrite(req, string, len); | |
177 | } | |
178 | ||
179 | static void v9fs_string_read(P9Req *req, uint16_t *len, char **string) | |
180 | { | |
181 | uint16_t local_len; | |
182 | ||
183 | v9fs_uint16_read(req, &local_len); | |
184 | if (len) { | |
185 | *len = local_len; | |
186 | } | |
187 | if (string) { | |
188 | *string = g_malloc(local_len); | |
189 | v9fs_memread(req, *string, local_len); | |
190 | } else { | |
191 | v9fs_memskip(req, local_len); | |
192 | } | |
193 | } | |
194 | ||
195 | typedef struct { | |
196 | uint32_t size; | |
197 | uint8_t id; | |
198 | uint16_t tag; | |
199 | } QEMU_PACKED P9Hdr; | |
200 | ||
201 | static P9Req *v9fs_req_init(QVirtIO9P *v9p, uint32_t size, uint8_t id, | |
202 | uint16_t tag) | |
203 | { | |
204 | P9Req *req = g_new0(P9Req, 1); | |
205 | uint32_t t_size = 7 + size; /* 9P header has well-known size of 7 bytes */ | |
206 | P9Hdr hdr = { | |
207 | .size = cpu_to_le32(t_size), | |
208 | .id = id, | |
209 | .tag = cpu_to_le16(tag) | |
210 | }; | |
211 | ||
212 | g_assert_cmpint(t_size, <=, P9_MAX_SIZE); | |
213 | ||
214 | req->v9p = v9p; | |
215 | req->t_size = t_size; | |
216 | req->t_msg = guest_alloc(v9p->qs->alloc, req->t_size); | |
217 | v9fs_memwrite(req, &hdr, 7); | |
218 | req->tag = tag; | |
219 | return req; | |
220 | } | |
221 | ||
222 | static void v9fs_req_send(P9Req *req) | |
223 | { | |
224 | QVirtIO9P *v9p = req->v9p; | |
6cc9906b GK |
225 | |
226 | req->r_msg = guest_alloc(v9p->qs->alloc, P9_MAX_SIZE); | |
65b70fc7 GK |
227 | req->free_head = qvirtqueue_add(v9p->vq, req->t_msg, req->t_size, false, |
228 | true); | |
6cc9906b | 229 | qvirtqueue_add(v9p->vq, req->r_msg, P9_MAX_SIZE, true, false); |
65b70fc7 | 230 | qvirtqueue_kick(v9p->dev, v9p->vq, req->free_head); |
6cc9906b GK |
231 | req->t_off = 0; |
232 | } | |
233 | ||
6e37f458 GK |
234 | static const char *rmessage_name(uint8_t id) |
235 | { | |
236 | return | |
237 | id == P9_RLERROR ? "RLERROR" : | |
238 | id == P9_RVERSION ? "RVERSION" : | |
239 | id == P9_RATTACH ? "RATTACH" : | |
240 | id == P9_RWALK ? "RWALK" : | |
241 | "<unknown>"; | |
242 | } | |
243 | ||
60b1fa9d | 244 | static void v9fs_req_wait_for_reply(P9Req *req) |
6cc9906b GK |
245 | { |
246 | QVirtIO9P *v9p = req->v9p; | |
6cc9906b | 247 | |
65b70fc7 GK |
248 | qvirtio_wait_used_elem(v9p->dev, v9p->vq, req->free_head, |
249 | QVIRTIO_9P_TIMEOUT_US); | |
60b1fa9d GK |
250 | } |
251 | ||
252 | static void v9fs_req_recv(P9Req *req, uint8_t id) | |
253 | { | |
254 | P9Hdr hdr; | |
6cc9906b | 255 | |
65b70fc7 GK |
256 | v9fs_memread(req, &hdr, 7); |
257 | hdr.size = ldl_le_p(&hdr.size); | |
258 | hdr.tag = lduw_le_p(&hdr.tag); | |
6cc9906b GK |
259 | |
260 | g_assert_cmpint(hdr.size, >=, 7); | |
261 | g_assert_cmpint(hdr.size, <=, P9_MAX_SIZE); | |
262 | g_assert_cmpint(hdr.tag, ==, req->tag); | |
263 | ||
6e37f458 GK |
264 | if (hdr.id != id) { |
265 | g_printerr("Received response %d (%s) instead of %d (%s)\n", | |
266 | hdr.id, rmessage_name(hdr.id), id, rmessage_name(id)); | |
267 | ||
268 | if (hdr.id == P9_RLERROR) { | |
269 | uint32_t err; | |
270 | v9fs_uint32_read(req, &err); | |
271 | g_printerr("Rlerror has errno %d (%s)\n", err, strerror(err)); | |
272 | } | |
6cc9906b GK |
273 | } |
274 | g_assert_cmpint(hdr.id, ==, id); | |
275 | } | |
276 | ||
277 | static void v9fs_req_free(P9Req *req) | |
278 | { | |
279 | QVirtIO9P *v9p = req->v9p; | |
280 | ||
281 | guest_free(v9p->qs->alloc, req->t_msg); | |
282 | guest_free(v9p->qs->alloc, req->r_msg); | |
283 | g_free(req); | |
284 | } | |
285 | ||
ba0d1037 GK |
286 | /* size[4] Rlerror tag[2] ecode[4] */ |
287 | static void v9fs_rlerror(P9Req *req, uint32_t *err) | |
288 | { | |
289 | v9fs_req_recv(req, P9_RLERROR); | |
290 | v9fs_uint32_read(req, err); | |
291 | v9fs_req_free(req); | |
292 | } | |
293 | ||
6cc9906b | 294 | /* size[4] Tversion tag[2] msize[4] version[s] */ |
693b21d2 GK |
295 | static P9Req *v9fs_tversion(QVirtIO9P *v9p, uint32_t msize, const char *version, |
296 | uint16_t tag) | |
6cc9906b GK |
297 | { |
298 | P9Req *req = v9fs_req_init(v9p, 4 + v9fs_string_size(version), P9_TVERSION, | |
693b21d2 | 299 | tag); |
6cc9906b GK |
300 | |
301 | v9fs_uint32_write(req, msize); | |
302 | v9fs_string_write(req, version); | |
303 | v9fs_req_send(req); | |
304 | return req; | |
305 | } | |
306 | ||
307 | /* size[4] Rversion tag[2] msize[4] version[s] */ | |
308 | static void v9fs_rversion(P9Req *req, uint16_t *len, char **version) | |
309 | { | |
310 | uint32_t msize; | |
311 | ||
312 | v9fs_req_recv(req, P9_RVERSION); | |
313 | v9fs_uint32_read(req, &msize); | |
314 | ||
315 | g_assert_cmpint(msize, ==, P9_MAX_SIZE); | |
316 | ||
317 | if (len || version) { | |
318 | v9fs_string_read(req, len, version); | |
319 | } | |
320 | ||
321 | v9fs_req_free(req); | |
322 | } | |
323 | ||
5c3df1f0 | 324 | /* size[4] Tattach tag[2] fid[4] afid[4] uname[s] aname[s] n_uname[4] */ |
693b21d2 GK |
325 | static P9Req *v9fs_tattach(QVirtIO9P *v9p, uint32_t fid, uint32_t n_uname, |
326 | uint16_t tag) | |
5c3df1f0 GK |
327 | { |
328 | const char *uname = ""; /* ignored by QEMU */ | |
329 | const char *aname = ""; /* ignored by QEMU */ | |
693b21d2 | 330 | P9Req *req = v9fs_req_init(v9p, 4 + 4 + 2 + 2 + 4, P9_TATTACH, tag); |
5c3df1f0 GK |
331 | |
332 | v9fs_uint32_write(req, fid); | |
333 | v9fs_uint32_write(req, P9_NOFID); | |
334 | v9fs_string_write(req, uname); | |
335 | v9fs_string_write(req, aname); | |
336 | v9fs_uint32_write(req, n_uname); | |
337 | v9fs_req_send(req); | |
338 | return req; | |
339 | } | |
340 | ||
341 | typedef char v9fs_qid[13]; | |
342 | ||
343 | /* size[4] Rattach tag[2] qid[13] */ | |
344 | static void v9fs_rattach(P9Req *req, v9fs_qid *qid) | |
345 | { | |
346 | v9fs_req_recv(req, P9_RATTACH); | |
347 | if (qid) { | |
348 | v9fs_memread(req, qid, 13); | |
349 | } | |
350 | v9fs_req_free(req); | |
351 | } | |
352 | ||
04b88c84 GK |
353 | /* size[4] Twalk tag[2] fid[4] newfid[4] nwname[2] nwname*(wname[s]) */ |
354 | static P9Req *v9fs_twalk(QVirtIO9P *v9p, uint32_t fid, uint32_t newfid, | |
693b21d2 | 355 | uint16_t nwname, char *const wnames[], uint16_t tag) |
04b88c84 GK |
356 | { |
357 | P9Req *req; | |
358 | int i; | |
359 | uint32_t size = 4 + 4 + 2; | |
360 | ||
361 | for (i = 0; i < nwname; i++) { | |
362 | size += v9fs_string_size(wnames[i]); | |
363 | } | |
693b21d2 | 364 | req = v9fs_req_init(v9p, size, P9_TWALK, tag); |
04b88c84 GK |
365 | v9fs_uint32_write(req, fid); |
366 | v9fs_uint32_write(req, newfid); | |
367 | v9fs_uint16_write(req, nwname); | |
368 | for (i = 0; i < nwname; i++) { | |
369 | v9fs_string_write(req, wnames[i]); | |
370 | } | |
371 | v9fs_req_send(req); | |
372 | return req; | |
373 | } | |
374 | ||
375 | /* size[4] Rwalk tag[2] nwqid[2] nwqid*(wqid[13]) */ | |
376 | static void v9fs_rwalk(P9Req *req, uint16_t *nwqid, v9fs_qid **wqid) | |
377 | { | |
378 | uint16_t local_nwqid; | |
379 | ||
380 | v9fs_req_recv(req, P9_RWALK); | |
381 | v9fs_uint16_read(req, &local_nwqid); | |
382 | if (nwqid) { | |
383 | *nwqid = local_nwqid; | |
384 | } | |
385 | if (wqid) { | |
386 | *wqid = g_malloc(local_nwqid * 13); | |
387 | v9fs_memread(req, *wqid, local_nwqid * 13); | |
388 | } | |
389 | v9fs_req_free(req); | |
390 | } | |
391 | ||
6cc9906b GK |
392 | static void fs_version(QVirtIO9P *v9p) |
393 | { | |
394 | const char *version = "9P2000.L"; | |
395 | uint16_t server_len; | |
396 | char *server_version; | |
397 | P9Req *req; | |
398 | ||
693b21d2 | 399 | req = v9fs_tversion(v9p, P9_MAX_SIZE, version, P9_NOTAG); |
60b1fa9d | 400 | v9fs_req_wait_for_reply(req); |
6cc9906b GK |
401 | v9fs_rversion(req, &server_len, &server_version); |
402 | ||
403 | g_assert_cmpmem(server_version, server_len, version, strlen(version)); | |
404 | ||
405 | g_free(server_version); | |
406 | } | |
407 | ||
5c3df1f0 GK |
408 | static void fs_attach(QVirtIO9P *v9p) |
409 | { | |
410 | P9Req *req; | |
411 | ||
412 | fs_version(v9p); | |
693b21d2 | 413 | req = v9fs_tattach(v9p, 0, getuid(), 0); |
60b1fa9d | 414 | v9fs_req_wait_for_reply(req); |
5c3df1f0 GK |
415 | v9fs_rattach(req, NULL); |
416 | } | |
417 | ||
04b88c84 GK |
418 | static void fs_walk(QVirtIO9P *v9p) |
419 | { | |
2893ddd5 | 420 | char *wnames[P9_MAXWELEM]; |
04b88c84 GK |
421 | uint16_t nwqid; |
422 | v9fs_qid *wqid; | |
423 | int i; | |
424 | P9Req *req; | |
425 | ||
426 | for (i = 0; i < P9_MAXWELEM; i++) { | |
2893ddd5 | 427 | wnames[i] = g_strdup_printf(QTEST_V9FS_SYNTH_WALK_FILE, i); |
04b88c84 GK |
428 | } |
429 | ||
430 | fs_attach(v9p); | |
693b21d2 | 431 | req = v9fs_twalk(v9p, 0, 1, P9_MAXWELEM, wnames, 0); |
60b1fa9d | 432 | v9fs_req_wait_for_reply(req); |
04b88c84 GK |
433 | v9fs_rwalk(req, &nwqid, &wqid); |
434 | ||
435 | g_assert_cmpint(nwqid, ==, P9_MAXWELEM); | |
436 | ||
437 | for (i = 0; i < P9_MAXWELEM; i++) { | |
04b88c84 GK |
438 | g_free(wnames[i]); |
439 | } | |
440 | ||
441 | g_free(wqid); | |
442 | } | |
443 | ||
ba0d1037 GK |
444 | static void fs_walk_no_slash(QVirtIO9P *v9p) |
445 | { | |
446 | char *const wnames[] = { g_strdup(" /") }; | |
447 | P9Req *req; | |
448 | uint32_t err; | |
449 | ||
450 | fs_attach(v9p); | |
693b21d2 | 451 | req = v9fs_twalk(v9p, 0, 1, 1, wnames, 0); |
60b1fa9d | 452 | v9fs_req_wait_for_reply(req); |
ba0d1037 GK |
453 | v9fs_rlerror(req, &err); |
454 | ||
455 | g_assert_cmpint(err, ==, ENOENT); | |
456 | ||
457 | g_free(wnames[0]); | |
458 | } | |
459 | ||
a37c0702 GK |
460 | static void fs_walk_dotdot(QVirtIO9P *v9p) |
461 | { | |
462 | char *const wnames[] = { g_strdup("..") }; | |
463 | v9fs_qid root_qid, *wqid; | |
464 | P9Req *req; | |
465 | ||
466 | fs_version(v9p); | |
693b21d2 | 467 | req = v9fs_tattach(v9p, 0, getuid(), 0); |
60b1fa9d | 468 | v9fs_req_wait_for_reply(req); |
a37c0702 GK |
469 | v9fs_rattach(req, &root_qid); |
470 | ||
693b21d2 | 471 | req = v9fs_twalk(v9p, 0, 1, 1, wnames, 0); |
60b1fa9d | 472 | v9fs_req_wait_for_reply(req); |
a37c0702 GK |
473 | v9fs_rwalk(req, NULL, &wqid); /* We now we'll get one qid */ |
474 | ||
475 | g_assert_cmpmem(&root_qid, 13, wqid[0], 13); | |
476 | ||
477 | g_free(wqid); | |
478 | g_free(wnames[0]); | |
479 | } | |
480 | ||
1211d81b GK |
481 | typedef void (*v9fs_test_fn)(QVirtIO9P *v9p); |
482 | ||
483 | static void v9fs_run_pci_test(gconstpointer data) | |
484 | { | |
485 | v9fs_test_fn fn = data; | |
486 | QVirtIO9P *v9p = qvirtio_9p_pci_start(); | |
557a4cc0 | 487 | |
1211d81b GK |
488 | if (fn) { |
489 | fn(v9p); | |
490 | } | |
491 | qvirtio_9p_pci_stop(v9p); | |
492 | } | |
493 | ||
494 | static void v9fs_qtest_pci_add(const char *path, v9fs_test_fn fn) | |
495 | { | |
496 | qtest_add_data_func(path, fn, v9fs_run_pci_test); | |
557a4cc0 GK |
497 | } |
498 | ||
993f8054 GK |
499 | int main(int argc, char **argv) |
500 | { | |
501 | g_test_init(&argc, &argv, NULL); | |
1211d81b GK |
502 | v9fs_qtest_pci_add("/virtio/9p/pci/nop", NULL); |
503 | v9fs_qtest_pci_add("/virtio/9p/pci/config", pci_config); | |
6cc9906b | 504 | v9fs_qtest_pci_add("/virtio/9p/pci/fs/version/basic", fs_version); |
5c3df1f0 | 505 | v9fs_qtest_pci_add("/virtio/9p/pci/fs/attach/basic", fs_attach); |
04b88c84 | 506 | v9fs_qtest_pci_add("/virtio/9p/pci/fs/walk/basic", fs_walk); |
ba0d1037 | 507 | v9fs_qtest_pci_add("/virtio/9p/pci/fs/walk/no_slash", fs_walk_no_slash); |
a37c0702 GK |
508 | v9fs_qtest_pci_add("/virtio/9p/pci/fs/walk/dotdot_from_root", |
509 | fs_walk_dotdot); | |
2d888c09 | 510 | |
993f8054 | 511 | return g_test_run(); |
2d888c09 | 512 | } |