[RFC] Per-request private data in virtio-block

2024-07-10 Thread Dmitry Fleytman
Hello QEMU-DEVEL! It's been a while… I work on a solution for "smart" IO caching on the host side. The configuration is virtio-block device backed by SPDK with OCF/OpenCAS on top of remote storage. To improve decision making for caching, I would like to have an additional per-request contextual i

Re: [PATCH v2] hw/net/net_tx_pkt: fix assertion failure in net_tx_pkt_add_raw_fragment()

2020-08-02 Thread Dmitry Fleytman
e host. This patch replaces the > affected assert() with a conditional statement, returning false if the current > data fragment exceeds max_raw_frags. > Reviewed-by: Dmitry Fleytman > Reported-by: Alexander Bulekov > Reported-by: Ziming Zhang > Signed-off-by: Mauro Matteo Casce

Re: [PATCH 0/2] assertion failure in net_tx_pkt_add_raw_fragment() in hw/net/net_tx_pkt.c

2020-07-29 Thread Dmitry Fleytman
Reviewed-by: Dmitry Fleytman The idea looks good to me. I believe it makes sense to do the check in net_tx_pkt_add_raw_fragment() as suggested by Jason. > On 27 Jul 2020, at 20:29, Alexander Bulekov wrote: > > I sent a reproducer for the to the list some time ago, but never cr

Re: [PATCH v2] Fixed integer overflow in e1000e

2020-03-05 Thread Dmitry Fleytman
te with 1 NetClientState(index 0) without peers, set > max_queue_num to 0 - It prevents undefined behavior and possible crashes, > especially during pcie hotplug. > > Signed-off-by: Andrew Melnychenko Reviewed-by: Dmitry Fleytman > --- > hw/net/e1000e.c | 2 +- > 1 file cha

Re: [PATCH 1/3] hw/net/e1000: Add readops/writeops typedefs

2020-03-05 Thread Dmitry Fleytman
> On 5 Mar 2020, at 3:04, Philippe Mathieu-Daudé wrote: > > Express the macreg[] arrays using typedefs. > No logical changes introduced here. > > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Dmitry Fleytman > --- > hw/net/e1000.c | 6 -- &g

Re: [PATCH 2/3] hw/net/e1000: Move macreg[] arrays to .rodata to save 1MiB of .data

2020-03-05 Thread Dmitry Fleytman
-Daudé Reviewed-by: Dmitry Fleytman > --- > hw/net/e1000.c | 4 ++-- > hw/net/e1000e_core.c | 4 ++-- > 2 files changed, 4 insertions(+), 4 deletions(-) > > diff --git a/hw/net/e1000.c b/hw/net/e1000.c > index 972d9b5083..9233248c9a 100644 > --- a/hw/net/e1000.

Re: [PATCH v2] Fixed integer overflow in e1000e

2020-03-05 Thread Dmitry Fleytman
1 NetClientState(index 0) without peers, set > max_queue_num to 0 - It prevents undefined behavior and possible crashes, > especially during pcie hotplug. > > Signed-off-by: Andrew Melnychenko Reviewed-by: Dmitry Fleytman > --- > hw/net/e1000e.c | 2 +- > 1 file changed,

Re: [PATCH 2/2] NetRxPkt: fix hash calculation of IPV6 TCP

2020-01-29 Thread Dmitry Fleytman
sted. > Use this type in e1000e hash calculation for IPv6 TCP, which > should take in account overrides of the addresses. > > Signed-off-by: Yuri Benditovich Acked-by: Dmitry Fleytman > --- > hw/net/e1000e_core.c | 2 +- > hw/net/net_rx_pkt.c | 2 +- > 2 files changed, 2 insert

Re: [PATCH 1/2] NetRxPkt: Introduce support for additional hash types

2020-01-29 Thread Dmitry Fleytman
> On 27 Jan 2020, at 13:54, Yuri Benditovich > wrote: > > Add support for following hash types: > IPV6 TCP with extension headers > IPV4 UDP > IPV6 UDP > IPV6 UDP with extension headers > > Signed-off-by: Yuri Benditovich Acked-by: Dmitry Fleytman &g

Re: [PATCH] e1000e: Avoid hw_error if legacy mode used

2020-01-29 Thread Dmitry Fleytman
of RCTL register define legacy format of > transfer descriptors. Current commit discards check > for BSIZE0 and BSIZE1 when legacy mode used. > > Signed-off-by: Yuri Benditovich Acked-by: Dmitry Fleytman > --- > hw/net/e1000e_core.c | 13 - > 1 file changed, 8

Re: [Qemu-devel] [PATCH] hw/net/vmxnet3: Fix leftover unregister_savevm

2019-08-27 Thread Dmitry Fleytman
> On 22 Aug 2019, at 14:12, Dr. David Alan Gilbert (git) > wrote: > > From: "Dr. David Alan Gilbert" > > Commit 78dd48df3 reworked vmxnet3's live migration but left a straggling > unregister_savevm call. Remove it, although it doesn't seem to have

Re: [Qemu-devel] [PATCH 0/6] net/eth: Remove duplicated tcp/udp_hdr structures

2019-08-12 Thread Dmitry Fleytman
Reviewed-by: Dmitry Fleytman > On 8 Aug 2019, at 17:34, Philippe Mathieu-Daudé wrote: > > This is a preparatory cleanup series. > > Commit 75020a70215 introduced 4 very equivalent structures: > - tcp_header and tcp_hdr, > - udp_header and udp_hdr. > > Choose

Re: [Qemu-devel] [PATCH] hw/net: fix vmxnet3 live migration

2019-07-08 Thread Dmitry Fleytman
> On 8 Jul 2019, at 19:03, Dr. David Alan Gilbert wrote: > > * Marcel Apfelbaum (marcel.apfelb...@gmail.com) wrote: >> >> >>> On 7/5/19 2:14 PM, Sukrit Bhatnagar wrote: >>>> On Fri, 5 Jul 2019 at 16:29, Dmitry Fleytman >>>> wrote

