Skip to content

Commit a650b1c

Browse files
dtatuleamstsirkin
authored andcommitted
vdpa/mlx5: Collapse "dvq" mr add/delete functions
Now that the cvq code is out of mlx5_vdpa_create/destroy_mr, the "dvq" functions can be folded into their callers. Having "dvq" in the naming will no longer be accurate in the downstream patches. Acked-by: Jason Wang <jasowang@redhat.com> Acked-by: Eugenio Pérez <eperezma@redhat.com> Signed-off-by: Dragos Tatulea <dtatulea@nvidia.com> Message-Id: <20231018171456.1624030-10-dtatulea@nvidia.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
1 parent f67ad6c commit a650b1c

File tree

1 file changed

+5
-11
lines changed
  • drivers/vdpa/mlx5/core

1 file changed

+5
-11
lines changed

drivers/vdpa/mlx5/core/mr.c

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -489,7 +489,7 @@ static void destroy_user_mr(struct mlx5_vdpa_dev *mvdev, struct mlx5_vdpa_mr *mr
489489
}
490490
}
491491

492-
static void _mlx5_vdpa_destroy_dvq_mr(struct mlx5_vdpa_dev *mvdev, unsigned int asid)
492+
static void _mlx5_vdpa_destroy_mr(struct mlx5_vdpa_dev *mvdev, unsigned int asid)
493493
{
494494
struct mlx5_vdpa_mr *mr = &mvdev->mr;
495495

@@ -513,7 +513,7 @@ void mlx5_vdpa_destroy_mr_asid(struct mlx5_vdpa_dev *mvdev, unsigned int asid)
513513

514514
mutex_lock(&mr->mkey_mtx);
515515

516-
_mlx5_vdpa_destroy_dvq_mr(mvdev, asid);
516+
_mlx5_vdpa_destroy_mr(mvdev, asid);
517517

518518
mutex_unlock(&mr->mkey_mtx);
519519
}
@@ -524,9 +524,9 @@ void mlx5_vdpa_destroy_mr(struct mlx5_vdpa_dev *mvdev)
524524
prune_iotlb(mvdev);
525525
}
526526

527-
static int _mlx5_vdpa_create_dvq_mr(struct mlx5_vdpa_dev *mvdev,
528-
struct vhost_iotlb *iotlb,
529-
unsigned int asid)
527+
static int _mlx5_vdpa_create_mr(struct mlx5_vdpa_dev *mvdev,
528+
struct vhost_iotlb *iotlb,
529+
unsigned int asid)
530530
{
531531
struct mlx5_vdpa_mr *mr = &mvdev->mr;
532532
int err;
@@ -550,12 +550,6 @@ static int _mlx5_vdpa_create_dvq_mr(struct mlx5_vdpa_dev *mvdev,
550550
return 0;
551551
}
552552

553-
static int _mlx5_vdpa_create_mr(struct mlx5_vdpa_dev *mvdev,
554-
struct vhost_iotlb *iotlb, unsigned int asid)
555-
{
556-
return _mlx5_vdpa_create_dvq_mr(mvdev, iotlb, asid);
557-
}
558-
559553
int mlx5_vdpa_create_mr(struct mlx5_vdpa_dev *mvdev, struct vhost_iotlb *iotlb,
560554
unsigned int asid)
561555
{

0 commit comments

Comments
 (0)