vdev_s

Virtual device information

Synopsis:

#include <qvm/vdev-core.h>
struct vdev_s {
    void* v_device;
    const struct vdev_factory* v_factory;
    struct guest_system* v_gsp;
    struct qvm_state_block v_block;
    struct guest_intr v_intr;
    pthread_mutex_t v_mtx;
    struct qvm_sched_info v_sched;
} ;

Data:

void* v_device

A pointer to device-specific state information.

const struct vdev_factory* v_factory

A pointer to the device factory for the vdev.

struct guest_system* v_gsp

A pointer to the guest system in which the vdev is defined (the hosting qvm process instance).

struct qvm_state_block v_block

The location of the vdev in the guest system.

struct guest_intr v_intr

The guest interrupt the vdev uses to request service.

pthread_mutex_t v_mtx

A mutex for the vdev's own use. Use the flags specified by vdev_factory_flags to intitialize this member: VFF_MUTEX (and, optionally, VFF_MUTEX_RECURSIVE).

struct qvm_sched_info v_sched

Scheduler information for the vdev threads.

Library:

Provided by qvm; no external library is required.