Re: [Qemu-devel] [PATCH] hw/net: fix vmxnet3 live migration

2019-07-05 Thread Dmitry Fleytman
, > then the above macro is enough. > > Use the opportunity to move to the standard VMSTATE_MSIX > instead of the deprecated SaveVMHandlers. > > Signed-off-by: Marcel Apfelbaum Reviewed-by: Dmitry Fleytman > --- > hw/net/vmxnet3.c | 52 ++---

Re: [Qemu-devel] [RFC 0/1] Add live migration support to the PVRDMA device

2019-06-25 Thread Dmitry Fleytman
> On 25 Jun 2019, at 11:49, Marcel Apfelbaum wrote: > > Hi Dmitry, > > On 6/25/19 11:39 AM, Dmitry Fleytman wrote: >> >>> On 25 Jun 2019, at 11:14, Marcel Apfelbaum >>> wrote: >>> >>> Hi Sukrit >>> >>> On 6/21/19

Re: [Qemu-devel] [RFC 0/1] Add live migration support to the PVRDMA device

2019-06-25 Thread Dmitry Fleytman
> On 25 Jun 2019, at 11:14, Marcel Apfelbaum wrote: > > Hi Sukrit > > On 6/21/19 5:45 PM, Sukrit Bhatnagar wrote: >> Hi, > [...] >> This RFC is meant to request suggestions on the things which are >> working and for help on the things which are not. >> > [...] >> What is not working: >> > [

Re: [Qemu-devel] Headers without multiple inclusion guards

2019-06-02 Thread Dmitry Fleytman
> > hw/net/e1000e_core.h > hw/net/e1000x_common.h > hw/net/vmxnet3_defs.h Unintentional.

Re: [Qemu-devel] [PATCH v2 01/10] hw/scsi/vmw_pvscsi: Use qbus_reset_all() directly

2019-06-02 Thread Dmitry Fleytman
Reviewed-by: Dmitry Fleytman > On 28 May 2019, at 19:40, Philippe Mathieu-Daudé wrote: > > Since the BusState is accesible from the SCSIBus object, > it is pointless to use qbus_reset_all_fn. > Use qbus_reset_all() directly. > > Signed-off-by: Philippe Mathieu-Daudé

Re: [Qemu-devel] [PATCH] e1000: Delay flush queue when receive RCTL

2019-03-20 Thread Dmitry Fleytman
Nice catch! Reviewed-by: Dmitry Fleytman mailto:dmitry.fleyt...@gmail.com>> > On 21 Mar 2019, at 3:35, yuchenlin wrote: > > Ping? > > On 2019-03-13 14:56, yuchen...@synology.com wrote: >> From: yuchenlin >> Due to too early RCT0 interrput, win10x32 may han

Re: [Qemu-devel] [PATCH 2/2] usb: implement XHCI underrun/overrun events

2019-01-30 Thread Dmitry Fleytman
ter assigned > to the slot (as these events do not have TRB), so current > commit adds the field of assigned interrupter to the > XHCISlot structure. Guest software assigns interrupter to the > slot on 'Address Device' and 'Evaluate Context' commands. > > Sig

Re: [Qemu-devel] [PATCH 1/2] usb: XHCI shall not halt isochronous endpoints

2019-01-30 Thread Dmitry Fleytman
ed-off-by: Yuri Benditovich Reviewed-by: Dmitry Fleytman > --- > hw/usb/hcd-xhci.c | 5 + > 1 file changed, 5 insertions(+) > > diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c > index 8f1a01a..1a8fd96 100644 > --- a/hw/usb/hcd-xhci.c > +++ b/hw/usb/hcd-xhci.c

Re: [Qemu-devel] [PATCH v2 12/22] vmxnet3: Move some definitions to header file

2018-11-12 Thread Dmitry Fleytman
tor vmxnet3 device state. > 3. To configure node_guid accoring to vmxnet3 device's MAC address. > > To be able to access vmxnet3 device the definition of VMXNET3State is > moved to a new header file. > > Signed-off-by: Yuval Shaia Reviewed-by: Dmitry Fleytm

Re: [Qemu-devel] [Bug 1785670] [NEW] Guest(ubuntu 18.04) crashes when trying uploading file

2018-08-09 Thread Dmitry Fleytman
Hi Dave, I’m not sure e1000e was ever tested with Slirp. It might be a bug existing from the beginning. Dmitry > On 6 Aug 2018, at 22:14, Dr. David Alan Gilbert wrote: > > Hi Sam, Jan, Dmitry, > Any idea where this is coming from; my backtrace shows it's a free in > slirp, but only happenin

Re: [Qemu-devel] [PULL 00/25] pc, pci, virtio: features, fixes, cleanups

2018-01-16 Thread Dmitry Fleytman
> On 16 Jan 2018, at 8:28, Jason Wang wrote: > > > > On 2018年01月16日 10:48, Michael S. Tsirkin wrote: >> On Tue, Jan 09, 2018 at 12:10:10PM +1100, David Gibson wrote: >>> On Mon, Jan 08, 2018 at 08:10:23PM +0200, Michael S. Tsirkin wrote: On Mon, Jan 08, 2018 at 09:14:41AM +, Peter Ma

Re: [Qemu-devel] [PATCH] MAINTAINERS: update Dmitry Fleytman email

2018-01-08 Thread Dmitry Fleytman
; F: tests/megasas-test.c > > Network packet abstractions > -M: Dmitry Fleytman > +M: Dmitry Fleytman > S: Maintained > F: include/net/eth.h > F: net/eth.c > @@ -1165,7 +1165,7 @@ F: hw/net/net_rx_pkt* > F: hw/net/net_tx_pkt* > > Vmware > -M: Dmitry Fleytman &

Re: [Qemu-devel] [PATCH for-2.11] hw/net/vmxnet3: Fix code to work on big endian hosts, too

2017-11-13 Thread Dmitry Fleytman
Reviewed-by: Dmitry Fleytman > On 13 Nov 2017, at 18:57 PM, Thomas Huth wrote: > > Since commit ab06ec43577177a442e8 we test the vmxnet3 device in the > pxe-tester, too (when running "make check SPEED=slow"). This now > revealed that the vmxnet3 code is not working r

Re: [Qemu-devel] [PATCH] default-configs: Enable CONFIG_VMXNET3_PCI only on x86

2017-09-28 Thread Dmitry Fleytman
or -95 > [vmxnet3][WR][vmxnet3_pci_realize]: Failed to initialize MSI-X, configuration > is inconsistent. > > Since vmxnet3 is a para-virtualized device that is only useful on x86, > it should also only be enabled on the x86 targets. > Reviewed-by: Dmitry Fleytman > Signed-of

Re: [Qemu-devel] [PATCH] e1000: Rename the SEC symbol to SEQEC

2017-09-04 Thread Dmitry Fleytman
Reviewed-by: Dmitry Fleytman > On 4 Sep 2017, at 10:23 AM, Fam Zheng wrote: > > On Sun, 09/03 18:37, Kamil Rytarowski wrote: >> SunOS defines SEC in as 1 (commonly used time symbols). >> >> This fixes build on SmartOS (Joyent). >> >> Patch cherr

[Qemu-devel] xhci issues with Logitech, Inc. Headset H340 audio device

2017-08-08 Thread Dmitry Fleytman
Hi Gerd, qemu-devel We are trying to use USB host device assignment to propagate Logitech H340 headset to QEMU guest with virtual XHCI controller running Windows 10. For some reason headphone function of the device does not work - guest OS claims that the device does not complete requests. We ha

Re: [Qemu-devel] [PATCH] vfio/pci-quirks: Set non-zero GMS memory size for IGD

2017-08-02 Thread Dmitry Fleytman
> On 2 Aug 2017, at 24:24 AM, Alex Williamson > wrote: > > On Fri, 28 Jul 2017 08:22:45 +0300 > Dmitry Fleytman mailto:dmi...@daynix.com>> wrote: > >>> On 28 Jul 2017, at 07:51 AM, Zhang, Xiong Y wrote: >>> >>>>>

Re: [Qemu-devel] [RFC PATCH 15/47] MAINTAINERS: add missing VMWare entry

2017-07-28 Thread Dmitry Fleytman
couple of such entries already > in the MAINTAINERS file. > >> MAINTAINERS | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/MAINTAINERS b/MAINTAINERS >> index d8aef164ca..9670a3901a 100644 >> --- a/MAINTAINERS >> +++ b/MAINTAINERS >>

Re: [Qemu-devel] [PATCH] vfio/pci-quirks: Set non-zero GMS memory size for IGD

2017-07-27 Thread Dmitry Fleytman
> On 28 Jul 2017, at 07:51 AM, Zhang, Xiong Y wrote: > >>> On 26 Jul 2017, at 08:22 AM, Zhang, Xiong Y >> wrote: >>> >>> Sorry, we indeed found Intel windows guest graphic driver couldn't be bind >> when GMS memory size is zero. And we have fixed it and the next intel >> windows driver release

Re: [Qemu-devel] [PATCH for 2.10 10/35] net/eth: fix incorrect check of iov_to_buf() return value

2017-07-26 Thread Dmitry Fleytman
f(opthdr), > src_addr, sizeof(*src_addr)); > > -return bytes_read == sizeof(src_addr); > +return bytes_read == sizeof(*src_addr); > } > Reviewed-by: Dmitry Fleytman > opt_offset += optlen; > -- > 2.13.3 >

