Re: [PATCH v4 1/2] char: xillybus: Move class-related functions to new xillybus_class.c

2021-03-23 Thread Eli Billauer
ransition on a kernel upgrade, by adding XILLYBUS_CLASS to kernels that had CONFIG_XILLYBUS enabled. Is there another way to prevent the said bug, without "select"? Thanks and regards, Eli

Re: [PATCH v4 1/2] char: xillybus: Move class-related functions to new xillybus_class.c

2021-03-22 Thread Eli Billauer
rect value smoothly and silently. Besides, isn't this the intended use case for "select"? A config symbol that doesn't depend on anything else, and solves a technical need to compile Y if X is enabled? Or is there a way to use "depends on" without this problem? Regards, Eli

Re: [PATCH v4 2/2] staging: Add driver for XillyUSB (Xillybus variant for USB)

2021-03-22 Thread Eli Billauer
gic emulating it, such as registers). This holds true for the existing Xillybus API as well as the one for XillyUSB. Thanks and regards, Eli

[PATCH v4 2/2] staging: Add driver for XillyUSB (Xillybus variant for USB)

2021-03-11 Thread eli . billauer
From: Eli Billauer The XillyUSB driver is the USB variant for the Xillybus FPGA IP core. Even though it presents a nearly identical API on the FPGA and host, it's almost a complete rewrite of the driver: The framework for exchanging data on a USB bus is fundamentally different from doin

[PATCH v4 0/2] Submission of XillyUSB driver

2021-03-11 Thread eli . billauer
From: Eli Billauer This is a resubmission of the XillyUSB driver, which is the USB variant of the existing Xillybus driver. Because these driver share some API related functions, this submission consists of two patches: (1) A patch moving away Xillybus' class related functions

[PATCH v4 1/2] char: xillybus: Move class-related functions to new xillybus_class.c

2021-03-11 Thread eli . billauer
From: Eli Billauer This patch is a preparation for adding another related driver, XillyUSB. In order to share some code between the existing Xillybus driver and the one to be added, some functions are moved to xillybus_class.c The header file, xillybus_class.h, is temporarily placed in include

Re: [kbuild] Re: [PATCH v3 1/2] char: xillybus: Move class-related functions to new xillybus_class.c

2021-03-10 Thread Eli Billauer
On 09/03/21 18:03, Dan Carpenter wrote: url:https://github.com/0day-ci/linux/commits/eli-billauer-gmail-com/Submission-of-XillyUSB-driver/20210309-193645 base:https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc.git 080951f99de1e483a9a48f34c079b634f2912a54 config: x86_64

[PATCH v3 1/2] char: xillybus: Move class-related functions to new xillybus_class.c

2021-03-09 Thread eli . billauer
From: Eli Billauer This patch is a preparation for adding another related driver, XillyUSB. In order to share some code between the existing Xillybus driver and the one to be added, some functions are moved to xillybus_class.c The header file, xillybus_class.h, is temporarily placed in include

[PATCH v3 2/2] staging: Add driver for XillyUSB (Xillybus variant for USB)

2021-03-09 Thread eli . billauer
From: Eli Billauer The XillyUSB driver is the USB variant for the Xillybus FPGA IP core. Even though it presents a nearly identical API on the FPGA and host, it's almost a complete rewrite of the driver: The framework for exchanging data on a USB bus is fundamentally different from doin

[PATCH v3 0/2] Submission of XillyUSB driver

2021-03-09 Thread eli . billauer
From: Eli Billauer This is a resubmission of the XillyUSB driver, which is the USB variant of the existing Xillybus driver. Because these driver share some API related functions, this submission consists of two patches: (1) A patch moving away Xillybus' class related functions

Re: [PATCH] vdpa/mlx5: Fix wrong use of bit numbers

2021-03-02 Thread Eli Cohen
On Mon, Mar 01, 2021 at 10:33:14AM -0500, Michael S. Tsirkin wrote: > On Mon, Mar 01, 2021 at 03:52:45PM +0800, Jason Wang wrote: > > > > On 2021/3/1 2:28 下午, Eli Cohen wrote: > > > VIRTIO_F_VERSION_1 is a bit number. Use BIT_ULL() with mask > > > co

[PATCH] vdpa/mlx5: Fix wrong use of bit numbers

2021-02-28 Thread Eli Cohen
VIRTIO_F_VERSION_1 is a bit number. Use BIT_ULL() with mask conditionals. Also, in mlx5_vdpa_is_little_endian() use BIT_ULL for consistency with the rest of the code. Fixes: 1a86b377aa21 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices") Signed-off-by: Eli Cohen --- drivers

Not yet merged patches

2021-02-28 Thread Eli Cohen
Hi Michael, I see that you did not include these in your latest pull request. https://lkml.org/lkml/2021/2/10/1386 https://lkml.org/lkml/2021/2/10/1383 https://lkml.org/lkml/2021/2/18/124 Are you going to merge them?

Re: [PATCH] vdpa/mlx5: set_features should allow reset to zero

2021-02-24 Thread Eli Cohen
On Wed, Feb 24, 2021 at 02:12:01AM -0500, Michael S. Tsirkin wrote: > On Wed, Feb 24, 2021 at 02:55:13PM +0800, Jason Wang wrote: > > > > On 2021/2/24 2:47 下午, Michael S. Tsirkin wrote: > > > On Wed, Feb 24, 2021 at 08:45:20AM +0200, Eli Cohen wrote: > > > >

