Re: [PATCH v7 3/4] virtio_net: Add second acceptable configuration for MAC setup

2025-04-27 Thread Cindy Lu
On Mon, Apr 21, 2025 at 11:19 AM Jason Wang wrote: > > On Thu, Apr 17, 2025 at 6:25 PM Cindy Lu wrote: > > > > For VDPA devices, Allow configurations where the hardware MAC address > > is non-zero while the MAC address in the QEMU command line is zero. > > I

Re: [PATCH v7 4/4] virtio_net: Add third acceptable configuration for MAC setup.

2025-04-27 Thread Cindy Lu
On Mon, Apr 21, 2025 at 11:22 AM Jason Wang wrote: > > On Thu, Apr 17, 2025 at 6:26 PM Cindy Lu wrote: > > > > For VDPA devices, Allow configurations where both the hardware MAC address > > and QEMU command line MAC address are zero. > > In this case, QEMU will a

[PATCH v7 4/4] virtio_net: Add third acceptable configuration for MAC setup.

2025-04-17 Thread Cindy Lu
: Cindy Lu --- hw/net/virtio-net.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c index 808a2fe4d4..2d4ac20ee0 100644 --- a/hw/net/virtio-net.c +++ b/hw/net/virtio-net.c @@ -3772,7 +3772,18 @@ static bool virtio_net_check_vdpa_mac(VirtIONet

[PATCH v7 3/4] virtio_net: Add second acceptable configuration for MAC setup

2025-04-17 Thread Cindy Lu
For VDPA devices, Allow configurations where the hardware MAC address is non-zero while the MAC address in the QEMU command line is zero. In this case, QEMU will use the hardware MAC address from the device. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 14 ++ 1 file changed, 14

[PATCH v7 1/4] vhost_vdpa : Add a new parameter to enable check mac address

2025-04-17 Thread Cindy Lu
vdpa0,check-mac=true\ -device virtio-net-pci,netdev=vhost-vdpa0\ To disable this check: -netdev type=vhost-vdpa,vhostdev=/dev/vhost-vdpa-0,id=vhost-vdpa0,check-mac=false\ -device virtio-net-pci,netdev=vhost-vdpa0\ Signed-off-by: Cindy Lu --- include/net/net.h | 1 + net/vhost-vdpa.c

[PATCH v7 0/4] virtio_net: Add the check for vdpa's mac address

2025-04-17 Thread Cindy Lu
2. Address comments and rebase with the latest QEMU Cindy Lu (4): vhost_vdpa : Add a new parameter to enable check mac address virtio_net: Add the check for vdpa's mac address virtio_net: Add second acceptable configuration for MAC setup virtio_net: Add third acceptable configuration for

[PATCH v7 2/4] virtio_net: Add the check for vdpa's mac address

2025-04-17 Thread Cindy Lu
When using a VDPA device, it is important to ensure that the MAC address is correctly set. The MAC address in the hardware should match the MAC address from the QEMU command line. This is a recommended configuration and will allow the system to boot. Signed-off-by: Cindy Lu --- hw/net/virtio

Re: [PATCH v6 1/4] vhost_vdpa : Add a new parameter to enable check mac address

2025-04-09 Thread Cindy Lu
On Tue, Apr 8, 2025 at 2:38 PM Jason Wang wrote: > > On Tue, Apr 8, 2025 at 2:13 PM Cindy Lu wrote: > > > > When using a VDPA device, it's important to ensure that the MAC > > address is correctly set. > > Add a new parameter in qemu cmdline to enable thi

Re: [PATCH v6 4/4] virtio_net: Add third acceptable configuration for MAC setup.

2025-04-09 Thread Cindy Lu
On Tue, Apr 8, 2025 at 2:48 PM Jason Wang wrote: > > On Tue, Apr 8, 2025 at 2:14 PM Cindy Lu wrote: > > > > For VDPA devices, Allow configurations where both the hardware MAC address > > and QEMU command line MAC address are zero. > > > > Let's explain w

Re: [PATCH v6 2/4] virtio_net: Add the check for vdpa's mac address

2025-04-09 Thread Cindy Lu
On Tue, Apr 8, 2025 at 2:46 PM Jason Wang wrote: > > On Tue, Apr 8, 2025 at 2:13 PM Cindy Lu wrote: > > > > When using a VDPA device, it is important to ensure that the MAC > > address is correctly set. The MAC address in the hardware should > > match the MAC addr

Re: [PATCH v6 3/4] virtio_net: Add second acceptable configuration for MAC setup

2025-04-08 Thread Cindy Lu
On Tue, Apr 8, 2025 at 2:48 PM Jason Wang wrote: > > On Tue, Apr 8, 2025 at 2:13 PM Cindy Lu wrote: > > > > For VDPA devices, Allow configurations where the hardware MAC address > > is non-zero while the MAC address in the QEMU command line is zero. > &g

[PATCH v6 1/4] vhost_vdpa : Add a new parameter to enable check mac address

2025-04-08 Thread Cindy Lu
t-pci,netdev=vhost-vdpa0\ Signed-off-by: Cindy Lu --- include/net/net.h | 1 + net/vhost-vdpa.c | 4 qapi/net.json | 5 + 3 files changed, 10 insertions(+) diff --git a/include/net/net.h b/include/net/net.h index cdd5b109b0..fac1951b6e 100644 --- a/include/net/net.h +++ b/includ

[PATCH v6 3/4] virtio_net: Add second acceptable configuration for MAC setup

2025-04-08 Thread Cindy Lu
For VDPA devices, Allow configurations where the hardware MAC address is non-zero while the MAC address in the QEMU command line is zero. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c

[PATCH v6 0/4] virtio_net: Add the check for vdpa's mac address

2025-04-08 Thread Cindy Lu
parameter's name to check-mac 2. change the comment and make it more clear change in v5 1.These patches haven't been merged for a while, so I rebased them with the latest code and resubmitted change in v6 1. Address comments 2. Rebase with the latest QEMU Cindy Lu (4): vhost_vdpa :

[PATCH v6 2/4] virtio_net: Add the check for vdpa's mac address

2025-04-08 Thread Cindy Lu
When using a VDPA device, it is important to ensure that the MAC address is correctly set. The MAC address in the hardware should match the MAC address from the QEMU command line. This is a recommended configuration and will allow the system to boot. Signed-off-by: Cindy Lu --- hw/net/virtio

[PATCH v6 4/4] virtio_net: Add third acceptable configuration for MAC setup.

2025-04-07 Thread Cindy Lu
For VDPA devices, Allow configurations where both the hardware MAC address and QEMU command line MAC address are zero. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 12 1 file changed, 12 insertions(+) diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c index 45b63eb9de

Re: VDPA MAC address problem

2025-04-05 Thread Cindy Lu
On Fri, Mar 21, 2025 at 12:29 PM Konstantin Shkolnyy wrote: > > On 3/20/2025 20:22, Jason Wang wrote: > > On Fri, Mar 21, 2025 at 12:45 AM Konstantin Shkolnyy > > wrote: > >> > >> On 3/19/2025 19:58, Jason Wang wrote: > >>> On Thu, Mar 20, 2025 at 12:34 AM Konstantin Shkolnyy > >>> wrote: > >>

[PATCH v5 1/4] vhost_vdpa : Add a new parameter to enable check mac address

2025-04-05 Thread Cindy Lu
t-pci,netdev=vhost-vdpa0\ Signed-off-by: Cindy Lu --- include/net/net.h | 1 + net/vhost-vdpa.c | 4 qapi/net.json | 5 + 3 files changed, 10 insertions(+) diff --git a/include/net/net.h b/include/net/net.h index cdd5b109b0..fac1951b6e 100644 --- a/include/net/net.h +++ b/includ

Re: [PATCH v5 3/4] virtio_net: Add second acceptable configuration for MAC setup

2025-04-05 Thread Cindy Lu
On Thu, Apr 3, 2025 at 12:35 AM Michael S. Tsirkin wrote: > > On Wed, Mar 26, 2025 at 09:19:32PM +0800, Cindy Lu wrote: > > For VDPA devices, Allow configurations where the hardware MAC address > > is non-zero while the MAC address in the QEMU command line is zero. > > >

Re: [PATCH v5 2/4] virtio_net: Add the check for vdpa's mac address

2025-04-05 Thread Cindy Lu
On Thu, Apr 3, 2025 at 12:34 AM Michael S. Tsirkin wrote: > > On Wed, Mar 26, 2025 at 09:19:31PM +0800, Cindy Lu wrote: > > When using a VDPA device, it is important to ensure that the MAC > > address is correctly set. The MAC address in the hardware should > > match the M

Re: [PATCH v5 4/4] virtio_net: Add third acceptable configuration for MAC setup.

2025-04-02 Thread Cindy Lu
On Thu, Apr 3, 2025 at 12:36 AM Michael S. Tsirkin wrote: > > On Wed, Mar 26, 2025 at 09:19:33PM +0800, Cindy Lu wrote: > > For VDPA devices, Allow configurations where both the hardware MAC address > > and QEMU command line MAC address are zero. > > > > Signed-off

[PATCH v5 2/4] virtio_net: Add the check for vdpa's mac address

2025-03-26 Thread Cindy Lu
When using a VDPA device, it is important to ensure that the MAC address is correctly set. The MAC address in the hardware should match the MAC address from the QEMU command line. This is a recommended configuration and will allow the system to boot. Signed-off-by: Cindy Lu --- hw/net/virtio

[PATCH v5 4/4] virtio_net: Add third acceptable configuration for MAC setup.

2025-03-26 Thread Cindy Lu
For VDPA devices, Allow configurations where both the hardware MAC address and QEMU command line MAC address are zero. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 13 + 1 file changed, 13 insertions(+) diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c index 1fd0403d5d

[PATCH v5 0/4] virtio_net: Add the check for vdpa's mac address

2025-03-26 Thread Cindy Lu
parameter's name to check-mac 2. change the comment and make it more clear change in v5 1.These patches haven't been merged for a while, so I rebased them with the latest code and resubmitted Cindy Lu (4): vhost_vdpa : Add a new parameter to enable check mac address virtio_net: Add the

[PATCH v5 3/4] virtio_net: Add second acceptable configuration for MAC setup

2025-03-26 Thread Cindy Lu
For VDPA devices, Allow configurations where the hardware MAC address is non-zero while the MAC address in the QEMU command line is zero. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c

Re: VDPA MAC address problem

2025-03-20 Thread Cindy Lu
Hi Konstantin yes, we have found this kind of issue in this upstream So here is a fix for this problem in kernel https://lore.kernel.org/kvm/caclfguuyny6-1cyabsgs+qtdzo+mkp3o09t_gt-bmm4jgdp...@mail.gmail.com/T/ vdpa: support set mac address from vdpa tool This tool allows the user to change the M

[PATCH v4 1/4] vhost_vdpa : Add a new parameter to enable check mac address

2024-11-08 Thread Cindy Lu
t-pci,netdev=vhost-vdpa0\ Signed-off-by: Cindy Lu --- include/net/net.h | 1 + net/vhost-vdpa.c | 4 qapi/net.json | 5 + 3 files changed, 10 insertions(+) diff --git a/include/net/net.h b/include/net/net.h index cdd5b109b0..fac1951b6e 100644 --- a/include/net/net.h +++ b/includ

[PATCH v4 4/4] virtio_net: Add third acceptable configuration for MAC setup.

2024-11-08 Thread Cindy Lu
For VDPA devices, Allow configurations where both the hardware MAC address and QEMU command line MAC address are zero. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 13 + 1 file changed, 13 insertions(+) diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c index f74aa4f8db

[PATCH v4 2/4] virtio_net: Add the check for vdpa's mac address

2024-11-08 Thread Cindy Lu
When using a VDPA device, it is important to ensure that the MAC address is correctly set. The MAC address in the hardware should match the MAC address from the QEMU command line. This is a recommended configuration and will allow the system to boot. Signed-off-by: Cindy Lu --- hw/net/virtio

[PATCH v4 3/4] virtio_net: Add second acceptable configuration for MAC setup

2024-11-08 Thread Cindy Lu
For VDPA devices, Allow configurations where the hardware MAC address is non-zero while the MAC address in the QEMU command line is zero. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c

[PATCH v4 0/4] virtio_net: Add the check for vdpa's mac address

2024-11-08 Thread Cindy Lu
name to check-mac 2. change the comment and make it more clear Cindy Lu (4): vhost_vdpa : Add a new parameter to enable check mac address virtio_net: Add the check for vdpa's mac address virtio_net: Add second acceptable configuration for MAC setup virtio_net: Add third

Re: [PATCH v3 1/4] vhost_vdpa : Add a new parameter to enable check mac address

2024-11-06 Thread Cindy Lu
On Wed, Nov 6, 2024 at 5:25 PM Michael S. Tsirkin wrote: > > On Sat, Oct 26, 2024 at 03:59:59PM +0800, Cindy Lu wrote: > > When using a VDPA device, it's important to ensure that the MAC > > address is correctly set. > > Add a new parameter in qemu cmdline to ena

[PATCH v3 3/4] virtio_net: Add the 2rd acceptable situation for Mac setup.

2024-10-26 Thread Cindy Lu
When using a VDPA device, the following situations are also acceptable: the hardware MAC address is not 0, and the MAC address in the QEMU command line is 0. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/hw/net/virtio-net.c b

[PATCH v3 4/4] virtio_net: Add the 3rd acceptable situation for Mac setup.

2024-10-26 Thread Cindy Lu
While the hardware MAC address is 0 and the MAC address in the QEMU command line is also 0, this configuration is acceptable. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 13 + 1 file changed, 13 insertions(+) diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c index

[PATCH v3 2/4] virtio_net: Add the check for vdpa's mac address

2024-10-26 Thread Cindy Lu
When using a VDPA device, it is important to ensure that the MAC address is correctly set. The MAC address in the hardware should match the MAC address from the QEMU command line. This is a recommended configuration and will allow the system to boot. Signed-off-by: Cindy Lu --- hw/net/virtio

[PATCH v3 1/4] vhost_vdpa : Add a new parameter to enable check mac address

2024-10-26 Thread Cindy Lu
o-net-pci,netdev=vhost-vdpa0\ Signed-off-by: Cindy Lu --- include/net/net.h | 1 + net/vhost-vdpa.c | 4 qapi/net.json | 5 + 3 files changed, 10 insertions(+) diff --git a/include/net/net.h b/include/net/net.h index c8f679761b..e00651a97b 100644 --- a/include/net/net.h

[PATCH v3 0/4] virtio_net: Add the check for vdpa's mac address

2024-10-26 Thread Cindy Lu
,vhostdev=/dev/vhost-vdpa-0,id=vhost-vdpa0,macstrickcheck=true\ -device virtio-net-pci,netdev=vhost-vdpa0\ tested by ConnectX-6 Dx device change in v3 1. add a new parameter to enable the check and keep the old behavior 2. adjust the comment and make it more clear Cindy Lu (4): vhost_vdpa : Add a

Re: [PATCH v2 3/3] virtio_net: Add the 3rd acceptable situation for Mac setup.

2024-10-13 Thread Cindy Lu
On Wed, 9 Oct 2024 at 16:30, Jason Wang wrote: > > On Mon, Sep 30, 2024 at 12:01 AM Cindy Lu wrote: > > > > While the hardware MAC address is 0 and the MAC address in > > the QEMU command line is also 0, this configuration is > > acceptable. > > > > Si

Re: [PATCH v2 2/3] virtio_net: Add the 2rd acceptable situation for Mac setup.

2024-10-13 Thread Cindy Lu
On Wed, 9 Oct 2024 at 16:30, Jason Wang wrote: > > On Mon, Sep 30, 2024 at 12:01 AM Cindy Lu wrote: > > > > When using a VDPA device, the following situations are > > also acceptable: the hardware MAC address is not 0, > > and the MAC address in the QEMU command li

[PATCH v2 0/3] virtio_net: Add the check for vdpa's mac address

2024-09-29 Thread Cindy Lu
When using a VDPA device, it is important to ensure that the MAC address is correctly set. There are only three acceptable situations for MAC setup; any other configuration will fail to boot. tested by ConnectX-6 Dx device Cindy Lu (3): virtio_net: Add the check for vdpa's mac ad

[PATCH v2 2/3] virtio_net: Add the 2rd acceptable situation for Mac setup.

2024-09-29 Thread Cindy Lu
When using a VDPA device, the following situations are also acceptable: the hardware MAC address is not 0, and the MAC address in the QEMU command line is 0. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 12 1 file changed, 12 insertions(+) diff --git a/hw/net/virtio-net.c b

[PATCH v2 3/3] virtio_net: Add the 3rd acceptable situation for Mac setup.

2024-09-29 Thread Cindy Lu
While the hardware MAC address is 0 and the MAC address in the QEMU command line is also 0, this configuration is acceptable. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c index

[PATCH v2 1/3] virtio_net: Add the check for vdpa's mac address

2024-09-29 Thread Cindy Lu
When using a VDPA device, it is important to ensure that the MAC address is correctly set. The MAC address in the hardware should match the MAC address from the QEMU command line. This is a recommended configuration and will allow the system to boot. Signed-off-by: Cindy Lu --- hw/net/virtio

Re: [PATCH 1/3] virtio_net: Add the check for vdpa's mac address

2024-08-09 Thread Cindy Lu
On Tue, 6 Aug 2024 at 21:30, Michael S. Tsirkin wrote: > > On Tue, Aug 06, 2024 at 08:58:01AM +0800, Cindy Lu wrote: > > When using a VDPA device, it is important to ensure that > > the MAC address in the hardware matches the MAC address > > from the QEMU command line.

Re: [PATCH 1/3] virtio_net: Add the check for vdpa's mac address

2024-08-09 Thread Cindy Lu
On Wed, 7 Aug 2024 at 10:36, Jason Wang wrote: > On Tue, Aug 6, 2024 at 5:44 PM Cindy Lu wrote: > > > > On Tue, 6 Aug 2024 at 11:07, Jason Wang wrote: > > > > > > On Tue, Aug 6, 2024 at 8:58 AM Cindy Lu wrote: > > > > > > > >

Re: [PATCH 1/3] virtio_net: Add the check for vdpa's mac address

2024-08-09 Thread Cindy Lu
x27;t have this kind of verification. I will double check this Thanks Cindy > > On Tue, Aug 6, 2024 at 12:45 PM Cindy Lu wrote: > > > > On Tue, 6 Aug 2024 at 11:07, Jason Wang wrote: > > > > > > On Tue, Aug 6, 2024 at 8:58 AM Cindy Lu wrote: > > > &

Re: [PATCH 3/3] virtio_net: remove the unnecessary check in get_config

2024-08-06 Thread Cindy Lu
On Tue, 6 Aug 2024 at 11:09, Jason Wang wrote: > > On Tue, Aug 6, 2024 at 8:58 AM Cindy Lu wrote: > > > > The vdpa device with MAC address 0 should not boot. > > So remove the check here > > > > Signed-off-by: Cindy Lu > > Please describe what issue

Re: [PATCH 1/3] virtio_net: Add the check for vdpa's mac address

2024-08-06 Thread Cindy Lu
On Tue, 6 Aug 2024 at 11:07, Jason Wang wrote: > > On Tue, Aug 6, 2024 at 8:58 AM Cindy Lu wrote: > > > > When using a VDPA device, it is important to ensure that > > the MAC address in the hardware matches the MAC address > > from the QEMU command line. > >

[PATCH v6] virtio-pci: Fix the use of an uninitialized irqfd

2024-08-06 Thread Cindy Lu
fix use of a released vector") Cc: qemu-sta...@nongnu.org Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c index 592fdaa10f..dc31a37ec0 100644 --- a/hw/virtio/virtio-pci.c +++ b/hw/virtio/v

[PATCH 1/3] virtio_net: Add the check for vdpa's mac address

2024-08-05 Thread Cindy Lu
When using a VDPA device, it is important to ensure that the MAC address in the hardware matches the MAC address from the QEMU command line. This will allow the device to boot. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 33 + 1 file changed, 29 insertions

[PATCH 3/3] virtio_net: remove the unnecessary check in get_config

2024-08-05 Thread Cindy Lu
The vdpa device with MAC address 0 should not boot. So remove the check here Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 13 - 1 file changed, 13 deletions(-) diff --git a/hw/net/virtio-net.c b/hw/net/virtio-net.c index c144ae2e78..8a7c743ad3 100644 --- a/hw/net/virtio-net.c

[PATCH 2/3] virtio_net: Add the check for vdpa mac address

2024-08-05 Thread Cindy Lu
When using a VDPA device, this is another acceptable situations The hardware MAC address is not 0, and the MAC address in the QEMU command line is 0. This is also acceptable Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 13 - 1 file changed, 12 insertions(+), 1 deletion

Re: [PATCH v5] virtio-pci: Fix the use of an uninitialized irqfd

2024-07-22 Thread Cindy Lu
On Mon, 22 Jul 2024 at 15:24, Jason Wang wrote: > > Hi Cindy > > On Fri, Jul 19, 2024 at 1:25 PM Cindy Lu wrote: > > > > The crash was reported in MAC OS and NixOS, here is the link for this bug > > https://gitlab.com/qemu-project/qemu/-/issues/2334 > >

[PATCH v5] virtio-pci: Fix the use of an uninitialized irqfd

2024-07-18 Thread Cindy Lu
cff94d ("virtio-pci: fix use of a released vector") Cc: qemu-sta...@nongnu.org Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c index 592fdaa10f..dc31a37ec0 100644 --- a/hw/virtio/vir

Re: [PATCH v4 1/2] virtio-pci: Fix the use of an uninitialized irqfd

2024-07-15 Thread Cindy Lu
On Tue, 2 Jul 2024 at 15:09, Jason Wang wrote: > > On Tue, Jul 2, 2024 at 10:00 AM Cindy Lu wrote: > > > > The crash was reported in MAC OS and NixOS, here is the link for this bug > > https://gitlab.com/qemu-project/qemu/-/issues/2334 > > https://gitlab.com/q

Re: [RFC v2] virtio-net: check the mac address for vdpa device

2024-07-15 Thread Cindy Lu
On Tue, 16 Jul 2024 at 13:37, Jason Wang wrote: > > On Tue, Jul 16, 2024 at 9:14 AM Cindy Lu wrote: > > > > When using a VDPA device, it is important to ensure that the MAC address > > in the hardware matches the MAC address from the QEMU command line. > > >

Re: [RFC v2] virtio-net: check the mac address for vdpa device

2024-07-15 Thread Cindy Lu
On Tue, 16 Jul 2024 at 09:56, Lei Yang wrote: > > Hi Cindy > > If needed, QE can help test this MR before merging into the master branch. > > Best Regards > Lei > sure, Really thanks for your help thanks cindy > > On Tue, Jul 16, 2024 at 9:14 AM Cindy Lu wrote: &g

[RFC v2] virtio-net: check the mac address for vdpa device

2024-07-15 Thread Cindy Lu
addresses are not 0. 2. The hardware MAC address is not 0, and the MAC address in the QEMU command line is 0. In this situation, the hardware MAC address will overwrite the QEMU command line address. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 43 +-- 1

Re: [RFC] virtio-net: check the mac address for vdpa device

2024-07-08 Thread Cindy Lu
On Tue, 9 Jul 2024 at 10:47, Jason Wang wrote: > > On Tue, Jul 9, 2024 at 10:41 AM Cindy Lu wrote: > > > > On Tue, 9 Jul 2024 at 10:33, Jason Wang wrote: > > > > > > On Tue, Jul 9, 2024 at 10:27 AM Cindy Lu wrote: > > > > > > > > When

Re: [RFC] virtio-net: check the mac address for vdpa device

2024-07-08 Thread Cindy Lu
On Tue, 9 Jul 2024 at 10:33, Jason Wang wrote: > > On Tue, Jul 9, 2024 at 10:27 AM Cindy Lu wrote: > > > > When using VDPA device, we should verify whether the MAC address in the > > hardware matches the MAC address from the QEMU command line. If not, > > we w

[RFC] virtio-net: check the mac address for vdpa device

2024-07-08 Thread Cindy Lu
When using VDPA device, we should verify whether the MAC address in the hardware matches the MAC address from the QEMU command line. If not, we will need to update the related information. Signed-off-by: Cindy Lu --- hw/net/virtio-net.c | 15 +++ 1 file changed, 11 insertions(+), 4

[PATCH v4 2/2] virtio-pci: Add check the return of kvm_virtio_pci_vector_use_one

2024-07-01 Thread Cindy Lu
Add the return value check for kvm_virtio_pci_vector_use_one(). Since the return value of function virtio_pci_set_vector() is void, we can do nothing here. So just add the error message here. Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 4 +++- 1 file changed, 3 insertions(+), 1

[PATCH v4 0/2] virtio-pci: Fix the use of an uninitialized irqfd

2024-07-01 Thread Cindy Lu
check for kvm_virtio_pci_vector_use_one(). Since the return value of function virtio_pci_set_vector() is void, just add the error message here. Cindy Lu (2): virtio-pci: Fix the use of an uninitialized irqfd virtio-pci: Add check the return of kvm_virtio_pci_vector_use_one hw/virtio/vir

[PATCH v4 1/2] virtio-pci: Fix the use of an uninitialized irqfd

2024-07-01 Thread Cindy Lu
t ../qemu-9.0.0/util/qemu-thread-posix.c:541 13 0x7c8185bcd1cf in ??? () at /usr/lib/libc.so.6 14 0x7c8185c4e504 in clone () at /usr/lib/libc.so.6 Fixes: 2ce6cff94d ("virtio-pci: fix use of a released vector") Cc: qemu-sta...@nongnu.org Signed-off-by: Cindy Lu --- hw/virtio/vir

Re: [PATCH v3] virtio-pci: Fix the use of an uninitialized irqfd

2024-06-27 Thread Cindy Lu
On Thu, Jun 27, 2024 at 4:55 PM Michael S. Tsirkin wrote: > > On Thu, Jun 27, 2024 at 04:40:33PM +0800, Cindy Lu wrote: > > On Wed, Jun 26, 2024 at 3:45 PM Michael S. Tsirkin wrote: > > > > > > On Wed, Jun 26, 2024 at 10:44:31AM +0800, Cindy Lu wrote: > > >

Re: [PATCH v3] virtio-pci: Fix the use of an uninitialized irqfd

2024-06-27 Thread Cindy Lu
On Wed, Jun 26, 2024 at 3:45 PM Michael S. Tsirkin wrote: > > On Wed, Jun 26, 2024 at 10:44:31AM +0800, Cindy Lu wrote: > > The crash was reported in MAC OS and NixOS, here is the link for this bug > > https://gitlab.com/qemu-project/qemu/-/issues/2334 > > https://gitl

[PATCH v3] virtio-pci: Fix the use of an uninitialized irqfd

2024-06-25 Thread Cindy Lu
) at /usr/lib/libc.so.6 14 0x7c8185c4e504 in clone () at /usr/lib/libc.so.6 Fixes: 2ce6cff94d ("virtio-pci: fix use of a released vector") Cc: qemu-sta...@nongnu.org Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git

