void virtio_init_iov_from_pdu(V9fsPDU *pdu, struct iovec **piov,

                              unsigned int *pniov, bool is_write)

{

    V9fsState *s = pdu->s;

    V9fsVirtioState *v = container_of(s, V9fsVirtioState, state);

    VirtQueueElement *elem = &v->elems[pdu->idx];



    if (is_write) {

        *piov = elem->out_sg;

        *pniov = elem->out_num;

    } else {

        *piov = elem->in_sg;

        *pniov = elem->in_num;

    }

}

void virtio_init_iov_from_pdu(V9fsPDU *pdu, struct iovec **piov,

                              unsigned int *pniov, bool is_write)

{

    V9fsState *s = pdu->s;

    V9fsVirtioState *v = container_of(s, V9fsVirtioState, state);

    VirtQueueElement *elem = &v->elems[pdu->idx];



    if (is_write) {

        *piov = elem->out_sg;

        *pniov = elem->out_num;

    } else {

        *piov = elem->in_sg;

        *pniov = elem->in_num;

    }

}

void FUNC_0(V9fsPDU *VAR_0, struct iovec **VAR_1,

                              unsigned int *VAR_2, bool VAR_3)

{

    V9fsState *s = VAR_0->s;

    V9fsVirtioState *v = container_of(s, V9fsVirtioState, state);

    VirtQueueElement *elem = &v->elems[VAR_0->idx];



    if (VAR_3) {

        *VAR_1 = elem->out_sg;

        *VAR_2 = elem->out_num;

    } else {

        *VAR_1 = elem->in_sg;

        *VAR_2 = elem->in_num;

    }

}

void FUNC_0(V9fsPDU *VAR_0, struct iovec **VAR_1,
unsigned int *VAR_2, bool VAR_3)
{ V9fsState *s = VAR_0->s; V9fsVirtioState *v = container_of(s, V9fsVirtioState, state); VirtQueueElement *elem = &v->elems[VAR_0->idx]; if (VAR_3) { *VAR_1 = elem->out_sg; *VAR_2 = elem->out_num; } else { *VAR_1 = elem->in_sg; *VAR_2 = elem->in_num; } }