Re: [Qemu-devel] [PATCH 1/2] hw/scsi/vmw_pvscsi: Remove the dead error handling

2017-07-26 Thread Dmitry Fleytman
> On 26 Jul 2017, at 11:41 AM, Mao Zhongyi wrote: > > qemu_bh_new() is a wrapper around aio_bh_new(), which returns > null only when g_new() does. It doesn't. So remove the dead > error handling. > Acked-by: Dmitry Fleytman mailto:dmi...@daynix.com>> >

Re: [Qemu-devel] [PATCH 2/2] hw/scsi/vmw_pvscsi: Convert to realize

2017-07-26 Thread Dmitry Fleytman
> On 26 Jul 2017, at 11:41 AM, Mao Zhongyi wrote: > > Convert a device model where initialization obviously > can't fail, make it implement realize() rather than init(). Acked-by: Dmitry Fleytman mailto:dmi...@daynix.com>> > > Cc: Dmitry Fleytman > Cc: Paolo

Re: [Qemu-devel] [PATCH] vfio/pci-quirks: Set non-zero GMS memory size for IGD

2017-07-26 Thread Dmitry Fleytman
gt; -Original Message- >> From: Alex Williamson [mailto:alex.william...@redhat.com] >> Sent: Tuesday, July 25, 2017 11:32 PM >> To: Dmitry Fleytman >> Cc: qemu-devel@nongnu.org; Zhang, Xiong Y >> Subject: Re: [PATCH] vfio/pci-quirks: Set non-zero GMS memo

[Qemu-devel] [PATCH] vfio/pci-quirks: Set non-zero GMS memory size for IGD

2017-07-24 Thread Dmitry Fleytman
-by: Dmitry Fleytman --- hw/vfio/pci-quirks.c | 13 + hw/vfio/pci.c| 2 +- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/hw/vfio/pci-quirks.c b/hw/vfio/pci-quirks.c index 349085e..197cb90 100644 --- a/hw/vfio/pci-quirks.c +++ b/hw/vfio/pci-quirks.c @@ -1527,10