Re: [PATCH v2] virtio-pci: Fix the use of an uninitialized irqfd.

2024-06-18 Thread Cindy Lu
On Mon, Jun 17, 2024 at 6:38 PM Philippe Mathieu-Daudé wrote: > > Hi Cindy, > > On 17/6/24 11:55, Cindy Lu wrote: > > The crash was reported in MAC OS and NixOS, here is the link for this bug > > https://gitlab.com/qemu-project/qemu/-/issues/2334 > > https://gitlab.

[PATCH v2] virtio-pci: Fix the use of an uninitialized irqfd.

2024-06-17 Thread Cindy Lu
leased vector") Cc: qemu-sta...@nongnu.org Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c index b1d02f4b3d..502aad28b2 100644 --- a/hw/virtio/virtio-pci.c +++ b/hw/virti

Re: [PATCH] virtio-pci: Fix the use of an uninitialized irqfd.

2024-06-02 Thread Cindy Lu
On Wed, May 29, 2024 at 9:54 PM Fiona Ebner wrote: > > Hi, > > Am 22.05.24 um 07:10 schrieb Cindy Lu: > > The crash was reported in MAC OS and NixOS, here is the link for this bug > > https://gitlab.com/qemu-project/qemu/-/issues/2334 > > https://gitlab.com/q

