1 /* 2 * Virtio 9p 3 * 4 * This work is licensed under the terms of the GNU GPL, version 2 or 5 * later. See the COPYING file in the top-level directory. 6 */ 7 8 #include "qemu/config-file.h" 9 #include "qemu/option.h" 10 #include "qemu/module.h" 11 12 static QemuOptsList qemu_fsdev_opts = { 13 .name = "fsdev", 14 .implied_opt_name = "fsdriver", 15 .head = QTAILQ_HEAD_INITIALIZER(qemu_fsdev_opts.head), 16 .desc = { 17 { 18 .name = "fsdriver", 19 .type = QEMU_OPT_STRING, 20 }, { 21 .name = "path", 22 .type = QEMU_OPT_STRING, 23 }, { 24 .name = "security_model", 25 .type = QEMU_OPT_STRING, 26 }, { 27 .name = "writeout", 28 .type = QEMU_OPT_STRING, 29 }, { 30 .name = "readonly", 31 .type = QEMU_OPT_BOOL, 32 33 }, { 34 .name = "socket", 35 .type = QEMU_OPT_STRING, 36 }, { 37 .name = "sock_fd", 38 .type = QEMU_OPT_NUMBER, 39 }, 40 41 { /*End of list */ } 42 }, 43 }; 44 45 static QemuOptsList qemu_virtfs_opts = { 46 .name = "virtfs", 47 .implied_opt_name = "fsdriver", 48 .head = QTAILQ_HEAD_INITIALIZER(qemu_virtfs_opts.head), 49 .desc = { 50 { 51 .name = "fsdriver", 52 .type = QEMU_OPT_STRING, 53 }, { 54 .name = "path", 55 .type = QEMU_OPT_STRING, 56 }, { 57 .name = "mount_tag", 58 .type = QEMU_OPT_STRING, 59 }, { 60 .name = "security_model", 61 .type = QEMU_OPT_STRING, 62 }, { 63 .name = "writeout", 64 .type = QEMU_OPT_STRING, 65 }, { 66 .name = "readonly", 67 .type = QEMU_OPT_BOOL, 68 }, { 69 .name = "socket", 70 .type = QEMU_OPT_STRING, 71 }, { 72 .name = "sock_fd", 73 .type = QEMU_OPT_NUMBER, 74 }, 75 76 { /*End of list */ } 77 }, 78 }; 79 80 static void fsdev_register_config(void) 81 { 82 qemu_add_opts(&qemu_fsdev_opts); 83 qemu_add_opts(&qemu_virtfs_opts); 84 } 85 machine_init(fsdev_register_config); 86