Re: [Qemu-devel] [PATCH] pci: honor PCI_COMMAND_MEMORY

2017-07-18 Thread Dmitry Fleytman
On 17 Jul 2017, at 19:59 PM, Michael S. Tsirkin wrote: > > On Mon, Jul 17, 2017 at 03:48:03PM +0300, Dmitry Fleytman wrote: >> Am I understand correctly that there are no special cases for >> IDE controllers, i.e. bus master bit must be set by SW same >> way as for oth

Re: [Qemu-devel] [PATCH] pci: honor PCI_COMMAND_MEMORY

2017-07-17 Thread Dmitry Fleytman
On 16 Jul 2017, at 19:56 PM, Marcel Apfelbaum wrote: > > On 16/07/2017 11:29, Dmitry Fleytman wrote: >> According to PCI spec. bit 1 of command >> register (PCI_COMMAND_MEMORY) controls >> a device's response to memory space accesses. >> A value of 0 disables t

[Qemu-devel] [PATCH] pci: honor PCI_COMMAND_MEMORY

2017-07-16 Thread Dmitry Fleytman
0aa00, Incorrect checksum Arg4: 0418, Previous disk read's checksum According to our tests this problem happens at least on Windows 8/8.1/2012/2012R2/10/2016. This patch solves https://bugzilla.redhat.com/show_bug.cgi?id=988351 Signed-off-by: Dmitry Fleytman ---

Re: [Qemu-devel] [PATCH] migration: remove register_savevm()

2017-05-24 Thread Dmitry Fleytman
to free it then. > > Signed-off-by: Laurent Vivier > --- > hw/net/vmxnet3.c | 8 ++— Acked-by: Dmitry Fleytman mailto:dmi...@daynix.com>> > hw/s390x/s390-skeys.c | 9 +++-- > hw/s390x/s390-virtio-ccw.c | 8 ++-- > include/migration/vms

Re: [Qemu-devel] [PATCH] e1000e: Fix a bug where guest hangs upon migration

2017-05-17 Thread Dmitry Fleytman
, IMS: 0xa4) > 27563@1494850819.412441:e1000e_irq_pending_interrupts ICR PENDING: 0x0 (ICR: > 0x815000c2, IMS: 0xa4) > 27563@1494850819.412998:e1000e_irq_pending_interrupts ICR PENDING: 0x100 > (ICR: 0x815000c2, IMS: 0x1a4) > > This commit solves: > https://bugzi

Re: [Qemu-devel] e1000e migration

2017-05-15 Thread Dmitry Fleytman
Hello Dave, It looks like we identified the problem. We are working on fix and will send it as soon as it is ready. ~Dmitry. Sent from my iPhone > On 15 May 2017, at 12:22, Dr. David Alan Gilbert wrote: > > * Dmitry Fleytman (dmi...@daynix.com) wrote: >> Hello Dave,

Re: [Qemu-devel] e1000e migration

2017-05-14 Thread Dmitry Fleytman
Hello Dave, We are trying to reproduce this issue on our systems but with no luck so far… From what you describe it looks like some bit in ICR is not being cleared by the driver. This usually means that this bit should never be set in that specific interrupt mode. Could you please check which

Re: [Qemu-devel] [PATCH] vmw_pvscsi: check message ring page count at initialisation

2017-04-25 Thread Dmitry Fleytman
loop. Add check to avoid it. Hello P J P, Except the commit message that does not exactly correspond to what this patch does, Reviewed-by: Dmitry Fleytman Thanks for the patch, Dmitry. > > Reported-by: YY Z > Signed-off-by: P J P > --- > hw/scsi/vmw_pvscsi.c | 2 +- > 1 file

Re: [Qemu-devel] [PATCH v2 21/30] trace: Fix parameter types in hw/net

2017-03-14 Thread Dmitry Fleytman
Reviewed-by: Dmitry Fleytman > On 13 Mar 2017, at 21:55 PM, Eric Blake wrote: > > An upcoming patch will let the compiler warn us when we are silently > losing precision in traces; update the trace definitions to pass > through the full value at the callsite. In one case, t

Re: [Qemu-devel] [PATCH 1/5] eth: Extend vlan stripping functions

2017-03-04 Thread Dmitry Fleytman
> On 3 Mar 2017, at 18:52 PM, Philippe Mathieu-Daudé wrote: > > On 02/16/2017 09:29 AM, Dmitry Fleytman wrote: >> Make VLAN stripping functions return number of bytes >> copied to given Ethernet header buffer. >> >> This information should be used to re

Re: [Qemu-devel] [PATCH 4/5] NetRxPkt: Account buffer with ETH header in IOV length

2017-03-04 Thread Dmitry Fleytman
> On 3 Mar 2017, at 18:39 PM, Philippe Mathieu-Daudé wrote: > > Hi Dmitry, > > On 02/16/2017 09:29 AM, Dmitry Fleytman wrote: >> In case of VLAN stripping ETH header is stored in a >> separate chunk and length of IOV should take this into >> account. >>

Re: [Qemu-devel] [PATCH 0/5] A few VLAN-related bugfixes for RX packet abstraction

2017-02-16 Thread Dmitry Fleytman
> On 17 Feb 2017, at 5:05, Jason Wang wrote: > > > >> On 2017年02月16日 20:39, Peter Maydell wrote: >>> On 16 February 2017 at 12:29, Dmitry Fleytman wrote: >>> This series fix a few issues related >>> to processing of RX packets with VLAN head

[Qemu-devel] [PATCH 5/5] NetRxPkt: Remove code duplication in net_rx_pkt_pull_data()

2017-02-16 Thread Dmitry Fleytman
This is a refactoring commit that does not change behavior. Signed-off-by: Dmitry Fleytman --- hw/net/net_rx_pkt.c | 9 + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/hw/net/net_rx_pkt.c b/hw/net/net_rx_pkt.c index c7ae33d..3899211 100644 --- a/hw/net/net_rx_pkt.c +++ b

