> -----Original Message-----
> From: Maxime Coquelin <[email protected]>
> Sent: Wednesday, September 23, 2020 5:15 PM
> To: Fu, Patrick <[email protected]>; [email protected]; Xia, Chenbo
> <[email protected]>
> Cc: Wang, Zhihong <[email protected]>; Jiang, Cheng1
> <[email protected]>
> Subject: Re: [PATCH v1 2/4] vhost: dynamically alloc async memory
>
> s/alloc/allocate/
>
Fix in v2
> On 9/11/20 3:53 AM, Patrick Fu wrote:
> > alloc async internal memory buffer by rte_malloc(), replacing array
>
> Allocate async internal memory buffer with rte_malloc()
>
Fix in v2
> > index 28aa77380..0af0ac23d 100644
> > --- a/lib/librte_vhost/vhost.h
> > +++ b/lib/librte_vhost/vhost.h
> > @@ -218,8 +218,8 @@ struct vhost_virtqueue {
> > /* operation callbacks for async dma */
> > struct rte_vhost_async_channel_ops async_ops;
> >
> > - struct rte_vhost_iov_iter it_pool[VHOST_MAX_ASYNC_IT];
> > - struct iovec vec_pool[VHOST_MAX_ASYNC_VEC];
> > + struct rte_vhost_iov_iter *it_pool;
> > + struct iovec *vec_pool;
> >
> > /* async data transfer status */
> > uintptr_t **async_pkts_pending;
> >
>
> I think you should also take care of reallocating on the same numa node
> the ring is (seel numa_realloc().
Agree, will add numa based allocation in v2
Thanks,
Patrick