blob: 65e4b1cfab2123dd453b91bfe801c1ab158da3b1 [file] [log] [blame]
Gautham R Shenoy74db9202010-04-29 17:44:43 +05301/*
Greg Kurzaf8b38b2016-06-06 11:52:34 +02002 * 9p
Gautham R Shenoy74db9202010-04-29 17:44:43 +05303 *
4 * Copyright IBM, Corp. 2010
5 *
6 * Authors:
7 * Gautham R Shenoy <ego@in.ibm.com>
8 *
9 * This work is licensed under the terms of the GNU GPL, version 2. See
10 * the COPYING file in the top-level directory.
11 *
12 */
13#ifndef QEMU_FSDEV_H
14#define QEMU_FSDEV_H
Aneesh Kumar K.V353ac782011-01-28 18:09:08 +053015#include "file-op-9p.h"
Gautham R Shenoy74db9202010-04-29 17:44:43 +053016
17
18/*
19 * A table to store the various file systems and their callback operations.
20 * -----------------
21 * fstype | ops
22 * -----------------
23 * local | local_ops
24 * . |
25 * . |
26 * . |
27 * . |
28 * -----------------
29 * etc
30 */
Aneesh Kumar K.Vfbcbf102011-10-13 12:28:04 +053031typedef struct FsDriverTable {
Gautham R Shenoy74db9202010-04-29 17:44:43 +053032 const char *name;
33 FileOperations *ops;
Aneesh Kumar K.Vfbcbf102011-10-13 12:28:04 +053034} FsDriverTable;
Gautham R Shenoy74db9202010-04-29 17:44:43 +053035
Aneesh Kumar K.Vfbcbf102011-10-13 12:28:04 +053036typedef struct FsDriverListEntry {
37 FsDriverEntry fse;
38 QTAILQ_ENTRY(FsDriverListEntry) next;
39} FsDriverListEntry;
Gautham R Shenoy74db9202010-04-29 17:44:43 +053040
Blue Swirl64b85a82011-01-23 16:21:20 +000041int qemu_fsdev_add(QemuOpts *opts);
Aneesh Kumar K.Vfbcbf102011-10-13 12:28:04 +053042FsDriverEntry *get_fsdev_fsentry(char *id);
Anthony Liguori9f107512010-04-29 17:44:44 +053043extern FileOperations local_ops;
Aneesh Kumar K.V5f542222011-08-02 11:35:54 +053044extern FileOperations handle_ops;
Aneesh Kumar K.V9db221a2011-10-25 12:10:40 +053045extern FileOperations synth_ops;
M. Mohan Kumar4c793dd2011-12-14 13:49:28 +053046extern FileOperations proxy_ops;
Gautham R Shenoy74db9202010-04-29 17:44:43 +053047#endif