[Qemu-devel] [PATCH 2/5] NetRxPkt: Fix memory corruption on VLAN header stripping

2017-02-16 Thread Dmitry Fleytman
der) + sizeof(struct vlan_header) bytes into it. Devices affected by this problem: vmxnet3. Reported-by: Peter Maydell Signed-off-by: Dmitry Fleytman --- hw/net/net_rx_pkt.c | 34 +- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/hw/net/net_rx_pkt.c b

[Qemu-devel] [PATCH 4/5] NetRxPkt: Account buffer with ETH header in IOV length

2017-02-16 Thread Dmitry Fleytman
In case of VLAN stripping ETH header is stored in a separate chunk and length of IOV should take this into account. This patch fixes checksum validation for RX packets with VLAN header. Devices affected by this problem: e1000e and vmxnet3. Signed-off-by: Dmitry Fleytman --- hw/net

[Qemu-devel] [PATCH 3/5] NetRxPkt: Do not try to pull more data than present

2017-02-16 Thread Dmitry Fleytman
In case of VLAN stripping, ETH header put into a separate buffer, therefore amont of data copied from original IOV should be smaller. Signed-off-by: Dmitry Fleytman --- hw/net/net_rx_pkt.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/net/net_rx_pkt.c b/hw/net

[Qemu-devel] [PATCH 0/5] A few VLAN-related bugfixes for RX packet abstraction

2017-02-16 Thread Dmitry Fleytman
This series fix a few issues related to processing of RX packets with VLAN headers. See commit messages of specific patches for information regarding affected devices. Dmitry Fleytman (5): eth: Extend vlan stripping functions NetRxPkt: Fix memory corruption on VLAN header stripping

[Qemu-devel] [PATCH 1/5] eth: Extend vlan stripping functions

2017-02-16 Thread Dmitry Fleytman
Make VLAN stripping functions return number of bytes copied to given Ethernet header buffer. This information should be used to re-compose packet IOV after VLAN stripping. Signed-off-by: Dmitry Fleytman --- include/net/eth.h | 4 ++-- net/eth.c | 25 ++--- 2 files

Re: [Qemu-devel] [PATCH] net: Remove useless local var pkt

2017-02-15 Thread Dmitry Fleytman
Reviewed-by: Dmitry Fleytman This patch also fixes compilation with NET_RX_PKT_DEBUG defined. > On 15 Feb 2017, at 10:31 AM, Fam Zheng wrote: > > This has been pointless since commit 605d52e62, which was a > search-and-replace, overlooked the redundancy. > > Signed

Re: [Qemu-devel] [PATCH v3] net: e1000e: fix an infinite loop issue

2017-02-12 Thread Dmitry Fleytman
Reviewed-by: Dmitry Fleytman > On 10 Feb 2017, at 04:19 AM, Li Qiang wrote: > > This issue is like the issue in e1000 network card addressed in > this commit: > e1000: eliminate infinite loops on out-of-bounds transfer start. > > Signed-off-by: Li Qiang > --- >

Re: [Qemu-devel] [PATCH v2] net: e1000e: fix an infinite loop issue

2017-02-09 Thread Dmitry Fleytman
> On 9 Feb 2017, at 04:11 AM, Li Qiang wrote: > > From: Li Qiang > > This issue is like the issue in e1000 network card addressed in > this commit: > e1000: eliminate infinite loops on out-of-bounds transfer start. Hi, Please see my comments below. > > Signed-off-by: Li Qiang > --- > > C

Re: [Qemu-devel] [PATCH] net: e1000e: fix an infinite loop issue

2017-02-08 Thread Dmitry Fleytman
> On 8 Feb 2017, at 12:17 PM, Li Qiang wrote: > > Hello Dmitry, > > > 2017-02-08 18:01 GMT+08:00 Dmitry Fleytman : > >> On 8 Feb 2017, at 11:30 AM, Li Qiang wrote: >> >> Hello, >> >> 2017-02-08 16:38 GMT+08:00 Dmitry Fleytman : >>

Re: [Qemu-devel] [PATCH] net: e1000e: fix an infinite loop issue

2017-02-08 Thread Dmitry Fleytman
> On 8 Feb 2017, at 11:30 AM, Li Qiang wrote: > > Hello, > > 2017-02-08 16:38 GMT+08:00 Dmitry Fleytman <mailto:dmi...@daynix.com>>: > Hello, > > Thanks for the patch! > > The problem of infinite loop indeed exists in e1000e, however it is different

Re: [Qemu-devel] [PATCH] net: e1000e: fix an infinite loop issue

2017-02-08 Thread Dmitry Fleytman
Hello, Thanks for the patch! The problem of infinite loop indeed exists in e1000e, however it is different from the one fixed in e1000. Please find my comments inline. ~Dmitry > On 7 Feb 2017, at 11:43 AM, Li Qiang wrote: > > From: Li Qiang > > This issue is the same as e1000 network card

Re: [Qemu-devel] [PATCH] net: e1000e: fix dead code in e1000e_write_packet_to_guest

2017-01-26 Thread Dmitry Fleytman
Good catch! Reviewed-by: Dmitry Fleytman > On 26 Jan 2017, at 12:10 PM, Paolo Bonzini wrote: > > Because is_first is declared inside a loop, it is always true. The store > is dead, and so is the "else" branch of "if (is_first)". is_last is > oka

Re: [Qemu-devel] [PATCH] net: optimize checksum computation

2017-01-08 Thread Dmitry Fleytman
ned multibyte reads, LE/BE considerations, > architecture-specific optimizations, etc. This patch still keeps > things simple and readable. Reviewed-by: Dmitry Fleytman > > Signed-off-by: Ladi Prosek > --- > net/checksum.c | 21 + > 1 file changed, 13

