2019-03-15 14:51:21 +00:00
|
|
|
#ifndef CHARDEV_SPICE_H
|
|
|
|
#define CHARDEV_SPICE_H
|
2019-02-21 11:06:58 +00:00
|
|
|
|
|
|
|
#include <spice.h>
|
|
|
|
#include "chardev/char-fe.h"
|
2020-09-03 20:43:22 +00:00
|
|
|
#include "qom/object.h"
|
2019-02-21 11:06:58 +00:00
|
|
|
|
2020-09-03 20:43:22 +00:00
|
|
|
struct SpiceChardev {
|
2019-02-21 11:06:58 +00:00
|
|
|
Chardev parent;
|
|
|
|
|
|
|
|
SpiceCharDeviceInstance sin;
|
|
|
|
bool active;
|
|
|
|
bool blocked;
|
|
|
|
const uint8_t *datapos;
|
|
|
|
int datalen;
|
2020-09-03 20:43:22 +00:00
|
|
|
};
|
|
|
|
typedef struct SpiceChardev SpiceChardev;
|
2019-02-21 11:06:58 +00:00
|
|
|
|
|
|
|
#define TYPE_CHARDEV_SPICE "chardev-spice"
|
|
|
|
#define TYPE_CHARDEV_SPICEVMC "chardev-spicevmc"
|
|
|
|
#define TYPE_CHARDEV_SPICEPORT "chardev-spiceport"
|
|
|
|
|
2020-08-31 21:07:33 +00:00
|
|
|
DECLARE_INSTANCE_CHECKER(SpiceChardev, SPICE_CHARDEV,
|
|
|
|
TYPE_CHARDEV_SPICE)
|
2019-02-21 11:06:58 +00:00
|
|
|
|
|
|
|
#endif
|