static inline void vring_used_write(VirtQueue *vq, VRingUsedElem *uelem,

                                    int i)

{

    hwaddr pa;

    virtio_tswap32s(vq->vdev, &uelem->id);

    virtio_tswap32s(vq->vdev, &uelem->len);

    pa = vq->vring.used + offsetof(VRingUsed, ring[i]);

    address_space_write(&address_space_memory, pa, MEMTXATTRS_UNSPECIFIED,

                       (void *)uelem, sizeof(VRingUsedElem));

}

static inline void vring_used_write(VirtQueue *vq, VRingUsedElem *uelem,

                                    int i)

{

    hwaddr pa;

    virtio_tswap32s(vq->vdev, &uelem->id);

    virtio_tswap32s(vq->vdev, &uelem->len);

    pa = vq->vring.used + offsetof(VRingUsed, ring[i]);

    address_space_write(&address_space_memory, pa, MEMTXATTRS_UNSPECIFIED,

                       (void *)uelem, sizeof(VRingUsedElem));

}

static inline void FUNC_0(VirtQueue *VAR_0, VRingUsedElem *VAR_1,

                                    int VAR_2)

{

    hwaddr pa;

    virtio_tswap32s(VAR_0->vdev, &VAR_1->id);

    virtio_tswap32s(VAR_0->vdev, &VAR_1->len);

    pa = VAR_0->vring.used + offsetof(VRingUsed, ring[VAR_2]);

    address_space_write(&address_space_memory, pa, MEMTXATTRS_UNSPECIFIED,

                       (void *)VAR_1, sizeof(VRingUsedElem));

}

static inline void FUNC_0(VirtQueue *VAR_0, VRingUsedElem *VAR_1,
int VAR_2)
{ hwaddr pa; virtio_tswap32s(VAR_0->vdev, &VAR_1->id); virtio_tswap32s(VAR_0->vdev, &VAR_1->len); pa = VAR_0->vring.used + offsetof(VRingUsed, ring[VAR_2]); address_space_write(&address_space_memory, pa, MEMTXATTRS_UNSPECIFIED,
(void *)VAR_1, sizeof(VRingUsedElem)); }