Re: [Qemu-devel] [PATCH 2/2] vmxnet3: VMStatify rx/tx q_descr and int_state

2017-01-04 Thread Dmitry Fleytman
> On 3 Jan 2017, at 21:40 PM, Dr. David Alan Gilbert > wrote: > > * Dmitry Fleytman (dmi...@daynix.com <mailto:dmi...@daynix.com>) wrote: >>> >>> On 16 Dec 2016, at 14:19 PM, Dr. David Alan Gilbert >>> wrote: >>> >>> * Dr.

Re: [Qemu-devel] [PATCH v4 1/2] pcie_aer: Convert pcie_aer_init to Error

2016-12-22 Thread Dmitry Fleytman
Acked-by: Dmitry Fleytman > On 21 Dec 2016, at 10:21 AM, Cao jin wrote: > > When user specify invalid value for property aer_log_max, device should > fail to create, and report appropriate message. > > Signed-off-by: Cao jin > Reviewed-by: Marcel Apfelbaum > A

Re: [Qemu-devel] [PATCH 1/2] vmxnet3: Convert ring values to uint32_t's

2016-12-17 Thread Dmitry Fleytman
Acked-by: Dmitry Fleytman > On 15 Dec 2016, at 22:05 PM, Dr. David Alan Gilbert (git) > wrote: > > From: "Dr. David Alan Gilbert" > > The index's in the Vmxnet3Ring were migrated as 32bit ints > yet are declared as size_t's. They appear to be deri

Re: [Qemu-devel] [PATCH 2/2] vmxnet3: VMStatify rx/tx q_descr and int_state

2016-12-17 Thread Dmitry Fleytman
>> The problem is vmxnet3-ring size/cell_size/next are declared as size_t >> but written as 32bit. > > Oops, I should have removed that warning in the commit message when > I added the 1st patch in. Acked-by: Dmitry Fleytman > >

Re: [Qemu-devel] [PATCH v3] pcie_aer: Convert pcie_aer_init to Error

2016-11-03 Thread Dmitry Fleytman
Acked-by: Dmitry Fleytman > On 3 Nov 2016, at 14:57 PM, Cao jin wrote: > > When user specify invalid property aer_log_max, device should fail to > create, and report appropriate message. > > Signed-off-by: Cao jin > --- > v3 changelog: > 1. get rid of PCIE_AER

Re: [Qemu-devel] [PATCH 3/4] e1000e: Rename "disable_vnet_hdr" property to "vnet"

2016-10-27 Thread Dmitry Fleytman
t; 1) we avoid confusing double-negatives like > "disable_vnet_hdr=false"; > 2) we avoid underscores in property names. > > This breaks command-line compatibility, but I am assuming the > property is not being used in production by anybody. Reviewed-by: Dmitry Fleytman

Re: [Qemu-devel] [PATCH 4/4] e1000e: Rename "subsys_ven" property to "subsys-vendor"

2016-10-27 Thread Dmitry Fleytman
> On 26 Oct 2016, at 22:21 PM, Eduardo Habkost wrote: > > Follow the usual QOM property naming style, and make the property > name clearer. > > This breaks command-line compatibility, but I am assuming the > property is not being used in production by anybody. I’m basically Ok with this patch

Re: [Qemu-devel] [PATCH 2/4] e1000e: No need to validate configuration on migration

2016-10-26 Thread Dmitry Fleytman
> On 26 Oct 2016, at 22:21 PM, Eduardo Habkost wrote: > > The user (or management software) is responsible for keeping the > same configuration on both sides while migrating. Remove the > configuration validation code at e1000e_post_load, and the > unnecessary subsys_used/subsys_ven_used fields.

Re: [Qemu-devel] [PATCH 1/4] e1000e: Use regular DEFINE_PROP_ macros for properties

2016-10-26 Thread Dmitry Fleytman
> On 27 Oct 2016, at 06:12 AM, Jason Wang wrote: > > > > On 2016年10月27日 03:21, Eduardo Habkost wrote: >> Instead of hacking custom PropertyInfo structs, use the regular >> DEFINE_PROP_ macros for the e1000e properties. >> >> This also fixes a bug in the disable_vnet_hdr property >> definition

Re: [Qemu-devel] [PATCH] e1000e: Don't zero out buffer address in rx descriptor

2016-10-19 Thread Dmitry Fleytman
> On 19 Oct 2016, at 13:07 PM, Kevin Wolf wrote: > > Am 19.10.2016 um 09:57 hat Dmitry Fleytman geschrieben: >> >>On 19 Oct 2016, at 10:25 AM, Kevin Wolf wrote: >> >>Am 19.10.2016 um 08:48 hat Dmitry Fleytman geschrieben: >> >>

Re: [Qemu-devel] [PATCH] e1000e: Don't zero out buffer address in rx descriptor

2016-10-19 Thread Dmitry Fleytman
> On 19 Oct 2016, at 10:25 AM, Kevin Wolf wrote: > > Am 19.10.2016 um 08:48 hat Dmitry Fleytman geschrieben: >>Another related thing that I noticed while debugging this and turning on >>tracing is that the interrupt throttling timers kept firing even if >>

Re: [Qemu-devel] [PATCH v4 08/10] vmxnet3: fix reference leak issue

2016-10-19 Thread Dmitry Fleytman
Reviewed-by: Dmitry Fleytman > On 19 Oct 2016, at 09:47 AM, Cao jin wrote: > > On migration target, msix_vector_use() will be called in vmxnet3_post_load() > in second time, without a matching second call to msi_vector_unuse(), > which results in vector reference leak.

Re: [Qemu-devel] [PATCH] e1000e: Don't zero out buffer address in rx descriptor