[PATCH v2] virtio-pci: Fix the failure process in kvm_virtio_pci_vector_use_one()

2024-05-28 Thread Cindy Lu
: qemu-sta...@nongnu.org Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 18 ++ 1 file changed, 2 insertions(+), 16 deletions(-) diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c index b1d02f4b3d..8a9d0f6ef5 100644 --- a/hw/virtio/virtio-pci.c +++ b/hw/virtio/virtio-pci.c

[PATCH] virtio-pci: Fix the use of an uninitialized irqfd.

2024-05-21 Thread Cindy Lu
es: 2ce6cff94d ("virtio-pci: fix use of a released vector") Cc: qemu-sta...@nongnu.org Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c index b1d02f4b3d..a7faee5

Re: [PATCH v8] virtio-pci: fix use of a released vector

2024-05-08 Thread Cindy Lu
On Thu, May 9, 2024 at 4:18 AM Michael Tokarev wrote: > > 15.04.2024 12:34, Michael S. Tsirkin wrote: > > From: Cindy Lu > > > > During the booting process of the non-standard image, the behavior of the > > called function in qemu is as follows: > > > >

Re: [PATCH] virtio-pci: Fix the failure process in kvm_virtio_pci_vector_use_one()

2024-04-18 Thread Cindy Lu
On Wed, Apr 17, 2024 at 2:38 AM Michael S. Tsirkin wrote: > > On Tue, Apr 16, 2024 at 02:14:57PM +0100, Peter Maydell wrote: > > On Tue, 16 Apr 2024 at 13:41, Cindy Lu wrote: > > > > > > On Tue, Apr 16, 2024 at 8:30 PM Peter Maydell > > > wrote: >

