12e31e210SGerd Hoffmann /* 22e31e210SGerd Hoffmann * Copyright (C) 2010 Red Hat, Inc. 32e31e210SGerd Hoffmann * 42e31e210SGerd Hoffmann * This program is free software; you can redistribute it and/or 52e31e210SGerd Hoffmann * modify it under the terms of the GNU General Public License as 62e31e210SGerd Hoffmann * published by the Free Software Foundation; either version 2 or 72e31e210SGerd Hoffmann * (at your option) version 3 of the License. 82e31e210SGerd Hoffmann * 92e31e210SGerd Hoffmann * This program is distributed in the hope that it will be useful, 102e31e210SGerd Hoffmann * but WITHOUT ANY WARRANTY; without even the implied warranty of 112e31e210SGerd Hoffmann * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 122e31e210SGerd Hoffmann * GNU General Public License for more details. 132e31e210SGerd Hoffmann * 142e31e210SGerd Hoffmann * You should have received a copy of the GNU General Public License 152e31e210SGerd Hoffmann * along with this program; if not, see <http://www.gnu.org/licenses/>. 162e31e210SGerd Hoffmann */ 172e31e210SGerd Hoffmann 182e31e210SGerd Hoffmann #ifndef QEMU_SPICE_MODULE_H 192e31e210SGerd Hoffmann #define QEMU_SPICE_MODULE_H 202e31e210SGerd Hoffmann 2105b53636SGerd Hoffmann #ifdef CONFIG_SPICE 2205b53636SGerd Hoffmann #include <spice.h> 2305b53636SGerd Hoffmann #endif 2405b53636SGerd Hoffmann 25*db5732c9SGerd Hoffmann typedef struct SpiceInfo SpiceInfo; 26*db5732c9SGerd Hoffmann 277477477cSGerd Hoffmann struct QemuSpiceOps { 2863be30e6SGerd Hoffmann void (*init)(void); 29b192cd1eSGerd Hoffmann void (*display_init)(void); 307477477cSGerd Hoffmann int (*migrate_info)(const char *h, int p, int t, const char *s); 3108ad2626SGerd Hoffmann int (*set_passwd)(const char *passwd, 3208ad2626SGerd Hoffmann bool fail_if_connected, bool disconnect_if_connected); 3308ad2626SGerd Hoffmann int (*set_pw_expire)(time_t expires); 34864a024cSGerd Hoffmann int (*display_add_client)(int csock, int skipauth, int tls); 3505b53636SGerd Hoffmann #ifdef CONFIG_SPICE 3605b53636SGerd Hoffmann int (*add_interface)(SpiceBaseInstance *sin); 37*db5732c9SGerd Hoffmann SpiceInfo* (*qmp_query)(Error **errp); 3805b53636SGerd Hoffmann #endif 397477477cSGerd Hoffmann }; 407477477cSGerd Hoffmann 412e31e210SGerd Hoffmann extern int using_spice; 427477477cSGerd Hoffmann extern struct QemuSpiceOps qemu_spice; 432e31e210SGerd Hoffmann 442e31e210SGerd Hoffmann #endif 45