2016-10-19 Thread Dmitry Fleytman
> On 18 Oct 2016, at 17:27 PM, Kevin Wolf wrote: > > Am 18.10.2016 um 16:10 hat Dmitry Fleytman geschrieben: >>On 17 Oct 2016, at 01:35 AM, Kevin Wolf wrote: >> >>The e1000e emulation zeroes out any used rx descriptor and then writes a >>complet

Re: [Qemu-devel] [PATCH v4 09/10] vmxnet3: remove unnecessary internal msix flag

2016-10-18 Thread Dmitry Fleytman
Reviewed-by: Dmitry Fleytman > On 19 Oct 2016, at 09:47 AM, Cao jin wrote: > > Internal flag msix_used is unnecessary, it has the same effect as > msix_enabled(). > > The corresponding msi flag is already dropped in commit 1070048e. > > CC: Dmitry Fleytman > C

Re: [Qemu-devel] [PATCH] e1000e: Don't zero out buffer address in rx descriptor

2016-10-18 Thread Dmitry Fleytman
ptors unchanged even after the descriptor has been used. Hi Kevin, Reviewed-by: Dmitry Fleytman Thanks for catching this! ~Dmitry > > Signed-off-by: Kevin Wolf > --- > hw/net/e1000e_core.c | 8 > 1 file changed, 4 insertions(+), 4 deletions(-) > > diff --git a

Re: [Qemu-devel] [PATCH v3 8/8] vmxnet3: remove unnecessary internal msix state flag

2016-10-10 Thread Dmitry Fleytman
> On 11 Oct 2016, at 6:35, Cao jin wrote: > > > >> On 10/06/2016 05:39 PM, Dmitry Fleytman wrote: >> > >> >> Hello, >> >> Yes, from what I see, this call is wrong and leads to >> reference leaks on device unload at migration target

Re: [Qemu-devel] [PATCH v3 8/8] vmxnet3: remove unnecessary internal msix state flag

2016-10-06 Thread Dmitry Fleytman
> On 6 Oct 2016, at 17:43, Dr. David Alan Gilbert wrote: > > * Dmitry Fleytman (dmi...@daynix.com) wrote: >> >>> On 30 Sep 2016, at 15:08 PM, Markus Armbruster wrote: >>> >>> Cao jin writes: >>> >>>>> On 0

Re: [Qemu-devel] [PATCH v3 8/8] vmxnet3: remove unnecessary internal msix state flag