Re: [PATCH v8] virtio-pci: fix use of a released vector

2024-04-16 Thread Cindy Lu
On Tue, Apr 16, 2024 at 11:21 AM Jason Wang wrote: > > On Mon, Apr 15, 2024 at 6:41 PM Cindy Lu wrote: > > > > On Mon, Apr 15, 2024 at 5:34 PM Michael S. Tsirkin wrote: > > > > > > From: Cindy Lu > > > > > > During the booting process of th

Re: [PULL 1/1] virtio-pci: fix use of a released vector

2024-04-16 Thread Cindy Lu
On Tue, Apr 16, 2024 at 8:22 PM Peter Maydell wrote: > > On Tue, 16 Apr 2024 at 12:50, Peter Maydell wrote: > > > > On Tue, 16 Apr 2024 at 12:05, Cindy Lu wrote: > > > > > > On Tue, Apr 16, 2024 at 6:01 PM Peter Maydell > > > wrote: > > >

Re: [PULL 1/1] virtio-pci: fix use of a released vector

2024-04-16 Thread Cindy Lu
On Tue, Apr 16, 2024 at 7:50 PM Peter Maydell wrote: > > On Tue, 16 Apr 2024 at 12:05, Cindy Lu wrote: > > > > On Tue, Apr 16, 2024 at 6:01 PM Peter Maydell > > wrote: > > > Here we pass that through to kvm_virtio_pci_vector_use_one(). > > > In kvm_vir