Re: [PATCH] vdpa/mlx5: set_features should allow reset to zero

2021-02-23 Thread Eli Cohen
On Wed, Feb 24, 2021 at 02:55:13PM +0800, Jason Wang wrote: > > On 2021/2/24 2:47 下午, Michael S. Tsirkin wrote: > > On Wed, Feb 24, 2021 at 08:45:20AM +0200, Eli Cohen wrote: > > > On Wed, Feb 24, 2021 at 12:17:58AM -0500, Michael S. Tsirkin wrote: > > > > On Wed,

Re: [PATCH] vdpa/mlx5: set_features should allow reset to zero

2021-02-23 Thread Eli Cohen
> > > > > > > “live”. > > > > > > > > > > > > > > > > > > > > > so accessing config space before FEATURES_OK is a spec > > > > > > > violation, right? > > > >

Re: [PATCH v2] vdpa/mlx5: Enable user to add/delete vdpa device

2021-02-23 Thread Eli Cohen
On Tue, Feb 23, 2021 at 07:56:16AM -0500, Michael S. Tsirkin wrote: > On Tue, Feb 23, 2021 at 02:54:42PM +0200, Eli Cohen wrote: > > On Tue, Feb 23, 2021 at 07:52:34AM -0500, Michael S. Tsirkin wrote: > > > > > > I think I have them in the linux next branch, no? >

Re: [PATCH v2] vdpa/mlx5: Enable user to add/delete vdpa device

2021-02-23 Thread Eli Cohen
On Tue, Feb 23, 2021 at 07:52:34AM -0500, Michael S. Tsirkin wrote: > > I think I have them in the linux next branch, no? > You do.

Re: [PATCH] vdpa/mlx5: Extract correct pointer from driver data

