admin_protocol-structs 2.2 KB
Newer Older
M
Martin Kletzander 已提交
1
/* -*- c -*- */
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
enum {
        VIR_TYPED_PARAM_INT = 1,
        VIR_TYPED_PARAM_UINT = 2,
        VIR_TYPED_PARAM_LLONG = 3,
        VIR_TYPED_PARAM_ULLONG = 4,
        VIR_TYPED_PARAM_DOUBLE = 5,
        VIR_TYPED_PARAM_BOOLEAN = 6,
        VIR_TYPED_PARAM_STRING = 7,
};
struct admin_typed_param_value {
        int                        type;
        union {
                int                i;
                u_int              ui;
                int64_t            l;
                uint64_t           ul;
                double             d;
                int                b;
                admin_nonnull_string s;
        } admin_typed_param_value_u;
};
struct admin_typed_param {
        admin_nonnull_string       field;
        admin_typed_param_value    value;
};
27 28 29
struct admin_nonnull_server {
        admin_nonnull_string       name;
};
30
struct admin_connect_open_args {
M
Martin Kletzander 已提交
31 32
        u_int                      flags;
};
33
struct admin_connect_get_lib_version_ret {
34 35
        uint64_t                   libVer;
};
36 37 38 39 40 41 42 43 44 45 46
struct admin_connect_list_servers_args {
        u_int                      need_results;
        u_int                      flags;
};
struct admin_connect_list_servers_ret {
        struct {
                u_int              servers_len;
                admin_nonnull_server * servers_val;
        } servers;
        u_int                      ret;
};
47 48 49 50 51 52 53
struct admin_connect_lookup_server_args {
        admin_nonnull_string       name;
        u_int                      flags;
};
struct admin_connect_lookup_server_ret {
        admin_nonnull_server       srv;
};
54 55 56 57 58 59 60 61 62 63
struct admin_server_get_threadpool_parameters_args {
        admin_nonnull_server       srv;
        u_int                      flags;
};
struct admin_server_get_threadpool_parameters_ret {
        struct {
                u_int              params_len;
                admin_typed_param * params_val;
        } params;
};
M
Martin Kletzander 已提交
64
enum admin_procedure {
65 66 67
        ADMIN_PROC_CONNECT_OPEN = 1,
        ADMIN_PROC_CONNECT_CLOSE = 2,
        ADMIN_PROC_CONNECT_GET_LIB_VERSION = 3,
68
        ADMIN_PROC_CONNECT_LIST_SERVERS = 4,
69
        ADMIN_PROC_CONNECT_LOOKUP_SERVER = 5,
70
        ADMIN_PROC_SERVER_GET_THREADPOOL_PARAMETERS = 6,
M
Martin Kletzander 已提交
71
};