Re: [PATCH] virtio-pci: Fix the failure process in kvm_virtio_pci_vector_use_one()

2024-04-16 Thread Cindy Lu
On Tue, Apr 16, 2024 at 8:30 PM Peter Maydell wrote: > > On Tue, 16 Apr 2024 at 13:29, Cindy Lu wrote: > > > > In function kvm_virtio_pci_vector_use_one(), in the undo label, > > the function will get the vector incorrectly while using > > VIRTIO_CONFIG_IRQ_IDX &

[PATCH] virtio-pci: Fix the failure process in kvm_virtio_pci_vector_use_one()

2024-04-16 Thread Cindy Lu
: qemu-sta...@nongnu.org Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 19 +++ 1 file changed, 3 insertions(+), 16 deletions(-) diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c index b138fa127a..565bdb0897 100644 --- a/hw/virtio/virtio-pci.c +++ b/hw/virtio/virtio-pci.c

Re: [PULL 1/1] virtio-pci: fix use of a released vector

2024-04-16 Thread Cindy Lu
On Tue, Apr 16, 2024 at 6:01 PM Peter Maydell wrote: > > On Mon, 15 Apr 2024 at 11:52, Michael S. Tsirkin wrote: > > > > From: Cindy Lu > > > > During the booting process of the non-standard image, the behavior of the > > called function in qemu is as foll

