All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: "Marc-André Lureau" <marcandre.lureau@redhat.com>
Cc: qemu-devel@nongnu.org, armbru@redhat.com, peterx@redhat.com
Subject: Re: [PATCH 11/41] RFC io/net-listener: move mutex init to instance_init
Date: Tue, 28 Apr 2026 08:05:00 +0100	[thread overview]
Message-ID: <afBcHHhu5CUefACW@redhat.com> (raw)
In-Reply-To: <20260427-qom-tests-v1-11-c413f3605311@redhat.com>

On Mon, Apr 27, 2026 at 11:42:10PM +0400, Marc-André Lureau wrote:
> The QIONetListener mutex is initialized in the convenience
> constructor qio_net_listener_new() rather than in an instance_init.
> This means a bare object_new(TYPE_QIO_NET_LISTENER) produces an
> object with an uninitialized mutex, but instance_finalize
> unconditionally calls qemu_mutex_destroy() on it, which aborts.
> 
> Move the mutex initialization to a proper instance_init so that init
> and finalize are always paired regardless of how the object is
> created.
> 
> This patch is just added for completeness, but "qio: Fix
> qom-list-properties crash on net listener object" from Peter Xu is
> basically the same.
> 
> Fixes: 9d86181874a ("qio: Protect NetListener callback with mutex")
> Cc: peterx@redhat.com
> Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
> ---
>  io/net-listener.c | 9 ++++++++-
>  1 file changed, 8 insertions(+), 1 deletion(-)

Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>



  reply	other threads:[~2026-04-28  7:05 UTC|newest]

