Re: [PATCH v1] vdpa/mlx5: Fix memory key MTT population

2021-01-20 Thread Eli Cohen
On Wed, Jan 20, 2021 at 03:52:00AM -0500, Michael S. Tsirkin wrote: > On Wed, Jan 20, 2021 at 10:11:54AM +0200, Eli Cohen wrote: > > On Wed, Jan 20, 2021 at 02:57:05AM -0500, Michael S. Tsirkin wrote: > > > On Wed, Jan 20, 2021 at 07:36:19AM +0200, Eli Cohen wrote: > > > > On Fri, Jan 08, 2021 at

Re: [PATCH v1] vdpa/mlx5: Fix memory key MTT population

2021-01-20 Thread Michael S. Tsirkin
On Wed, Jan 20, 2021 at 10:11:54AM +0200, Eli Cohen wrote: > On Wed, Jan 20, 2021 at 02:57:05AM -0500, Michael S. Tsirkin wrote: > > On Wed, Jan 20, 2021 at 07:36:19AM +0200, Eli Cohen wrote: > > > On Fri, Jan 08, 2021 at 04:38:55PM +0800, Jason Wang wrote: > > > > > > Hi Michael, > > > this

Re: [PATCH v1] vdpa/mlx5: Fix memory key MTT population

2021-01-20 Thread Eli Cohen
On Wed, Jan 20, 2021 at 02:57:05AM -0500, Michael S. Tsirkin wrote: > On Wed, Jan 20, 2021 at 07:36:19AM +0200, Eli Cohen wrote: > > On Fri, Jan 08, 2021 at 04:38:55PM +0800, Jason Wang wrote: > > > > Hi Michael, > > this patch is a fix. Are you going to merge it? > > yes - in the next pull

Re: [PATCH v1] vdpa/mlx5: Fix memory key MTT population

2021-01-20 Thread Michael S. Tsirkin
On Wed, Jan 20, 2021 at 07:36:19AM +0200, Eli Cohen wrote: > On Fri, Jan 08, 2021 at 04:38:55PM +0800, Jason Wang wrote: > > Hi Michael, > this patch is a fix. Are you going to merge it? yes - in the next pull request. > > > > On 2021/1/7 下午3:18, Eli Cohen wrote: > > > map_direct_mr() assumed

Re: [PATCH v1] vdpa/mlx5: Fix memory key MTT population

2021-01-19 Thread Eli Cohen
On Fri, Jan 08, 2021 at 04:38:55PM +0800, Jason Wang wrote: Hi Michael, this patch is a fix. Are you going to merge it? > > On 2021/1/7 下午3:18, Eli Cohen wrote: > > map_direct_mr() assumed that the number of scatter/gather entries > > returned by dma_map_sg_attrs() was equal to the number of

Re: [PATCH v1] vdpa/mlx5: Fix memory key MTT population

2021-01-08 Thread Jason Wang
On 2021/1/7 下午3:18, Eli Cohen wrote: map_direct_mr() assumed that the number of scatter/gather entries returned by dma_map_sg_attrs() was equal to the number of segments in the sgl list. This led to wrong population of the mkey object. Fix this by properly referring to the returned value. The

[PATCH v1] vdpa/mlx5: Fix memory key MTT population

2021-01-06 Thread Eli Cohen
map_direct_mr() assumed that the number of scatter/gather entries returned by dma_map_sg_attrs() was equal to the number of segments in the sgl list. This led to wrong population of the mkey object. Fix this by properly referring to the returned value. The hardware expects each MTT entry to