2016-10-06 Thread Dmitry Fleytman
> On 30 Sep 2016, at 15:08 PM, Markus Armbruster wrote: > > Cao jin writes: > >> On 09/29/2016 10:42 PM, Markus Armbruster wrote: >>> Cao jin writes: >>> >> static int vmxnet3_post_load(void *opaque, int version_id) { VMXNET3State *s = opaque; -PCIDevice *d =

Re: [Qemu-devel] [PATCH 4/7] e1000e: Fix PBACLR implementation

2016-09-22 Thread Dmitry Fleytman
> On 22 Sep 2016, at 09:40 AM, Jason Wang wrote: > > > > On 2016年09月15日 14:14, Dmitry Fleytman wrote: >> This patch fixes incorrect check for >> interrypt type being used. >> >> PBSCLR register is valid for MSI-X only. >> >> See spec. 10.

Re: [Qemu-devel] [PATCH 0/7] e1000e: A few fixes for RX data path

2016-09-21 Thread Dmitry Fleytman
Hi qemu-devel, Ping. ~Dmitry > On 15 Sep 2016, at 09:14 AM, Dmitry Fleytman wrote: > > This series contains a few RX logic fixes for e1000e. > > These fixes improve compliance to HW device specification > and fix occasional interruptions of RX traffic with > th

[Qemu-devel] [PATCH 5/7] e1000e: Fix OTHER interrupts processing for MSI-X

2016-09-14 Thread Dmitry Fleytman
Interrupt mask for legacy OTHER causes should not apply to MSI-X OTHER cause. Signed-off-by: Dmitry Fleytman --- hw/net/e1000e_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/net/e1000e_core.c b/hw/net/e1000e_core.c index c38ed10..e70e669 100644 --- a/hw/net

[Qemu-devel] [PATCH 7/7] e1000e: Fix EIAC register implementation

2016-09-14 Thread Dmitry Fleytman
This patch fixes 2 issues: 1. Bits set in EIAC register should be cleared from IMS when EIAM is not used. 2. Only bit that corresonds to the interrupt being raised should be cleared. See spec. 10.2.4.7 Interrupt Auto Clear Signed-off-by: Dmitry Fleytman --- hw/net/e1000e_core.c | 14

[Qemu-devel] [PATCH 6/7] e1000e: Fix spurious RX TCP ACK interrupts

2016-09-14 Thread Dmitry Fleytman
Do not raise ACK interrupts when RFCTL.ACKDIS bit is set (see spec. 10.2.5.16). Signed-off-by: Dmitry Fleytman --- hw/net/e1000e_core.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hw/net/e1000e_core.c b/hw/net/e1000e_core.c index e70e669..f4ec79f 100644 --- a/hw/net

[Qemu-devel] [PATCH 1/7] e1000e: Flush all receive queues on receive enable

2016-09-14 Thread Dmitry Fleytman
Before this patch first netdev queue only was flushed. Signed-off-by: Dmitry Fleytman --- hw/net/e1000e.c | 2 +- hw/net/e1000e_core.c | 2 +- hw/net/e1000e_core.h | 3 +++ 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/hw/net/e1000e.c b/hw/net/e1000e.c index bad43f4

[Qemu-devel] [PATCH 4/7] e1000e: Fix PBACLR implementation

2016-09-14 Thread Dmitry Fleytman
This patch fixes incorrect check for interrypt type being used. PBSCLR register is valid for MSI-X only. See spec. 10.2.3.13 MSI—X PBA Clear Signed-off-by: Dmitry Fleytman --- hw/net/e1000e_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/net/e1000e_core.c b/hw

[Qemu-devel] [PATCH 2/7] e1000e: Flush receive queues on link up

2016-09-14 Thread Dmitry Fleytman
Signed-off-by: Dmitry Fleytman --- hw/net/e1000e_core.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hw/net/e1000e_core.c b/hw/net/e1000e_core.c index ade4d25..a9603e0 100644 --- a/hw/net/e1000e_core.c +++ b/hw/net/e1000e_core.c @@ -1807,6 +1807,7 @@ e1000e_core_set_link_status

[Qemu-devel] [PATCH 0/7] e1000e: A few fixes for RX data path

2016-09-14 Thread Dmitry Fleytman
This series contains a few RX logic fixes for e1000e. These fixes improve compliance to HW device specification and fix occasional interruptions of RX traffic with the latest linux driver. Dmitry Fleytman (7): e1000e: Flush all receive queues on receive enable e1000e: Flush receive queue on

[Qemu-devel] [PATCH 3/7] e1000e: Fix CTRL_EXT.EIAME behavior

2016-09-14 Thread Dmitry Fleytman
CTRL_EXT.EIAME bit controls clearing of IAM bits, but current code clears IMS bits instead. See spec. 10.2.2.5 Extended Device Control Register. Signed-off-by: Dmitry Fleytman --- hw/net/e1000e_core.c | 4 ++-- hw/net/trace-events | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff

Re: [Qemu-devel] [PATCH v3] scsi: pvscsi: avoid infinite loop while building SG list

2016-09-13 Thread Dmitry Fleytman
> On 13 Sep 2016, at 15:53 PM, P J P wrote: > > Hello Dmitry, > > +-- On Tue, 13 Sep 2016, Dmitry Fleytman wrote --+ > | It should be in the same patch because otherwise a broken logic will be > | introduced. > > Not even same patch-set? Same patc

Re: [Qemu-devel] [PATCH] scsi: pvscsi: limit process IO loop to maximum page count

2016-09-13 Thread Dmitry Fleytman
> On 13 Sep 2016, at 13:48 PM, P J P wrote: > > Hello Dmitry, > > +-- On Tue, 13 Sep 2016, Dmitry Fleytman wrote --+ > | > On 13 Sep 2016, at 10:00 AM, P J P wrote: > | > > | > +-- On Wed, 7 Sep 2016, P J P wrote --+ > | > | From: Prasad J Pandit &

Re: [Qemu-devel] [PATCH v3] scsi: pvscsi: avoid infinite loop while building SG list

2016-09-13 Thread Dmitry Fleytman
> On 13 Sep 2016, at 14:20 PM, P J P wrote: > > Hello Dmitry, > > +-- On Tue, 13 Sep 2016, Dmitry Fleytman wrote --+ > | Better put here: > | > | if(elemcnt++ >= PVSCSI_MAX_SG_ELEM) { > | return; > | } > | > | And ditch additional conditions from

Re: [Qemu-devel] [PATCH v3] scsi: pvscsi: avoid infinite loop while building SG list

2016-09-13 Thread Dmitry Fleytman
Hello Prasad, See my comments inline. > On 13 Sep 2016, at 10:01 AM, P J P wrote: > > +-- On Tue, 6 Sep 2016, P J P wrote --+ > | From: Prasad J Pandit > | > | In PVSCSI paravirtual SCSI bus, pvscsi_convert_sglist can take a very > | long time or go into an infinite loop due to two different

Re: [Qemu-devel] [PATCH] scsi: pvscsi: limit process IO loop to maximum page count

2016-09-13 Thread Dmitry Fleytman
Hello Prasad, Please see my questions inline. > On 13 Sep 2016, at 10:00 AM, P J P wrote: > > +-- On Wed, 7 Sep 2016, P J P wrote --+ > | From: Prasad J Pandit > | > | Vmware Paravirtual SCSI emulator while processing IO requests > | could run into an infinite loop if 'pvscsi_ring_pop_req_des

Re: [Qemu-devel] [PATCH v2 2/2] e1000: fix buliding complaint

2016-09-12 Thread Dmitry Fleytman
> On 9 Sep 2016, at 10:15 AM, Gonglei (Arei) wrote: > > Who can pick up this patch? Dmitry or Jason? Thanks! Jason, would you please? > > > Regards, > -Gonglei > > >> -----Original Message- >> From: Dmitry Fleytman [mailto:dmi...@daynix.com] >

Re: [Qemu-devel] [PATCH v3] scsi: check page count while initialising descriptor rings

2016-09-01 Thread Dmitry Fleytman
Reviewed-by: Dmitry Fleytman > On 1 Sep 2016, at 14:00 PM, P J P wrote: > > From: Prasad J Pandit > > Vmware Paravirtual SCSI emulation uses command descriptors to > process SCSI commands. These descriptors come with their ring > buffers. A guest could set the page cou

Re: [Qemu-devel] [PATCH v2] scsi: check page count while initialising descriptor rings

2016-09-01 Thread Dmitry Fleytman
> On 1 Sep 2016, at 07:50 AM, P J P wrote: > > Hello Dmitry, > > +-- On Wed, 31 Aug 2016, Dmitry Fleytman wrote --+ > | > -if ((ri->reqRingNumPages > PVSCSI_SETUP_RINGS_MAX_NUM_PAGES) > | > -|| (ri->cmpRingNumPages > PVSCSI_SETUP_RINGS_MAX

Re: [Qemu-devel] [PATCH v2] scsi: check page count while initialising descriptor rings

2016-08-31 Thread Dmitry Fleytman
> On 31 Aug 2016, at 09:49 AM, P J P wrote: > > From: Prasad J Pandit > > Vmware Paravirtual SCSI emulation uses command descriptors to > process SCSI commands. These descriptors come with their ring > buffers. A guest could set the page count for these rings to > an arbitrary value, leading t

  1   2   3   4   5   >