On Fri, Jul 06, 2018 at 09:07:10AM +0200, Maxime Coquelin wrote:
[...]
> diff --git a/lib/librte_vhost/vhost_user.c b/lib/librte_vhost/vhost_user.c
> index bea6a0428..dca43ff00 100644
> --- a/lib/librte_vhost/vhost_user.c
> +++ b/lib/librte_vhost/vhost_user.c
> @@ -467,6 +467,27 @@ translate_ring_addresses(struct virtio_net *dev, int 
> vq_index)
>       struct vhost_vring_addr *addr = &vq->ring_addrs;
>       uint64_t len;
>  
> +     if (vq_is_packed(dev)) {
> +             len = sizeof(struct vring_packed_desc) * vq->size;
> +             vq->desc_packed = (struct vring_packed_desc *) ring_addr_to_vva

FYI, above code will cause below build error on 32bit platform:

/tmp/dpdk-build/lib/librte_vhost/vhost_user.c: In function 
‘translate_ring_addresses’:
/tmp/dpdk-build/lib/librte_vhost/vhost_user.c:472:21: error: cast to pointer 
from integer of different size [-Werror=int-to-pointer-cast]
   vq->desc_packed = (struct vring_packed_desc *) ring_addr_to_vva
                     ^

I'll fix it while applying.

Reply via email to