Re: [PATCH v8] virtio-pci: fix use of a released vector

2024-04-15 Thread Cindy Lu
On Mon, Apr 15, 2024 at 5:34 PM Michael S. Tsirkin wrote: > > From: Cindy Lu > > During the booting process of the non-standard image, the behavior of the > called function in qemu is as follows: > > 1. vhost_net_stop() was triggered by guest image. This w

Re: [PATCH v8] virtio-pci: fix use of a released vector

2024-04-15 Thread Cindy Lu
On Mon, Apr 15, 2024 at 5:34 PM Michael S. Tsirkin wrote: > > From: Cindy Lu > > During the booting process of the non-standard image, the behavior of the > called function in qemu is as follows: > > 1. vhost_net_stop() was triggered by guest image. This w

Re: [PATCH v6] virtio-pci: Fix the crash that the vector was used after released.

2024-04-15 Thread Cindy Lu
On Mon, Apr 15, 2024 at 4:32 PM Michael S. Tsirkin wrote: > > On Fri, Apr 12, 2024 at 02:26:55PM +0800, Cindy Lu wrote: > > During the booting process of the non-standard image, the behavior of the > > called function in qemu is as follows: > > > > 1. vhost_net_stop(

Re: [PATCH v6] virtio-pci: Fix the crash that the vector was used after released.

2024-04-11 Thread Cindy Lu
r); if (ret < 0) { return; } ... So I move the setting vector into the function virtio_pci_set_and_change_vector() the other part are the same . the sanity test is passed and the qemu qtest is also passed Thanks Cindy On Fri, Apr 12, 2024 at 2:28 PM Cindy Lu wrote: > > During th

