guest_cpu_to_vrs()

Convert an error from guest_cpu_read() or guest_cpu_write() into a vdev_ref_status value

Synopsis:

#include <qvm/vdev-core.h>
static enum vdev_ref_status guest_cpu_to_vrs(int const errcode)

Arguments:

errcode
A value returned by guest_cpu_read() or guest_cpu_write().

Library:

Provided by qvm; no external library is required.

Description:

It is assumed that the returned value is an error.

Returns:

VRS_BUS_ERROR if errcode is -1; otherwise, VRS_ERRNO and the errcode value.