2021-02-23 Thread Eli Cohen
On Tue, Feb 23, 2021 at 07:32:49AM -0500, Michael S. Tsirkin wrote: > On Tue, Feb 16, 2021 at 07:50:21AM +0200, Eli Cohen wrote: > > struct mlx5_vdpa_net pointer was stored in drvdata. Extract it as well > > in mlx5v_remove(). > > > > Fixes: 74c9729dd892 ("

Re: [PATCH v2] vdpa/mlx5: Enable user to add/delete vdpa device

2021-02-23 Thread Eli Cohen
On Tue, Feb 23, 2021 at 07:29:32AM -0500, Michael S. Tsirkin wrote: > On Thu, Feb 18, 2021 at 09:41:57AM +0200, Eli Cohen wrote: > > Allow to control vdpa device creation and destruction using the vdpa > > management tool. > > > > Examples: > > 1. List the mana

Re: [PATCH] vdpa/mlx5: set_features should allow reset to zero

2021-02-21 Thread Eli Cohen
On Sun, Feb 21, 2021 at 04:52:05PM -0500, Michael S. Tsirkin wrote: > On Sun, Feb 21, 2021 at 04:44:37PM +0200, Eli Cohen wrote: > > On Fri, Feb 19, 2021 at 06:54:58AM -0500, Si-Wei Liu wrote: > > > Commit 452639a64ad8 ("vdpa: make sure set_features is invoked > > >

Re: [PATCH] vdpa/mlx5: set_features should allow reset to zero

2021-02-21 Thread Eli Cohen
On Fri, Feb 19, 2021 at 06:54:58AM -0500, Si-Wei Liu wrote: > Commit 452639a64ad8 ("vdpa: make sure set_features is invoked > for legacy") made an exception for legacy guests to reset > features to 0, when config space is accessed before features > are set. We should relieve the verify_min_features

[PATCH v1] vdpa/mlx5: Fix suspend/resume index restoration

2021-02-18 Thread Eli Cohen
of hardware used index. Fixes: b35ccebe3ef7 ("vdpa/mlx5: Restore the hardware used index after change map") Fixes: 1a86b377aa21 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices") Signed-off-by: Eli Cohen --- v0->v1: Fix subject prefix drivers/vdpa/ml

[PATCH v2] vdpa/mlx5: Enable user to add/delete vdpa device

2021-02-18 Thread Eli Cohen
show vdpa0: type network mgmtdev pci/:3b:00.1 vendor_id max_vqs 16 \ max_vq_size 256 Signed-off-by: Eli Cohen Reviewed-by: Parav Pandit --- v0->v1: set mgtdev->ndev NULL on dev delete v1->v2: Resend drivers/vdpa/mlx5/net/mlx5_vnet.c | 79 +++ 1 fil

Re: [PATCH 1/2] vdpa/mlx5: Fix suspend/resume index restoration

2021-02-18 Thread Eli Cohen
On Wed, Feb 17, 2021 at 04:20:14PM -0500, Michael S. Tsirkin wrote: > On Wed, Feb 17, 2021 at 11:42:48AM -0800, Si-Wei Liu wrote: > > > > > > On 2/16/2021 8:20 AM, Eli Cohen wrote: > > > When we suspend the VM, the VDPA interface will be reset. When

Re: [PATCH 2/2 v1] vdpa/mlx5: Enable user to add/delete vdpa device

2021-02-18 Thread Eli Cohen
On Wed, Feb 17, 2021 at 12:13:37PM -0500, Michael S. Tsirkin wrote: > On Wed, Feb 17, 2021 at 01:31:36PM +0200, Eli Cohen wrote: > > Allow to control vdpa device creation and destruction using the vdpa > > management tool. > > > > Examples: > > 1. List the mana

[PATCH 2/2 v1] vdpa/mlx5: Enable user to add/delete vdpa device

2021-02-17 Thread Eli Cohen
show vdpa0: type network mgmtdev pci/:3b:00.1 vendor_id max_vqs 16 \ max_vq_size 256 Signed-off-by: Eli Cohen Reviewed-by: Parav Pandit --- v0->v1: set mgtdev->ndev NULL on dev delete drivers/vdpa/mlx5/net/mlx5_vnet.c | 79 +++ 1 file chang

Re: [PATCH v1] vdpa/mlx5: Restore the hardware used index after change map

2021-02-16 Thread Eli Cohen
On Tue, Feb 16, 2021 at 04:25:20PM -0800, Si-Wei Liu wrote: > > > > The saved mvq->avail_idx will be used to recreate hardware virtq object > > > and > > > the used index in create_virtqueue(), once status DRIVER_OK is set. I > > > suspect we should pass the index to mvq->used_idx in > > > mlx5_v

[PATCH 2/2] vdpa/mlx5: Enable user to add/delete vdpa device

2021-02-16 Thread Eli Cohen
show vdpa0: type network mgmtdev pci/:3b:00.1 vendor_id max_vqs 16 \ max_vq_size 256 Signed-off-by: Eli Cohen Reviewed-by: Parav Pandit --- drivers/vdpa/mlx5/net/mlx5_vnet.c | 76 +++ 1 file changed, 67 insertions(+), 9 deletions(-) diff --git a/drivers

[PATCH 1/2] vdpa/mlx5: Fix suspend/resume index restoration

2021-02-16 Thread Eli Cohen
of hardware used index. Fixes: 1a86b377aa21 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices") Signed-off-by: Eli Cohen --- drivers/vdpa/mlx5/net/mlx5_vnet.c | 17 - 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/drivers/vdpa/mlx5/net/mlx5_vnet.c

Re: [PATCH v2 3/3] vdpa/mlx5: defer clear_virtqueues to until DRIVER_OK

2021-02-16 Thread Eli Cohen
On Thu, Feb 11, 2021 at 09:33:14AM +0200, Eli Cohen wrote: > On Wed, Feb 10, 2021 at 01:48:00PM -0800, Si-Wei Liu wrote: > > While virtq is stopped, get_vq_state() is supposed to > > be called to get sync'ed with the latest internal > > avail_index from device. The

Re: [PATCH] vdpa/mlx5: Extract correct pointer from driver data

2021-02-16 Thread Eli Cohen
On Tue, Feb 16, 2021 at 09:37:34AM +0200, Leon Romanovsky wrote: > On Tue, Feb 16, 2021 at 08:42:26AM +0200, Eli Cohen wrote: > > On Tue, Feb 16, 2021 at 08:35:51AM +0200, Leon Romanovsky wrote: > > > On Tue, Feb 16, 2021 at 07:50:22AM +0200, Eli Cohen wrote: > > > >

Re: [PATCH] vdpa/mlx5: Extract correct pointer from driver data

2021-02-15 Thread Eli Cohen
On Tue, Feb 16, 2021 at 08:35:51AM +0200, Leon Romanovsky wrote: > On Tue, Feb 16, 2021 at 07:50:22AM +0200, Eli Cohen wrote: > > struct mlx5_vdpa_net pointer was stored in drvdata. Extract it as well > > in mlx5v_remove(). > > > > Fixes: 74c9729dd892 ("vdpa/mlx5

[PATCH] vdpa/mlx5: Extract correct pointer from driver data

2021-02-15 Thread Eli Cohen
struct mlx5_vdpa_net pointer was stored in drvdata. Extract it as well in mlx5v_remove(). Fixes: 74c9729dd892 ("vdpa/mlx5: Connect mlx5_vdpa to auxiliary bus") Signed-off-by: Eli Cohen --- drivers/vdpa/mlx5/net/mlx5_vnet.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) di

[PATCH] vdpa/mlx5: Extract correct pointer from driver data

2021-02-15 Thread Eli Cohen
struct mlx5_vdpa_net pointer was stored in drvdata. Extract it as well in mlx5v_remove(). Fixes: 74c9729dd892 ("vdpa/mlx5: Connect mlx5_vdpa to auxiliary bus") Signed-off-by: Eli Cohen --- drivers/vdpa/mlx5/net/mlx5_vnet.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) di

Re: [PATCH v2 3/3] vdpa/mlx5: defer clear_virtqueues to until DRIVER_OK

2021-02-10 Thread Eli Cohen
> map") > Signed-off-by: Si-Wei Liu > Acked-by: Jason Wang Acked-by: Eli Cohen > --- > drivers/vdpa/mlx5/net/mlx5_vnet.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/vdpa/mlx5/net/mlx5_vnet.c > b/drivers/vdpa/mlx5/ne

Re: [PATCH v2 2/3] vdpa/mlx5: fix feature negotiation across device reset

2021-02-10 Thread Eli Cohen
ssume tx checksum offload > is available after reset and feature negotiation, > causing frames with bogus (incomplete) checksum > transmitted on the wire. > > Fixes: 1a86b377aa21 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices") > Signed-off-by

Re: [PATCH v1] vdpa/mlx5: Restore the hardware used index after change map

2021-02-10 Thread Eli Cohen
On Wed, Feb 10, 2021 at 12:59:03AM -0800, Si-Wei Liu wrote: > > > On 2/9/2021 7:53 PM, Jason Wang wrote: > > > > On 2021/2/10 上午10:30, Si-Wei Liu wrote: > > > > > > > > > On 2/8/2021 10:37 PM, Jason Wang wrote: > > > > > >

Re: [PATCH v1] vdpa/mlx5: Restore the hardware used index after change map

2021-02-08 Thread Eli Cohen
On Tue, Feb 09, 2021 at 11:20:14AM +0800, Jason Wang wrote: > > On 2021/2/8 下午6:04, Eli Cohen wrote: > > On Mon, Feb 08, 2021 at 05:04:27PM +0800, Jason Wang wrote: > > > On 2021/2/8 下午2:37, Eli Cohen wrote: > > > > On Mon, Feb 08, 2021 at 12:27:18PM +0800, Jason

Re: [PATCH] vdpa/mlx5: fix param validation in mlx5_vdpa_get_config()

2021-02-08 Thread Eli Cohen
t; this condition. > > Fixes: 1a86b377aa21 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices") > Cc: sta...@vger.kernel.org > Signed-off-by: Stefano Garzarella Acked-by: Eli Cohen BTW, same error in vdpa_sim you may want to fix. > --- > drivers/vdpa/mlx5/net

Re: [PATCH v1] vdpa/mlx5: Restore the hardware used index after change map

2021-02-08 Thread Eli Cohen
On Mon, Feb 08, 2021 at 05:04:27PM +0800, Jason Wang wrote: > > On 2021/2/8 下午2:37, Eli Cohen wrote: > > On Mon, Feb 08, 2021 at 12:27:18PM +0800, Jason Wang wrote: > > > On 2021/2/6 上午7:07, Si-Wei Liu wrote: > > > > > > > > On 2/3/2021 11:36 PM

Re: [PATCH v1] vdpa/mlx5: Restore the hardware used index after change map

2021-02-07 Thread Eli Cohen
On Mon, Feb 08, 2021 at 12:27:18PM +0800, Jason Wang wrote: > > On 2021/2/6 上午7:07, Si-Wei Liu wrote: > > > > > > On 2/3/2021 11:36 PM, Eli Cohen wrote: > > > When a change of memory map occurs, the hardware resources are destroyed > > > and then re

Re: [PATCH 3/3] mlx5_vdpa: defer clear_virtqueues to until DRIVER_OK

2021-02-07 Thread Eli Cohen
On Sat, Feb 06, 2021 at 04:29:24AM -0800, Si-Wei Liu wrote: > While virtq is stopped, get_vq_state() is supposed to > be called to get sync'ed with the latest internal > avail_index from device. The saved avail_index is used > to restate the virtq once device is started. Commit > b35ccebe3

Re: [PATCH 1/3] mlx5_vdpa: should exclude header length and fcs from mtu

2021-02-07 Thread Eli Cohen
s not just contain the > Ethernet payload, but includes extra lengths starting > from the Ethernet header up to the FCS altogether. > > Fix the MTU so packets won't get dropped silently. > > Signed-off-by: Si-Wei Liu Acked-by: Eli Cohen > --- > drivers/vdpa/mlx5/

Re: [PATCH 2/3] mlx5_vdpa: fix feature negotiation across device reset

2021-02-07 Thread Eli Cohen
On Sat, Feb 06, 2021 at 04:29:23AM -0800, Si-Wei Liu wrote: > The mlx_features denotes the capability for which > set of virtio features is supported by device. In > principle, this field needs not be cleared during > virtio device reset, as this capability is static > and does not change across re

[PATCH v1] vdpa/mlx5: Restore the hardware used index after change map

2021-02-03 Thread Eli Cohen
to reset the available and used indices upon device reset, fix this here to avoid regression caused by the fact that used index may not be zero upon device reset. Fixes: 1a86b377aa21 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices") Signed-off-by: Eli Cohen --- v0 -> v1: Clear

Re: [PATCH] vdpa/mlx5: Restore the hardware used index after change map

2021-02-03 Thread Eli Cohen
On Wed, Feb 03, 2021 at 12:33:26PM -0800, Si-Wei Liu wrote: > On Tue, Feb 2, 2021 at 10:48 PM Eli Cohen wrote: > > > > On Tue, Feb 02, 2021 at 09:14:02AM -0800, Si-Wei Liu wrote: > > > On Tue, Feb 2, 2021 at 6:34 AM Eli Cohen wrote: > > > > > > &

Re: [PATCH] vdpa/mlx5: Restore the hardware used index after change map

2021-02-03 Thread Eli Cohen
On Wed, Feb 03, 2021 at 12:33:26PM -0800, Si-Wei Liu wrote: > On Tue, Feb 2, 2021 at 10:48 PM Eli Cohen wrote: > > > > On Tue, Feb 02, 2021 at 09:14:02AM -0800, Si-Wei Liu wrote: > > > On Tue, Feb 2, 2021 at 6:34 AM Eli Cohen wrote: > > > > > > &

Re: [PATCH 1/2] vdpa/mlx5: Avoid unnecessary query virtqueue

2021-02-03 Thread Eli Cohen
On Wed, Feb 03, 2021 at 03:19:40PM -0800, Si-Wei Liu wrote: > On Tue, Feb 2, 2021 at 9:16 PM Jason Wang wrote: > > > > > > On 2021/2/3 上午1:54, Si-Wei Liu wrote: > > > On Tue, Feb 2, 2021 at 1:23 AM Eli Cohen wrote: > > >> On Tue, Feb 02, 2021 at 12:38:51

Re: [PATCH] vdpa/mlx5: Restore the hardware used index after change map

2021-02-02 Thread Eli Cohen
On Tue, Feb 02, 2021 at 09:14:02AM -0800, Si-Wei Liu wrote: > On Tue, Feb 2, 2021 at 6:34 AM Eli Cohen wrote: > > > > When a change of memory map occurs, the hardware resources are destroyed > > and then re-created again with the new memory map. In such case, we need > &

[PATCH] vdpa/mlx5: Restore the hardware used index after change map

2021-02-02 Thread Eli Cohen
/mlx5: Add VDPA driver for supported mlx5 devices") Signed-off-by: Eli Cohen --- This patch is being sent again a single patch the fixes hot memory addtion to a qemy process. drivers/vdpa/mlx5/net/mlx5_vnet.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/drivers/vdpa/mlx5/net/mlx5

Re: [PATCH 1/2] vdpa/mlx5: Avoid unnecessary query virtqueue

2021-02-02 Thread Eli Cohen
On Tue, Feb 02, 2021 at 12:38:51AM -0800, Si-Wei Liu wrote: > Thanks Eli and Jason for clarifications. See inline. > > On Mon, Feb 1, 2021 at 11:06 PM Eli Cohen wrote: > > > > On Tue, Feb 02, 2021 at 02:02:25PM +0800, Jason Wang wrote: > > > > > >

Re: [PATCH 1/2] vdpa/mlx5: Avoid unnecessary query virtqueue

2021-02-01 Thread Eli Cohen
Liu > > > > wrote: > > > > > On Thu, Jan 28, 2021 at 5:46 AM Eli Cohen wrote: > > > > > > suspend_vq should only suspend the VQ on not save the current > > > > > > available > > > > > > index. This is done when a ch

Re: [PATCH 1/2] vdpa/mlx5: Avoid unnecessary query virtqueue

2021-02-01 Thread Eli Cohen
On Mon, Feb 01, 2021 at 08:15:29PM -0800, Si-Wei Liu wrote: > On Mon, Feb 1, 2021 at 7:13 PM Jason Wang wrote: > > > > > > On 2021/2/2 上午3:17, Si-Wei Liu wrote: > > > On Mon, Feb 1, 2021 at 10:51 AM Si-Wei Liu > > > wrote: > > >&g

Re: [PATCH 1/2] vdpa/mlx5: Avoid unnecessary query virtqueue

2021-02-01 Thread Eli Cohen
On Tue, Feb 02, 2021 at 11:12:51AM +0800, Jason Wang wrote: > > On 2021/2/2 上午3:17, Si-Wei Liu wrote: > > On Mon, Feb 1, 2021 at 10:51 AM Si-Wei Liu wrote: > > > On Thu, Jan 28, 2021 at 5:46 AM Eli Cohen wrote: > > > > suspend_vq should only suspend the VQ

Re: [PATCH v2] char: xillybus: Add driver for XillyUSB (Xillybus variant for USB)

2021-02-01 Thread Eli Billauer
USB driver so that the developers there can review it. Sorry, I wasn't aware of that. Will resend this patch with this list cc'ed shortly. Thanks, Eli

[RESEND PATCH v2] char: xillybus: Add driver for XillyUSB (Xillybus variant for USB)

2021-02-01 Thread eli . billauer
From: Eli Billauer The XillyUSB driver is the USB variant for the Xillybus FPGA IP core. Even though it presents a nearly identical API on the FPGA and host, it's almost a complete rewrite of the driver: The framework for exchanging data on a USB bus is fundamentally different from doin

[PATCH v2] char: xillybus: Add driver for XillyUSB (Xillybus variant for USB)

2021-02-01 Thread eli . billauer
From: Eli Billauer The XillyUSB driver is the USB variant for the Xillybus FPGA IP core. Even though it presents a nearly identical API on the FPGA and host, it's almost a complete rewrite of the driver: The framework for exchanging data on a USB bus is fundamentally different from doin

Re: [PATCH 2/2] vdpa/mlx5: Restore the hardware used index after change map

2021-01-31 Thread Eli Cohen
On Mon, Feb 01, 2021 at 02:00:35PM +0800, Jason Wang wrote: > > On 2021/2/1 下午1:52, Eli Cohen wrote: > > On Mon, Feb 01, 2021 at 11:36:23AM +0800, Jason Wang wrote: > > > On 2021/2/1 上午2:55, Eli Cohen wrote: > > > > On Fri, Jan 29, 2021 at 11:49:45AM +0800, Jaso

Re: [PATCH 2/2] vdpa/mlx5: Restore the hardware used index after change map

2021-01-31 Thread Eli Cohen
On Mon, Feb 01, 2021 at 11:36:23AM +0800, Jason Wang wrote: > > On 2021/2/1 上午2:55, Eli Cohen wrote: > > On Fri, Jan 29, 2021 at 11:49:45AM +0800, Jason Wang wrote: > > > On 2021/1/28 下午9:41, Eli Cohen wrote: > > > > When a change of memory map occurs, the

Re: [PATCH 2/2] vdpa/mlx5: Restore the hardware used index after change map

2021-01-31 Thread Eli Cohen
On Fri, Jan 29, 2021 at 11:49:45AM +0800, Jason Wang wrote: > > On 2021/1/28 下午9:41, Eli Cohen wrote: > > When a change of memory map occurs, the hardware resources are destroyed > > and then re-created again with the new memory map. In such case, we need > > to restore th

[PATCH 2/2] vdpa/mlx5: Restore the hardware used index after change map

2021-01-28 Thread Eli Cohen
/mlx5: Add VDPA driver for supported mlx5 devices") Signed-off-by: Eli Cohen --- drivers/vdpa/mlx5/net/mlx5_vnet.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/drivers/vdpa/mlx5/net/mlx5_vnet.c b/drivers/vdpa/mlx5/net/mlx5_vnet.c index 549ded074ff3..3fc8588cecae 100644 --- a/dr

[PATCH 1/2] vdpa/mlx5: Avoid unnecessary query virtqueue

2021-01-28 Thread Eli Cohen
suspend_vq should only suspend the VQ on not save the current available index. This is done when a change of map occurs when the driver calls save_channel_info(). Signed-off-by: Eli Cohen --- drivers/vdpa/mlx5/net/mlx5_vnet.c | 8 1 file changed, 8 deletions(-) diff --git a/drivers

[PATCH 0/2] Fix failure to hot add memory

2021-01-28 Thread Eli Cohen
code. The second on is the actual fix. Eli Cohen (2): vdpa/mlx5: Avoid unnecessary query virtqueue vdpa/mlx5: Restore the hardware used index after change map drivers/vdpa/mlx5/net/mlx5_vnet.c | 15 +++ 1 file changed, 7 insertions(+), 8 deletions(-) -- 2.29.2

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: > > >

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?

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 equa

Re: Change eats memory on my server

2021-01-18 Thread Eli Cohen
On Mon, Jan 18, 2021 at 10:30:56AM +0100, Thomas Zimmermann wrote: > Hi > > Am 18.01.21 um 10:13 schrieb Eli Cohen: > > On Mon, Jan 18, 2021 at 08:54:07AM +0100, Thomas Zimmermann wrote: > > > Hi > > > > > > Am 18.01.21 um 08:43 schrieb Christian König:

Re: Change eats memory on my server

2021-01-18 Thread Eli Cohen
On Mon, Jan 18, 2021 at 02:20:49PM +0100, Thomas Zimmermann wrote: > Hi > > Am 18.01.21 um 14:16 schrieb Eli Cohen: > > On Mon, Jan 18, 2021 at 10:30:56AM +0100, Thomas Zimmermann wrote: > > > > > > Here's the patch against the latest DRM tree

Re: Change eats memory on my server

2021-01-18 Thread Eli Cohen
as I am concerned, this issue is fixed by the patch you sent. Thanks for looking into it. Eli

Re: Change eats memory on my server

2021-01-18 Thread Eli Cohen
On Mon, Jan 18, 2021 at 08:54:07AM +0100, Thomas Zimmermann wrote: > Hi > > Am 18.01.21 um 08:43 schrieb Christian König: > > Hi Eli, > > > > have you already tried using kmemleak? > > > > This sounds like a leak of memory allocated using kmalloc(), so

Re: Change eats memory on my server

2021-01-18 Thread Eli Cohen
On Mon, Jan 18, 2021 at 08:57:26AM +0100, Christian König wrote: > Am 18.01.21 um 08:49 schrieb Eli Cohen: > > On Mon, Jan 18, 2021 at 08:43:12AM +0100, Christian König wrote: > > > Hi Eli, > > > > > > have you already tried using kmemleak? > > > >

Re: Change eats memory on my server

2021-01-17 Thread Eli Cohen
On Mon, Jan 18, 2021 at 08:43:12AM +0100, Christian König wrote: > Hi Eli, > > have you already tried using kmemleak? > > This sounds like a leak of memory allocated using kmalloc(), so kmemleak > should be able to catch it. > Hi Christian, I have the following configu

Re: Change eats memory on my server

2021-01-16 Thread Eli Cohen
On Fri, Jan 15, 2021 at 10:03:50AM +0100, Thomas Zimmermann wrote: > > Could you please double-check that 3fb91f56aea4 ("drm/udl: Retrieve USB > device from struct drm_device.dev") works correctly Checked again, it does not seem to leak. > and that 823efa922102 > ("drm/cma-helper: Remove empty d

Change eats memory on my server

2021-01-14 Thread Eli Cohen
Hi Thomas, After long bisecting I found that this patch, commit 1086db71a1dbbfb32ffb42cf0d540b69956f951e Author: Thomas Zimmermann Date: Tue Nov 3 10:30:06 2020 +0100 drm/vram-helper: Remove invariant parameters from internal kmap function is the offending patch causing the kernel to eat

Re: [PATCH V2] mlx5: vdpa: fix possible uninitialized var

2021-01-13 Thread Eli Cohen
On Thu, Jan 14, 2021 at 03:09:04PM +0800, Jason Wang wrote: > When compiling with -Werror=maybe-uninitialized, gcc may complains the Maybe you want to fix to: gcc may complain about possible... Other than that: Acked-by: Eli Cohen > possible uninitialized umem. Since the callers won&

Re: [PATCH 21/21] vdpasim: control virtqueue support

2021-01-11 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:18PM +0800, Jason Wang wrote: > This patch introduces the control virtqueue support for vDPA > simulator. This is a requirement for supporting advanced features like > multiqueue. > > A requirement for control virtqueue is to isolate its memory access > from the rx/tx

Re: [PATCH] mlx5: vdpa: fix possible uninitialized var

2021-01-09 Thread Eli Cohen
On Fri, Jan 08, 2021 at 04:24:43PM +0800, Jason Wang wrote: > Upstream: posted > > When compiling with -Werror=maybe-uninitialized, gcc may complains the > possible uninitialized umem. Fix that. > > Signed-off-by: Jason Wang > --- > drivers/vdpa/mlx5/net/mlx5_vnet.c | 3 +++ > 1 file changed, 3

Re: [PATCH] char: xillybus: Add driver for XillyUSB (Xillybus variant for USB)

2021-01-08 Thread Eli Billauer
new XillyUSB device files xillyusb_* instead of xillybus_* may appear awkward. But I'm quite sure that no single user will ever thank me or anyone else for merging them. Maybe the formality is still important enough to do this anyhow...? Thanks and regards, Eli

Re: [PATCH] char: xillybus: Add driver for XillyUSB (Xillybus variant for USB)

2021-01-07 Thread Eli Billauer
concern about this patch? Thanks and regards, Eli On 06/01/21 16:23, Greg KH wrote: On Wed, Jan 06, 2021 at 04:03:08PM +0200, Eli Billauer wrote: > Hello Greg, > > Merging XillyUSB's driver into xillybus_core.c was of course the initial > idea. Practically, it turned

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

2021-01-06 Thread Eli Cohen
f fill_sg() which effect is overwritten by populate_mtts(). Fixes: 94abbccdf291 ("vdpa/mlx5: Add shared memory registration code") Signed-off-by: Eli Cohen --- V0->V1: 1. Fix typos 2. Improve changelog drivers/vdpa/mlx5/core/mlx5_vdpa.h | 1 + drivers/vdpa/mlx5

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

2021-01-06 Thread Eli Cohen
On Thu, Jan 07, 2021 at 12:15:53PM +0800, Jason Wang wrote: > > On 2021/1/6 下午5:05, 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 le

Re: [PATCH] char: xillybus: Add driver for XillyUSB (Xillybus variant for USB)

2021-01-06 Thread Eli Billauer
I don't expect that to reduce the total amount of code lines, nor make it friendlier to read. But this will reuse the existing device class name instead of creating a new one. Does this sound like a good idea? Thanks and regards, Eli On 05/01/21 15:47, Greg KH wrote: On Su

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

2021-01-06 Thread Eli Cohen
effect is overwritten bu populate_mtts(). Fixes: 94abbccdf291 ("vdpa/mlx5: Add shared memory registration code") Signed-off-by: Eli Cohen --- drivers/vdpa/mlx5/core/mlx5_vdpa.h | 1 + drivers/vdpa/mlx5/core/mr.c| 28 2 files changed, 13 inserti

Re: [PATCH 12/21] vhost-vdpa: introduce uAPI to get the number of virtqueue groups

2020-12-30 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:09PM +0800, Jason Wang wrote: > Follows the vDPA support for multiple address spaces, this patch > introduce uAPI for the userspace to know the number of virtqueue > groups supported by the vDPA device. > > Signed-off-by: Jason Wang > --- > drivers/vhost/vdpa.c

Re: [PATCH 07/21] vdpa: multiple address spaces support

2020-12-30 Thread Eli Cohen
On Wed, Dec 30, 2020 at 12:04:30PM +0800, Jason Wang wrote: > > On 2020/12/29 下午3:28, Eli Cohen wrote: > > > @@ -43,6 +43,8 @@ struct vdpa_vq_state { > > >* @index: device index > > >* @features_valid: were features initialized? for legacy guests > >

Re: [PATCH 12/21] vhost-vdpa: introduce uAPI to get the number of virtqueue groups

2020-12-29 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:09PM +0800, Jason Wang wrote: > Follows the vDPA support for multiple address spaces, this patch > introduce uAPI for the userspace to know the number of virtqueue > groups supported by the vDPA device. Can you explain what exactly you mean be userspace? Is it just qe

Re: [PATCH 11/21] vhost-vdpa: introduce asid based IOTLB

2020-12-29 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:08PM +0800, Jason Wang wrote: > This patch converts the vhost-vDPA device to support multiple IOTLBs > tagged via ASID via hlist. This will be used for supporting multiple > address spaces in the following patches. > > Signed-off-by: Jason Wang > --- > drivers/vhost

Re: [PATCH 11/21] vhost-vdpa: introduce asid based IOTLB

2020-12-29 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:08PM +0800, Jason Wang wrote: > This patch converts the vhost-vDPA device to support multiple IOTLBs > tagged via ASID via hlist. This will be used for supporting multiple > address spaces in the following patches. > > Signed-off-by: Jason Wang > --- > drivers/vhost

Re: [PATCH 11/21] vhost-vdpa: introduce asid based IOTLB

2020-12-29 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:08PM +0800, Jason Wang wrote: > This patch converts the vhost-vDPA device to support multiple IOTLBs > tagged via ASID via hlist. This will be used for supporting multiple > address spaces in the following patches. > > Signed-off-by: Jason Wang > --- > drivers/vhost

Re: [PATCH 10/21] vhost: support ASID in IOTLB API

2020-12-29 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:07PM +0800, Jason Wang wrote: > This patches allows userspace to send ASID based IOTLB message to > vhost. This idea is to use the reserved u32 field in the existing V2 > IOTLB message. Vhost device should advertise this capability via > VHOST_BACKEND_F_IOTLB_ASID back

Re: [PATCH 07/21] vdpa: multiple address spaces support

2020-12-28 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:48:04PM +0800, Jason Wang wrote: > This patches introduces the multiple address spaces support for vDPA > device. This idea is to identify a specific address space via an > dedicated identifier - ASID. > > During vDPA device allocation, vDPA device driver needs to report

Re: [PATCH 00/21] Control VQ support in vDPA

2020-12-16 Thread Eli Cohen
On Wed, Dec 16, 2020 at 02:47:57PM +0800, Jason Wang wrote: Hi Jason, I saw the patchset and will start reviewing it starting Dec 27. I am out of office next week. > Hi All: > > This series tries to add the support for control virtqueue in vDPA. > > Control virtqueue is used by networking devic

Re: [PATCH] char: xillybus: Add driver for XillyUSB (Xillybus variant for USB)

2020-12-13 Thread Eli Billauer
Hello Randy, The new driver doesn't depend on XILLYBUS, so the patch puts it correctly outside the "if XILLYBUS" clause. It indeed looks like a mistake, but it isn't. :) Thanks for paying attention to this. Regards, Eli On 13/12/20 19:22, Randy Dunlap wrote:

[PATCH] char: xillybus: Add driver for XillyUSB (Xillybus variant for USB)

2020-12-13 Thread eli . billauer
From: Eli Billauer The XillyUSB driver is the USB variant for the Xillybus FPGA IP core. Even though it presents a nearly identical API on the FPGA and host, it's almost a complete rewrite of the driver: The framework for exchanging data on a USB bus is fundamentally different from doin

[PATCH v1] vdpa/mlx5: Use write memory barrier after updating CQ index

2020-12-09 Thread Eli Cohen
: 1a86b377aa21 ("vdpa/mlx5: Add VDPA driver for supported mlx5 devices") Signed-off-by: Eli Cohen --- V0 -> V1 Use dma_wmb() instead of wmb() drivers/vdpa/mlx5/net/mlx5_vnet.c | 5 + 1 file changed, 5 insertions(+) diff --git a/drivers/vdpa/mlx5/net/mlx5_vnet.c b/drivers/vdpa/mlx5/ne

Re: [PATCH] vdpa/mlx5: Use write memory barrier after updating CQ index

2020-12-09 Thread Eli Cohen
On Wed, Dec 09, 2020 at 03:05:42AM -0500, Michael S. Tsirkin wrote: > On Wed, Dec 09, 2020 at 08:58:46AM +0200, Eli Cohen wrote: > > On Wed, Dec 09, 2020 at 01:46:22AM -0500, Michael S. Tsirkin wrote: > > > On Wed, Dec 09, 2020 at 08:02:30AM +0200, Eli Cohen wrote: > > >

Re: [PATCH] vdpa/mlx5: Use write memory barrier after updating CQ index

2020-12-08 Thread Eli Cohen
On Wed, Dec 09, 2020 at 01:46:22AM -0500, Michael S. Tsirkin wrote: > On Wed, Dec 09, 2020 at 08:02:30AM +0200, Eli Cohen wrote: > > On Tue, Dec 08, 2020 at 04:45:04PM -0500, Michael S. Tsirkin wrote: > > > On Sun, Dec 06, 2020 at 12:57:19PM +0200, Eli Cohen wrote: > > &g

Re: [PATCH] vdpa/mlx5: Use write memory barrier after updating CQ index

2020-12-08 Thread Eli Cohen
On Tue, Dec 08, 2020 at 04:45:04PM -0500, Michael S. Tsirkin wrote: > On Sun, Dec 06, 2020 at 12:57:19PM +0200, Eli Cohen wrote: > > Make sure to put write memory barrier after updating CQ consumer index > > so the hardware knows that there are available CQE slots in the queue. >

Re: [PATCH] vdpa/mlx5: Use write memory barrier after updating CQ index

2020-12-08 Thread Eli Cohen
On Mon, Dec 07, 2020 at 10:51:44AM +0800, Jason Wang wrote: > > On 2020/12/6 下午6:57, Eli Cohen wrote: > > Make sure to put write memory barrier after updating CQ consumer index > > so the hardware knows that there are available CQE slots in the queue. > > > > Fa

  1   2   3   4   >