[PATCH v2] vdpa/mlx5: workaround var offset within page
Maxime Coquelin
maxime.coquelin at redhat.com
Wed Jun 1 09:55:00 CEST 2022
Hi Yajun,
On 3/15/22 03:47, Yajun Wu wrote:
> vDPA driver first uses kernel driver to allocate doorbell(VAR) area for
> each device. Then uses var->mmap_off and var->length to mmap uverbs device
> file as doorbell userspace virtual address.
>
> Current kernel driver provides var->mmap_off equal to page start of VAR.
> It's fine with x86 4K page server, because VAR physical address is only 4K
> aligned thus locate in 4K page start.
>
> But with aarch64 64K page server, the actual VAR physical address has
> offset within page(not locate in 64K page start). So vDPA driver need add
> this within page offset(caps.doorbell_bar_offset) to get right VAR virtual
> address.
>
> Fixes: 62c813706e4 ("vdpa/mlx5: map doorbell")
> Cc: stable at dpdk.org
>
> Signed-off-by: Yajun Wu <yajunw at nvidia.com>
> Acked-by: Matan Azrad <matan at nvidia.com>
> ---
> drivers/vdpa/mlx5/mlx5_vdpa_virtq.c | 9 ++++++++-
> 1 file changed, 8 insertions(+), 1 deletion(-)
>
Reviewed-by: Maxime Coquelin <maxime.coquelin at redhat.com>
Thanks,
Maxime
More information about the stable
mailing list