/*
* Process a received message.
*/
-static void vfio_user_process(VFIOUserProxy *proxy, VFIOUserMsg *msg,
- bool isreply)
+static void vfio_user_process(VFIOUserProxy *proxy, VFIOUserMsg *msg)
{
/*
*
* Requests get queued for the BH.
*/
- if (isreply) {
+ if ((msg->hdr->flags & VFIO_USER_TYPE) == VFIO_USER_REPLY) {
msg->complete = true;
if (msg->type == VFIO_MSG_WAIT) {
qemu_cond_signal(&msg->cv);
{
VFIOUserMsg *msg = proxy->part_recv;
size_t msgleft = proxy->recv_left;
- bool isreply;
char *data;
int ret;
*/
proxy->part_recv = NULL;
proxy->recv_left = 0;
- isreply = (msg->hdr->flags & VFIO_USER_TYPE) == VFIO_USER_REPLY;
- vfio_user_process(proxy, msg, isreply);
+ vfio_user_process(proxy, msg);
/* return positive value */
return 1;
data += ret;
}
- vfio_user_process(proxy, msg, isreply);
+ vfio_user_process(proxy, msg);
return 0;
/*