Thread overview: 90+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-04-27 19:41 [PATCH 00/41] Fix various QOM object life-cycle issues Marc-André Lureau
2026-04-27 19:42 ` [PATCH 01/41] hw/pci: handle missing bus in prop_pci_busnr_get Marc-André Lureau
2026-04-27 19:42 ` [PATCH 02/41] chardev/char-socket: handle NULL addr in char_socket_get_addr Marc-André Lureau
2026-04-27 19:42 ` [PATCH 03/41] hw/pci-bridge: handle missing parent in prop_pxb_uid_get Marc-André Lureau
2026-04-27 19:42 ` [PATCH 04/41] hw/pci-host/i440fx: handle NULL bus in pci-hole64 getters Marc-André Lureau
2026-04-27 21:00   ` Philippe Mathieu-Daudé
2026-04-28  6:10     ` Marc-André Lureau
2026-04-28  6:14       ` Philippe Mathieu-Daudé
2026-04-27 19:42 ` [PATCH 05/41] hw/pci-host/q35: " Marc-André Lureau
2026-04-27 19:42 ` [PATCH 06/41] hw/remote: check visit return in vfu_object_set_socket Marc-André Lureau
2026-04-27 20:38   ` Jagannathan Raman
2026-04-27 19:42 ` [PATCH 07/41] qom: skip link property check callback when clearing link Marc-André Lureau
2026-04-30 15:48   ` Peter Maydell
2026-04-27 19:42 ` [PATCH 08/41] hw/intc/apic: guard against NULL cpu in set_id Marc-André Lureau
2026-04-27 20:40   ` Philippe Mathieu-Daudé
2026-05-03  8:19     ` marcandre.lureau
2026-04-27 19:42 ` [PATCH 09/41] RFC hw/remote: guard listener unregister in finalize Marc-André Lureau
2026-04-27 19:58   ` Jagannathan Raman
2026-04-28 10:17     ` Marc-André Lureau
2026-04-27 19:42 ` [PATCH 10/41] backends/cryptodev-lkcf: skip cleanup when not initialized Marc-André Lureau
2026-04-28  0:05   ` zhenwei pi
2026-04-27 19:42 ` [PATCH 11/41] RFC io/net-listener: move mutex init to instance_init Marc-André Lureau
2026-04-28  7:05   ` Daniel P. Berrangé [this message]
2026-04-29 21:08   ` Peter Xu
2026-04-27 19:42 ` [PATCH 12/41] RFC net/colo-compare: guard finalize against uninitialized state Marc-André Lureau
2026-04-29 20:58   ` Peter Xu
2026-04-29 21:09     ` Marc-André Lureau
2026-04-29 22:24       ` Peter Xu
2026-04-27 19:42 ` [PATCH 13/41] RFC system/ioport: move embedded memory region cleanup to portio_list_destroy Marc-André Lureau
2026-04-29 21:07   ` Peter Xu
2026-05-04  7:11     ` marcandre.lureau
2026-04-27 19:42 ` [PATCH 14/41] ui/console: remove console from global list on finalization Marc-André Lureau
2026-04-27 19:42 ` [PATCH 15/41] hw/i386/x86: free oem_id and oem_table_id " Marc-André Lureau
2026-04-27 20:41   ` Philippe Mathieu-Daudé
2026-04-27 19:42 ` [PATCH 16/41] hw/core/machine: free shim_filename " Marc-André Lureau
2026-04-27 19:42 ` [PATCH 17/41] hw/core/resetcontainer: free children array " Marc-André Lureau
2026-04-30 15:50   ` Peter Maydell
2026-04-27 19:42 ` [PATCH 18/41] net/filter: free old values in property setters Marc-André Lureau
2026-04-27 19:42 ` [PATCH 19/41] ui/console-vc: destroy fifo on text console finalization Marc-André Lureau
2026-04-27 19:42 ` [PATCH 20/41] target/i386/sev: add finalize functions and fix leaking setters Marc-André Lureau
2026-04-27 19:42 ` [PATCH 21/41] target/i386/kvm/tdx: free strings in tdx_guest_finalize Marc-André Lureau
2026-04-27 19:42 ` [PATCH 22/41] hw/i386/nitro_enclave: add instance finalize Marc-André Lureau
2026-04-27 19:42 ` [PATCH 23/41] net/can: free ifname on socketcan finalization Marc-André Lureau
2026-04-28  8:25   ` Pavel Pisa
2026-04-27 19:42 ` [PATCH 24/41] backends/igvm-cfg: free filename on finalization Marc-André Lureau
2026-04-28  6:55   ` Gerd Hoffmann
2026-04-27 19:42 ` [PATCH 25/41] scsi/pr-manager-helper: free path " Marc-André Lureau
2026-04-30 15:51   ` Peter Maydell
2026-04-27 19:42 ` [PATCH 26/41] accel/kvm: free device " Marc-André Lureau
2026-04-30 15:56   ` Peter Maydell
2026-04-27 19:42 ` [PATCH 27/41] system/qtest: free log " Marc-André Lureau
2026-04-30 16:01   ` Peter Maydell
2026-05-04  7:23     ` marcandre.lureau
2026-04-27 19:42 ` [PATCH 28/41] hw/i386/pc: free pcspk " Marc-André Lureau
2026-04-27 19:42 ` [PATCH 29/41] hw/fsi: move OPBus address space init to realize Marc-André Lureau
2026-04-30 16:09   ` Peter Maydell
2026-04-30 17:47     ` Cédric Le Goater
2026-04-27 19:42 ` [PATCH 30/41] hw/gpio/pca9552: fix state_str leak in pca955x_set_led Marc-André Lureau
2026-04-27 20:19   ` Miles Glenn
2026-04-27 20:46   ` Philippe Mathieu-Daudé
2026-04-27 19:42 ` [PATCH 31/41] hw/arm/aspeed: free fmc_model and spi_model on finalization Marc-André Lureau
2026-04-30 17:32   ` Cédric Le Goater
2026-04-27 19:42 ` [PATCH 32/41] hw/tpm: free PPI buffer " Marc-André Lureau
2026-04-27 20:29   ` Stefan Berger
2026-04-27 19:42 ` [PATCH 33/41] hw/arm/sbsa-ref: free unrealized flash devices " Marc-André Lureau
2026-04-27 20:49   ` Philippe Mathieu-Daudé
2026-04-27 19:42 ` [PATCH 34/41] hw/arm/virt: free flash devices and OEM strings " Marc-André Lureau
2026-04-27 20:50   ` Philippe Mathieu-Daudé
2026-04-30 15:12   ` Peter Maydell
2026-04-30 15:18     ` Philippe Mathieu-Daudé
2026-04-30 15:30       ` Peter Maydell
2026-05-11 13:01         ` Marc-André Lureau
2026-05-11 14:33           ` Peter Maydell
2026-04-27 19:42 ` [PATCH 35/41] hw/loongarch/virt: " Marc-André Lureau
2026-04-27 19:42 ` [PATCH 36/41] hw/ppc/spapr: free host_model and host_serial " Marc-André Lureau
2026-04-27 19:42 ` [PATCH 37/41] hw/ppc/pnv: drop extra ref on PHB after adding as child Marc-André Lureau
2026-04-27 20:20   ` Miles Glenn
2026-05-10  9:02   ` Aditya Gupta
2026-04-27 19:42 ` [PATCH 38/41] target/riscv: fix general_user_opts hash table leak Marc-André Lureau
2026-05-01  1:53   ` Alistair Francis
2026-05-04 10:29     ` marcandre.lureau
2026-05-05 15:43     ` Daniel Henrique Barboza
2026-04-27 19:42 ` [PATCH 39/41] hw/riscv/virt: free flash devices and OEM strings on finalization Marc-André Lureau
2026-04-27 20:51   ` Philippe Mathieu-Daudé
2026-04-28  2:19   ` Alistair Francis
2026-04-27 19:42 ` [PATCH 40/41] hw/i2c/pmbus: fix undefined behavior in pmbus_direct_mode2data Marc-André Lureau
2026-04-27 19:42 ` [PATCH 41/41] qtest: add "qom-tests" command Marc-André Lureau
2026-04-27 20:06   ` Peter Maydell
2026-04-28  6:37     ` Marc-André Lureau
2026-04-28  7:48       ` Peter Maydell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=afBcHHhu5CUefACW@redhat.com \
    --to=berrange@redhat.com \
    --cc=armbru@redhat.com \
    --cc=marcandre.lureau@redhat.com \
    --cc=peterx@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.