[PATCH v6] virtio-pci: Fix the crash that the vector was used after released.

2024-04-11 Thread Cindy Lu
) at pthread_create.c:442 23 0x7fc871512630 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81 (gdb) Fixes: f9a09ca3ea ("vhost: add support for configure interrupt") Cc: qemu-sta...@nongnu.org Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 43 ++

[PATCH v5] virtio-pci: Fix the crash that the vector was used after released.

2024-04-11 Thread Cindy Lu
) at pthread_create.c:442 23 0x7fc871512630 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81 (gdb) Fixes: f9a09ca3ea ("vhost: add support for configure interrupt") Cc: qemu-sta...@nongnu.org Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 29 +

Re: [PATCH v4] virtio-pci: Fix the crash that the vector was used after released.

2024-04-10 Thread Cindy Lu
On Thu, Apr 11, 2024 at 1:56 PM Michael S. Tsirkin wrote: > > On Thu, Apr 11, 2024 at 12:11:30PM +0800, Cindy Lu wrote: > > During the booting process of the non-standard image, the behavior of the > > called function in qemu is as follows: > > > > 1. vhost_net_stop(

[PATCH v4] virtio-pci: Fix the crash that the vector was used after released.

2024-04-10 Thread Cindy Lu
) at pthread_create.c:442 23 0x7fc871512630 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81 (gdb) Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 30 ++ 1 file changed, 30 insertions(+) diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c

Re: [PATCH v3] virtio-pci: Fix the crash that the vector was used after released.

2024-04-10 Thread Cindy Lu
On Thu, Apr 11, 2024 at 12:18 AM Michael S. Tsirkin wrote: > > On Thu, Apr 11, 2024 at 12:12:00AM +0800, Cindy Lu wrote: > > During the booting process of the non-standard image, the behavior of the > > called function in qemu is as follows: > > > > 1. vhost_net

