qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Daniel P. Berrangé" <berrange@redhat.com>
To: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
Cc: marcandre.lureau@redhat.com, pbonzini@redhat.com,
	eduardo@habkost.net, qemu-devel@nongnu.org,
	raphael@enfabrica.net, armbru@redhat.com, yc-core@yandex-team.ru,
	d-tatianin@yandex-team.ru
Subject: Re: [PATCH v2 0/7] chardev: postpone connect
Date: Tue, 14 Oct 2025 14:40:15 +0100	[thread overview]
Message-ID: <aO5Sv8i4rxLFi-XF@redhat.com> (raw)
In-Reply-To: <20251013133836.852018-1-vsementsov@yandex-team.ru>

On Mon, Oct 13, 2025 at 04:38:29PM +0300, Vladimir Sementsov-Ogievskiy wrote:
> Hi all!
> 
> That's a preparation for backend-transfer migration of
> vhost-user-blk. For such migration we are going to transfer
> vhost-user-blk fds, including backend chardev fd to the target
> in migration stream (backed by UNIX domain socket).
> 
> So, on the target, we want to know, should we call connect(),
> or is it a backend-transfer migration, and we should wait for
> incoming fd.
> 
> But at initialization time we can't know it: user may setup
> migration parameters (enabling backend-transfer) later.
> 
> So, let's postpone chardev open/connect phase up to attaching
> to frontend. At this point we can check:
> 
> - if it's vhost-user-blk, do nothing, let vhost-user-blk decide
>   when to do connect()
> - otherwise, do connect() at this point

I'm finding it quite unpleasant that we've created a new set of
callbacks just for the socket backend, and not the other chardev
backends.

Conceptually it feels like the problem of transferring in pre-
opened FDs from a previous QEMU should be conceptually relevant
to all the backend types. If it is, then I very much want us to
convert all the backends instead of leaving a pile of technical
debt for someone else in the future.

This series also doesn't illustrate usage of the new model with
pre-opened FDs, so I'm finding it hard to validate whether
this design is effective or not.


With regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|



  parent reply	other threads:[~2025-10-14 13:41 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-13 13:38 [PATCH v2 0/7] chardev: postpone connect Vladimir Sementsov-Ogievskiy
2025-10-13 13:38 ` [PATCH v2 1/7] chardev/char-socket: simplify reconnect-ms handling Vladimir Sementsov-Ogievskiy
2025-10-14  7:31   ` Marc-André Lureau
2025-10-13 13:38 ` [PATCH v2 2/7] chardev/char: split chardev_init_logfd() out of qemu_char_open() Vladimir Sementsov-Ogievskiy
2025-10-14  7:30   ` Marc-André Lureau
2025-10-14  9:21     ` Vladimir Sementsov-Ogievskiy
2025-10-14 13:55       ` Marc-André Lureau
2025-10-13 13:38 ` [PATCH v2 3/7] chardev/char: qemu_char_open(): add return value Vladimir Sementsov-Ogievskiy
2025-10-14  7:10   ` Marc-André Lureau
2025-10-14  9:13     ` Vladimir Sementsov-Ogievskiy
2025-10-13 13:38 ` [PATCH v2 4/7] chardev/char: move filename and be_opened handling to qemu_char_open() Vladimir Sementsov-Ogievskiy
2025-10-14  7:31   ` Marc-André Lureau
2025-10-13 13:38 ` [PATCH v2 5/7] chardev/char: introduce .init() + .connect() initialization interface Vladimir Sementsov-Ogievskiy
2025-10-14  7:30   ` Marc-André Lureau
2025-10-13 13:38 ` [PATCH v2 6/7] chardev/char-socket: move to .init + .connect api Vladimir Sementsov-Ogievskiy
2025-10-14  7:31   ` Marc-André Lureau
2025-10-13 13:38 ` [PATCH v2 7/7] char: vhost-user-blk call connect by hand Vladimir Sementsov-Ogievskiy
2025-10-14  7:30   ` Marc-André Lureau
2025-10-14  9:18     ` Vladimir Sementsov-Ogievskiy
2025-10-14 13:40 ` Daniel P. Berrangé [this message]
2025-10-14 14:43   ` [PATCH v2 0/7] chardev: postpone connect Vladimir Sementsov-Ogievskiy

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=aO5Sv8i4rxLFi-XF@redhat.com \
    --to=berrange@redhat.com \
    --cc=armbru@redhat.com \
    --cc=d-tatianin@yandex-team.ru \
    --cc=eduardo@habkost.net \
    --cc=marcandre.lureau@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=raphael@enfabrica.net \
    --cc=vsementsov@yandex-team.ru \
    --cc=yc-core@yandex-team.ru \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).