0x6a/0xa0
> do_syscall_64+0x3c/0x80
> entry_SYSCALL_64_after_hwframe+0x46/0xb0
>
> Fixes: 10cbf8dfaf93 ("vhost-vdpa: clean iotlb map during reset for older
> userspace")
> Reported-by: Dragos Tatulea
This works, thanks for the quick response.
Tested-by: Dragos
On Fri, 2023-10-20 at 18:01 +0200, Eugenio Perez Martin wrote:
> On Wed, Oct 18, 2023 at 7:21 PM Dragos Tatulea wrote:
> >
> > On Wed, 2023-10-18 at 20:14 +0300, Dragos Tatulea wrote:
> > > The current flow for updating an mr works directly on mvdev->mr which
> >
On Wed, 2023-10-18 at 20:14 +0300, Dragos Tatulea wrote:
> The current flow for updating an mr works directly on mvdev->mr which
> makes it cumbersome to handle multiple new mr structs.
>
> This patch makes the flow more straightforward by having
> mlx5_vdpa_create_mr return a
the cvq iotlb with it on a cvq group change.
Acked-by: Jason Wang
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 2 ++
drivers/vdpa/mlx5/core/mr.c| 26 ++
drivers/vdpa/mlx5/net/mlx5_vnet.c | 9 -
3 files
They will be used in a follow-up patch.
For dup_iotlb, avoid the src == dst case. This is an error.
Acked-by: Jason Wang
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mr.c | 19 +++
1 file changed, 11 insertions(+), 8 deletions(-)
diff
ASID mapping.
The feature is signaled to the vdpa core through the presence of the
.get_vq_desc_group op.
Acked-by: Jason Wang
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/net/mlx5_vnet.c | 24 +++-
include/linux/mlx5/mlx5_ifc_vdpa.h | 7
-by: Eugenio Pérez
Acked-by: Jason Wang
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 14 +++--
drivers/vdpa/mlx5/core/mr.c| 87 --
drivers/vdpa/mlx5/net/mlx5_vnet.c | 53 +-
3 files changed, 82 insertions(+), 72 deleti
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 5 +++--
drivers/vdpa/mlx5/core/mr.c| 14 +-
drivers/vdpa/mlx5/net/mlx5_vnet.c | 20 +---
3 files changed, 25 insertions(+), 14 deletions(-)
diff --git a/drivers
The mutex is named like it is supposed to protect only the mkey but in
reality it is a global lock for all mr resources.
Shift the mutex to it's rightful location (struct mlx5_vdpa_dev) and
give it a more appropriate name.
Signed-off-by: Dragos Tatulea
Acked-by: Eugenio Pérez
Acked-by:
This change is needed for a followup patch which will introduce an
additional mr for the vq descriptor data.
Signed-off-by: Dragos Tatulea
Acked-by: Eugenio Pérez
Acked-by: Jason Wang
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 8 +++--
drivers/vdpa/mlx5/core/mr.c
genio Pérez
Reviewed-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mr.c | 10 +-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/drivers/vdpa/mlx5/core/mr.c b/drivers/vdpa/mlx5/core/mr.c
index fcb6ae32e9ed..587300e7c18e 100644
--- a/drivers/vdpa
all in the same "update" function.
Finally, the destruction path is handled by directly pruning the iotlb.
After this move is done the ASID mr code can be collapsed into a single
function.
Acked-by: Jason Wang
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa
From: Si-Wei Liu
With _F_DESC_ASID backend feature, the device can now support the
VHOST_VDPA_GET_VRING_DESC_GROUP ioctl, and it may expose the descriptor
table (including avail and used ring) in a different group than the
buffers it contains. This new uAPI will fetch the group ID of the
descript
Make mlx5_destroy_mr symmetric to mlx5_create_mr.
Acked-by: Jason Wang
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 4 ++--
drivers/vdpa/mlx5/core/mr.c| 6 +++---
drivers/vdpa/mlx5/net/mlx5_vnet.c | 12 ++--
3 files changed
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
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
--
From: Si-Wei Liu
Userspace knows if the device has dedicated descriptor group or not
by checking this feature bit.
It's only exposed if the vdpa driver backend implements the
.get_vq_desc_group() operation callback. Userspace trying to negotiate
this feature when it or the dependent _F_IOTLB_ASI
Necessary for upcoming cvq separation from mr allocation.
Acked-by: Jason Wang
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 1 +
drivers/vdpa/mlx5/core/mr.c| 5 +
drivers/vdpa/mlx5/net/mlx5_vnet.c | 4 ++--
3 files changed, 8 insertions(+), 2 deletions
From: Si-Wei Liu
In some cases, the access to the virtqueue's descriptor area, device
and driver areas (precluding indirect descriptor table in guest memory)
may have to be confined to a different address space than where its
buffers reside. Without loss of simplicity and generality with already
Necessary for improved live migration flow. Actual support will be added
in a downstream patch.
Signed-off-by: Dragos Tatulea
Reviewed-by: Gal Pressman
---
include/linux/mlx5/mlx5_ifc.h | 8 +++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/include/linux/mlx5/mlx5_ifc.h b
d fom mlx5-vdpa into the vhost
tree and only then the remaining patches can be applied.
[0]
https://lore.kernel.org/virtualization/1694248959-13369-1-git-send-email-si-wei@oracle.com
[1]
https://git.kernel.org/pub/scm/linux/kernel/git/mellanox/linux.git/log/?h=mlx5-vhost
Dragos Tatulea (13):
the cvq iotlb with it on a cvq group change.
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 2 ++
drivers/vdpa/mlx5/core/mr.c| 26 ++
drivers/vdpa/mlx5/net/mlx5_vnet.c | 9 -
3 files changed, 36
They will be used in a follow-up patch.
For dup_iotlb, avoid the src == dst case. This is an error.
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mr.c | 19 +++
1 file changed, 11 insertions(+), 8 deletions(-)
diff --git a/drivers/vdpa/mlx5
ASID mapping.
The feature is signaled to the vdpa core through the presence of the
.get_vq_desc_group op.
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/net/mlx5_vnet.c | 24 +++-
include/linux/mlx5/mlx5_ifc_vdpa.h | 7 ++-
2 files changed
Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 5 +++--
drivers/vdpa/mlx5/core/mr.c| 14 +-
drivers/vdpa/mlx5/net/mlx5_vnet.c | 20 +---
3 files changed, 25 insertions(+), 14 deletions(-)
diff --git a/drivers/vdpa/mlx5/core/mlx5_vdpa
ked from mvdev.
This change paves the way for adding mrs for different ASIDs.
The initialized bool is no longer needed as mr is now a pointer in the
mlx5_vdpa_dev struct which will be NULL when not initialized.
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/c
This change is needed for a followup patch which will introduce an
additional mr for the vq descriptor data.
Signed-off-by: Dragos Tatulea
Acked-by: Eugenio Pérez
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 8 +++--
drivers/vdpa/mlx5/core/mr.c| 53 ++
drivers/vdpa
The mutex is named like it is supposed to protect only the mkey but in
reality it is a global lock for all mr resources.
Shift the mutex to it's rightful location (struct mlx5_vdpa_dev) and
give it a more appropriate name.
Signed-off-by: Dragos Tatulea
Acked-by: Eugenio Pérez
---
drivers
Make mlx5_destroy_mr symmetric to mlx5_create_mr.
Acked-by: Jason Wang
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 4 ++--
drivers/vdpa/mlx5/core/mr.c| 6 +++---
drivers/vdpa/mlx5/net/mlx5_vnet.c | 12 ++--
3 files changed
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
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
--
Necessary for upcoming cvq separation from mr allocation.
Acked-by: Jason Wang
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 1 +
drivers/vdpa/mlx5/core/mr.c| 5 +
drivers/vdpa/mlx5/net/mlx5_vnet.c | 4 ++--
3 files changed, 8 insertions(+), 2 deletions
all in the same "update" function.
Finally, the destruction path is handled by directly pruning the iotlb.
After this move is done the ASID mr code can be collapsed into a single
function.
Acked-by: Jason Wang
Acked-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa
genio Pérez
Reviewed-by: Eugenio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mr.c | 10 +-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/drivers/vdpa/mlx5/core/mr.c b/drivers/vdpa/mlx5/core/mr.c
index fcb6ae32e9ed..587300e7c18e 100644
--- a/drivers/vdpa
From: Si-Wei Liu
With _F_DESC_ASID backend feature, the device can now support the
VHOST_VDPA_GET_VRING_DESC_GROUP ioctl, and it may expose the descriptor
table (including avail and used ring) in a different group than the
buffers it contains. This new uAPI will fetch the group ID of the
descript
From: Si-Wei Liu
In some cases, the access to the virtqueue's descriptor area, device
and driver areas (precluding indirect descriptor table in guest memory)
may have to be confined to a different address space than where its
buffers reside. Without loss of simplicity and generality with already
From: Si-Wei Liu
Userspace knows if the device has dedicated descriptor group or not
by checking this feature bit.
It's only exposed if the vdpa driver backend implements the
.get_vq_desc_group() operation callback. Userspace trying to negotiate
this feature when it or the dependent _F_IOTLB_ASI
Necessary for improved live migration flow. Actual support will be added
in a downstream patch.
Reviewed-by: Gal Pressman
Signed-off-by: Dragos Tatulea
---
include/linux/mlx5/mlx5_ifc.h | 8 +++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/include/linux/mlx5/mlx5_ifc.h b
ost
tree and only then the remaining patches can be applied.
[0]
https://lore.kernel.org/virtualization/1694248959-13369-1-git-send-email-si-wei@oracle.com
[1]
https://git.kernel.org/pub/scm/linux/kernel/git/mellanox/linux.git/log/?h=mlx5-vhost
Dragos Tatulea (13):
vdpa/mlx5: Expose descri
On Mon, 2023-10-09 at 14:39 +0800, Jason Wang wrote:
> On Sun, Oct 8, 2023 at 8:05 PM Dragos Tatulea wrote:
> >
> > On Sun, 2023-10-08 at 12:25 +0800, Jason Wang wrote:
> > > On Tue, Sep 26, 2023 at 3:21 PM Dragos Tatulea
> > > wrote:
> > > >
>
On Sun, 2023-10-08 at 12:25 +0800, Jason Wang wrote:
> On Tue, Sep 26, 2023 at 3:21 PM Dragos Tatulea wrote:
> >
> > On Tue, 2023-09-26 at 12:44 +0800, Jason Wang wrote:
> > > On Tue, Sep 12, 2023 at 9:02 PM Dragos Tatulea
> > > wrote:
> > > >
>
On Thu, 2023-10-05 at 13:31 -0400, Michael S. Tsirkin wrote:
> On Thu, Sep 28, 2023 at 07:45:11PM +0300, Dragos Tatulea wrote:
> > This patch series adds support for vq descriptor table mappings which
> > are used to improve vdpa live migration downtime. The improvement comes
On Thu, 2023-10-05 at 12:41 +0200, Eugenio Perez Martin wrote:
> On Thu, Sep 28, 2023 at 6:50 PM Dragos Tatulea wrote:
> >
> > For the following sequence:
> > - cvq group is in ASID 0
> > - .set_map(1, cvq_iotlb)
> > - .set_group_asid(cvq_group, 1)
> >
&
On Thu, 2023-10-05 at 12:14 +0200, Eugenio Perez Martin wrote:
> On Thu, Sep 28, 2023 at 6:50 PM Dragos Tatulea wrote:
> >
> > They will be used in a followup patch.
> >
> > Signed-off-by: Dragos Tatulea
> > ---
> > drivers/vdpa/mlx5/core/mr.c | 16
On Thu, 2023-10-05 at 11:42 +0200, Eugenio Perez Martin wrote:
> On Thu, Sep 28, 2023 at 6:50 PM Dragos Tatulea wrote:
> >
> > Vq descriptor mappings are supported in hardware by filling in an
> > additional mkey which contains the descriptor mappings to the hw vq.
> &g
On Wed, 2023-10-04 at 20:53 +0200, Eugenio Perez Martin wrote:
> On Thu, Sep 28, 2023 at 6:50 PM Dragos Tatulea wrote:
> >
> > Introduce the vq descriptor group and ASID 1. Until now .set_map on ASID
>
> s/ASID/vq group/?
>
Oh, indeed.
> > 1 was only updating
On Thu, 2023-09-28 at 19:45 +0300, Dragos Tatulea wrote:
> This patch adapts the mr creation/deletion code to be able to work with
> any given mr struct pointer. All the APIs are adapted to take an extra
> parameter for the mr.
>
> mlx5_vdpa_create/delete_mr doesn't need a AS
They will be used in a followup patch.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mr.c | 16
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/drivers/vdpa/mlx5/core/mr.c b/drivers/vdpa/mlx5/core/mr.c
index 3dee6d9bed6b..a4135c16b5bf 100644
--- a
the cvq iotlb with it on a cvq group change.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 2 ++
drivers/vdpa/mlx5/core/mr.c| 26 ++
drivers/vdpa/mlx5/net/mlx5_vnet.c | 9 -
3 files changed, 36 insertions(+), 1 deletion(-)
diff
ASID mapping.
The feature is signaled to the vdpa core through the presence of the
.get_vq_desc_group op.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/net/mlx5_vnet.c | 26 --
include/linux/mlx5/mlx5_ifc_vdpa.h | 7 ++-
2 files changed, 30 insertions(+), 3
Introduce the vq descriptor group and ASID 1. Until now .set_map on ASID
1 was only updating the cvq iotlb. From now on it also creates a mkey
for it. The current patch doesn't use it but follow-up patches will
add hardware support for mapping the vq descriptors.
Signed-off-by: Dragos Ta
The mutex is named like it is supposed to protect only the mkey but in
reality it is a global lock for all mr resources.
Shift the mutex to it's rightful location (struct mlx5_vdpa_dev) and
give it a more appropriate name.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_v
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
Signed-off-by: Dragos Tatulea
---
drivers/vdpa
ked from mvdev.
This change paves the way for adding mrs for different ASIDs.
The initialized bool is no longer needed as mr is now a pointer in the
mlx5_vdpa_dev struct which will be NULL when not initialized.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 14 +++--
driv
genio Pérez
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mr.c | 10 +-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/drivers/vdpa/mlx5/core/mr.c b/drivers/vdpa/mlx5/core/mr.c
index fcb6ae32e9ed..587300e7c18e 100644
--- a/drivers/vdpa/mlx5/core/mr.c
+++ b/drivers
This change is needed for a followup patch which will introduce an
additional mr for the vq descriptor data.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 8 +++--
drivers/vdpa/mlx5/core/mr.c| 53 ++
drivers/vdpa/mlx5/net/mlx5_vnet.c
Make mlx5_destroy_mr symmetric to mlx5_create_mr.
Acked-by: Jason Wang
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 4 ++--
drivers/vdpa/mlx5/core/mr.c| 6 +++---
drivers/vdpa/mlx5/net/mlx5_vnet.c | 12 ++--
3 files changed, 11 insertions(+), 11
all in the same "update" function.
Finally, the destruction path is handled by directly pruning the iotlb.
After this move is done the ASID mr code can be collapsed into a single
function.
Acked-by: Jason Wang
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 3 +
From: Si-Wei Liu
With _F_DESC_ASID backend feature, the device can now support the
VHOST_VDPA_GET_VRING_DESC_GROUP ioctl, and it may expose the descriptor
table (including avail and used ring) in a different group than the
buffers it contains. This new uAPI will fetch the group ID of the
descript
Necessary for upcoming cvq separation from mr allocation.
Acked-by: Jason Wang
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 1 +
drivers/vdpa/mlx5/core/mr.c| 5 +
drivers/vdpa/mlx5/net/mlx5_vnet.c | 4 ++--
3 files changed, 8 insertions(+), 2 deletions
From: Si-Wei Liu
Userspace knows if the device has dedicated descriptor group or not
by checking this feature bit.
It's only exposed if the vdpa driver backend implements the
.get_vq_desc_group() operation callback. Userspace trying to negotiate
this feature when it or the dependent _F_IOTLB_ASI
From: Si-Wei Liu
In some cases, the access to the virtqueue's descriptor area, device
and driver areas (precluding indirect descriptor table in guest memory)
may have to be confined to a different address space than where its
buffers reside. Without loss of simplicity and generality with already
Necessary for improved live migration flow. Actual support will be added
in a downstream patch.
Reviewed-by: Gal Pressman
Signed-off-by: Dragos Tatulea
---
include/linux/mlx5/mlx5_ifc.h | 8 +++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/include/linux/mlx5/mlx5_ifc.h b
y then the remaining patches can be applied.
[0]
https://lore.kernel.org/virtualization/1694248959-13369-1-git-send-email-si-wei@oracle.com
[1]
https://git.kernel.org/pub/scm/linux/kernel/git/mellanox/linux.git/log/?h=mlx5-next
Dragos Tatulea (13):
vdpa/mlx5: Expose descriptor group mkey hw
y then the remaining patches can be applied.
[0]
https://lore.kernel.org/virtualization/1694248959-13369-1-git-send-email-si-wei@oracle.com
[1]
https://git.kernel.org/pub/scm/linux/kernel/git/mellanox/linux.git/log/?h=mlx5-next
Dragos Tatulea (13):
vdpa/mlx5: Expose descriptor group mkey hw
On Tue, 2023-09-26 at 05:22 -0700, Si-Wei Liu wrote:
>
>
> On 9/25/2023 12:59 AM, Dragos Tatulea wrote:
> > On Tue, 2023-09-12 at 16:01 +0300, Dragos Tatulea wrote:
> > > This patch series adds support for vq descriptor table mappings which
> > > are used to imp
On Tue, 2023-09-26 at 12:44 +0800, Jason Wang wrote:
> On Tue, Sep 12, 2023 at 9:02 PM Dragos Tatulea wrote:
> >
> > This patch adapts the mr creation/deletion code to be able to work with
> > any given mr struct pointer. All the APIs are adapted to take an extra
>
As Eli Cohen moved to other work, I'll be the contact point for
mlx5_vdpa.
Acked-by: Jason Wang
Signed-off-by: Dragos Tatulea
---
Changes since v1:
- Fix alphabetical sorting.
- Make naming consistent with other MELLANOX entries.
---
MAINTAINERS | 6 ++
1 file changed, 6 inser
On Tue, 2023-09-12 at 16:01 +0300, Dragos Tatulea wrote:
> This patch series adds support for vq descriptor table mappings which
> are used to improve vdpa live migration downtime. The improvement comes
> from using smaller mappings which take less time to create and destroy
> in h
On Tue, 2023-08-29 at 20:40 +0300, Dragos Tatulea wrote:
> The error path in setup_driver deletes the debugfs entry but doesn't
> clear the pointer. During .dev_del the invalid pointer will be released
> again causing a crash.
>
> This patch fixes the issue by always clearing
On Thu, 2023-08-31 at 18:50 +0300, Dragos Tatulea wrote:
> A firmware error is triggered when configuring a 9k MTU on the PF after
> switching to switchdev mode and then using a vdpa device with larger
> (1k) rings:
> mlx5_cmd_out_err: CREATE_GENERAL_OBJECT(0xa00) op_mod(0xd) failed
ASID mapping.
The feature is signaled to the vdpa core through the presence of the
.get_vq_desc_group op.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/net/mlx5_vnet.c | 26 --
include/linux/mlx5/mlx5_ifc.h | 8 +++-
include/linux/mlx5/mlx5_ifc_vdpa.h | 7
Introduce the vq descriptor group and ASID 1. Until now .set_map on ASID
1 was only updating the cvq iotlb. From now on it also creates a mkey
for it. The current patch doesn't use it but follow-up patches will
add hardware support for mapping the vq descriptors.
Signed-off-by: Dragos Ta
ked from mvdev.
This change paves the way for adding mrs for different ASIDs.
The initialized bool is no longer needed as mr is now a pointer in the
mlx5_vdpa_dev struct which will be NULL when not initialized.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 14 +++--
driv
They will be used in a followup patch.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mr.c | 16
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/drivers/vdpa/mlx5/core/mr.c b/drivers/vdpa/mlx5/core/mr.c
index 3dee6d9bed6b..a4135c16b5bf 100644
--- a
the cvq iotlb with it on a cvq group change.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 2 ++
drivers/vdpa/mlx5/core/mr.c| 26 ++
drivers/vdpa/mlx5/net/mlx5_vnet.c | 9 -
3 files changed, 36 insertions(+), 1 deletion(-)
diff
The mutex is named like it is supposed to protect only the mkey but in
reality it is a global lock for all mr resources.
Shift the mutex to it's rightful location (struct mlx5_vdpa_dev) and
give it a more appropriate name.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_v
all in the same "update" function.
Finally, the destruction path is handled by directly pruning the iotlb.
After this move is done the ASID mr code can be collapsed into a single
function.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 3 ++
drivers/vdpa/mlx5
Make mlx5_destroy_mr symmetric to mlx5_create_mr.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 4 ++--
drivers/vdpa/mlx5/core/mr.c| 6 +++---
drivers/vdpa/mlx5/net/mlx5_vnet.c | 12 ++--
3 files changed, 11 insertions(+), 11 deletions(-)
diff --git
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.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mr.c | 16
This change is needed for a followup patch which will introduce an
additional mr for the vq descriptor data.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 8 +++--
drivers/vdpa/mlx5/core/mr.c| 53 ++
drivers/vdpa/mlx5/net/mlx5_vnet.c
ff-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mr.c | 10 +-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/drivers/vdpa/mlx5/core/mr.c b/drivers/vdpa/mlx5/core/mr.c
index fcb6ae32e9ed..587300e7c18e 100644
--- a/drivers/vdpa/mlx5/core/mr.c
+++ b/drivers/vdpa/mlx5/core
From: Si-Wei Liu
In some cases, the access to the virtqueue's descriptor area, device
and driver areas (precluding indirect descriptor table in guest memory)
may have to be confined to a different address space than where its
buffers reside. Without loss of simplicity and generality with already
From: Si-Wei Liu
Userspace knows if the device has dedicated descriptor group or not
by checking this feature bit.
It's only exposed if the vdpa driver backend implements the
.get_vq_desc_group() operation callback. Userspace trying to negotiate
this feature when it or the dependent _F_IOTLB_ASI
Necessary for upcoming cvq separation from mr allocation.
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/core/mlx5_vdpa.h | 1 +
drivers/vdpa/mlx5/core/mr.c| 5 +
drivers/vdpa/mlx5/net/mlx5_vnet.c | 4 ++--
3 files changed, 8 insertions(+), 2 deletions(-)
diff --git a/drivers
From: Si-Wei Liu
With _F_DESC_ASID backend feature, the device can now support the
VHOST_VDPA_GET_VRING_DESC_GROUP ioctl, and it may expose the descriptor
table (including avail and used ring) in a different group than the
buffers it contains. This new uAPI will fetch the group ID of the
descript
adds support in mlx5_vdpa:
- Refactor the mr code to be able to cleanly add descriptor mappings.
- Add hardware descriptor mr support.
- Properly update iotlb for cvq during ASID switch.
[0]
https://lore.kernel.org/virtualization/1694248959-13369-1-git-send-email-si-wei@oracle.com
Dragos
Hi Jason,
On Mon, 2023-09-11 at 14:43 +0800, Jason Wang wrote:
> On Sat, Sep 9, 2023 at 4:45 PM Si-Wei Liu wrote:
> >
> > Following patchset introduces dedicated group for descriptor table to
> > reduce live migration downtime when passthrough VQ is being switched
> > to shadow VQ. This RFC v2 i
.
v2:
- Allocate output with kmalloc to reduce stack frame size.
- Removed stable from cc.
Fixes: 1a86b377aa21 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices")
Signed-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/net/mlx5_vnet.c | 63 ++-
driver
Fixes: 1a86b377aa21 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices")
Signed-off-by: Dragos Tatulea
Reviewed-by: Saeed Mahameed
---
drivers/vdpa/mlx5/net/mlx5_vnet.c | 55 ++-
drivers/vdpa/mlx5/net/mlx5_vnet.h | 9 +
2 files changed, 55 insertions(
ry in
.dev_del op: the debugfs entry is already handled within the
setup_driver/teardown_driver scope.
Fixes: f0417e72add5 ("vdpa/mlx5: Add and remove debugfs in setup/teardown
driver")
Signed-off-by: Dragos Tatulea
Reviewed-by: Gal Pressman
---
drivers/vdpa/mlx5/net/debug.c | 5
As Eli Cohen moved to other work, I'll be the contact point for
mlx5_vdpa.
Signed-off-by: Dragos Tatulea
---
MAINTAINERS | 6 ++
1 file changed, 6 insertions(+)
diff --git a/MAINTAINERS b/MAINTAINERS
index 9a5863f1b016..c9a9259f4d37 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -13
On Mon, 2023-08-14 at 18:43 -0700, Si-Wei Liu wrote:
> This patch is based on top of the "vdpa/mlx5: Fixes
> for ASID handling" series [1].
>
> [1] vdpa/mlx5: Fixes for ASID handling
> https://lore.kernel.org/virtualization/20230802171231.11001-1-dtatu...@nvidia.com/
>
> Signed-off-by: Si-Wei Liu
On Wed, 2023-08-09 at 09:42 +0800, Jason Wang wrote:
> On Tue, Aug 8, 2023 at 3:24 PM Dragos Tatulea wrote:
> >
> > On Tue, 2023-08-08 at 10:57 +0800, Jason Wang wrote:
> > > On Thu, Aug 3, 2023 at 7:40 PM Dragos Tatulea wrote:
> > > >
> > > &g
On Thu, 2023-08-10 at 04:54 -0400, Michael S. Tsirkin wrote:
> On Wed, Aug 02, 2023 at 08:12:16PM +0300, Dragos Tatulea wrote:
> > This patch series is based on Eugenio's fix for handling CVQs in
> > a different ASID [0].
> >
> > The first patch is the actual fix.
Fixing this by setting queues after virtio_device_ready().
>
> Fixes: 25266128fe16 ("virtio-net: fix race between set queues and probe")
> Reported-by: Dragos Tatulea
> Signed-off-by: Jason Wang
> ---
> The patch is needed for -stable.
> ---
> drivers/net/vir
On Tue, 2023-07-25 at 03:20 -0400, Jason Wang wrote:
> A race were found where set_channels could be called after registering
> but before virtnet_set_queues() in virtnet_probe(). Fixing this by
> moving the virtnet_set_queues() before netdevice registering. While at
> it, use _virtnet_set_queues()
On Tue, 2023-08-08 at 10:57 +0800, Jason Wang wrote:
> On Thu, Aug 3, 2023 at 7:40 PM Dragos Tatulea wrote:
> >
> > On Thu, 2023-08-03 at 16:03 +0800, Jason Wang wrote:
> > > On Thu, Aug 3, 2023 at 1:13 AM Dragos Tatulea wrote:
> > > >
> > > >
ned-off-by: Dragos Tatulea
---
drivers/vdpa/mlx5/net/mlx5_vnet.c | 12
1 file changed, 12 deletions(-)
diff --git a/drivers/vdpa/mlx5/net/mlx5_vnet.c
b/drivers/vdpa/mlx5/net/mlx5_vnet.c
index 9138ef2fb2c8..047b069a5622 100644
--- a/drivers/vdpa/mlx5/net/mlx5_vnet.c
+++ b/drivers/vdp
On Wed, 2023-08-02 at 09:56 +0200, Dragos Tatulea wrote:
> On Wed, 2023-08-02 at 10:51 +0800, Jason Wang wrote:
> > On Tue, Aug 1, 2023 at 4:17 PM Dragos Tatulea wrote:
> > >
> > > On Tue, 2023-08-01 at 11:59 +0800, Jason Wang wrote:
> > > > On Mon, Jul
On Thu, 2023-08-03 at 16:03 +0800, Jason Wang wrote:
> On Thu, Aug 3, 2023 at 1:13 AM Dragos Tatulea wrote:
> >
> > The mr->initialized flag is shared between the control vq and data vq
> > part of the mr init/uninit. But if the control vq and data vq get placed
> &
From: Eugenio Pérez
mlx5_vdpa_destroy_mr can be called from .set_map with data ASID after
the control virtqueue ASID iotlb has been populated. The control vq
iotlb must not be cleared, since it will not be populated again.
So call the ASID aware destroy function which makes sure that the
right v
1 - 100 of 135 matches
Mail list logo