[PATCH v3] virtio-pci: Fix the crash that the vector was used after released.

2024-04-10 Thread Cindy Lu
) at pthread_create.c:442 23 0x7fc871512630 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81 (gdb) Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 30 ++ 1 file changed, 30 insertions(+) diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c

Re: [PATCH v2 1/1] virtio-pci: Fix the crash that the vector was used after released.

2024-04-09 Thread Cindy Lu
On Wed, Apr 10, 2024 at 1:48 PM Jason Wang wrote: > > On Wed, Apr 10, 2024 at 1:29 PM Cindy Lu wrote: > > > > When the guest triggers vhost_stop and then virtio_reset, the vector will > > the > > IRQFD for this vector will be released and change to VIRTIO_NO_VEC

Re: [PATCH v2 1/1] virtio-pci: Fix the crash that the vector was used after released.

2024-04-09 Thread Cindy Lu
On Wed, Apr 10, 2024 at 1:36 PM Jason Wang wrote: > > On Wed, Apr 10, 2024 at 1:29 PM Cindy Lu wrote: > > > > When the guest triggers vhost_stop and then virtio_reset, the vector will > > the > > IRQFD for this vector will be released and change to VIRTIO_NO_VEC

[PATCH v2 0/1] virtio-pci: Fix the crash that the vector was used after released

2024-04-09 Thread Cindy Lu
et_stop(), So this step will not lost during this process. Change from V1 1.add the check for if using irqfd 2.remove the check for bool recovery, irqfd's user is enough to check status Cindy Lu (1): virtio-pci: Fix the crash that the vector was used after releas

[PATCH v2 1/1] virtio-pci: Fix the crash that the vector was used after released.

2024-04-09 Thread Cindy Lu
640f8d731 in kvm_vcpu_thread_fn (arg=0x560642f205e0) at ../accel/kvm/kvm-accel-ops.c:51 21 0x5606411949f4 in qemu_thread_start (args=0x560642f292b0) at ../util/qemu-thread-posix.c:541 22 0x7fc87148cdcd in start_thread (arg=) at pthread_create.c:442 23 0x7fc871512630 in clone3 () at

Re: [PATCH 1/1] virtio-pci: Fix the crash when the vector changes back from VIRTIO_NO_VECTOR

2024-04-07 Thread Cindy Lu
On Mon, Apr 8, 2024 at 12:59 PM Jason Wang wrote: > > On Sun, Apr 7, 2024 at 3:00 PM Cindy Lu wrote: > > > > On Sun, Apr 7, 2024 at 12:20 PM Jason Wang wrote: > > > > > > On Tue, Apr 2, 2024 at 11:02 PM Cindy Lu wrote: > > > > > > >

Re: [PATCH 1/1] virtio-pci: Fix the crash when the vector changes back from VIRTIO_NO_VECTOR

2024-04-07 Thread Cindy Lu
On Sun, Apr 7, 2024 at 12:20 PM Jason Wang wrote: > > On Tue, Apr 2, 2024 at 11:02 PM Cindy Lu wrote: > > > > When the guest calls virtio_stop and then virtio_reset, > > Guests could not call those functions directly, it is triggered by for > example writing to some

[PATCH 0/1] virtio-pci: Fix the crash when the vector changes back from VIRTIO_NO_VECTOR

2024-04-02 Thread Cindy Lu
0 is_masked 1 [msix_fire_vector_notifier] 112 called vector 0 is_masked 0 To fix this, we need to call the function "kvm_virtio_pci_vector_use_one()" when the vector changes back from VIRTIO_NO_VECTOR Signed-off-by: Cindy Lu Cindy Lu (1): virtio-pci: Fix the crash when the v

[PATCH 1/1] virtio-pci: Fix the crash when the vector changes back from VIRTIO_NO_VECTOR

2024-04-02 Thread Cindy Lu
e_one()" when the vector changes back from VIRTIO_NO_VECTOR Signed-off-by: Cindy Lu --- hw/virtio/virtio-pci.c | 31 --- 1 file changed, 28 insertions(+), 3 deletions(-) diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c index e433879542..45f3ab38c3 10064

Re: [RFC 0/2] disable the configuration interrupt for the unsupported device

2024-03-28 Thread Cindy Lu
On Thu, Mar 28, 2024 at 12:12 PM Jason Wang wrote: > > On Wed, Mar 27, 2024 at 5:33 PM Cindy Lu wrote: > > > > On Wed, Mar 27, 2024 at 5:12 PM Jason Wang wrote: > > > > > > On Wed, Mar 27, 2024 at 4:28 PM Cindy Lu wrote: > > > > > >

Re: [RFC 0/2] disable the configuration interrupt for the unsupported device

2024-03-28 Thread Cindy Lu
On Thu, Mar 28, 2024 at 12:14 PM Jason Wang wrote: > > On Wed, Mar 27, 2024 at 5:44 PM Cindy Lu wrote: > > > > On Wed, Mar 27, 2024 at 5:13 PM Jason Wang wrote: > > > > > > On Wed, Mar 27, 2024 at 5:12 PM Jason Wang wrote: > > > > > &g

  1   2   3   4   5   6   >