All of lore.kernel.org
 help / color / mirror / Atom feed
From: Wei Liu <wei.liu2@citrix.com>
To: Anthony PERARD <anthony.perard@citrix.com>
Cc: xen-devel@lists.xenproject.org, Wei Liu <wei.liu2@citrix.com>,
	Ian Jackson <ian.jackson@eu.citrix.com>
Subject: Re: [RFC v2 6/9] libxl: Have QEMU save its state to a file descriptor
Date: Tue, 24 Apr 2018 10:37:46 +0100	[thread overview]
Message-ID: <20180424093746.5e4mj6fm4kxmlhfs@citrix.com> (raw)
In-Reply-To: <20180423154528.GE1980@perard>

On Mon, Apr 23, 2018 at 04:45:28PM +0100, Anthony PERARD wrote:
> On Mon, Apr 23, 2018 at 10:20:42AM +0100, Wei Liu wrote:
> > On Mon, Apr 16, 2018 at 06:32:24PM +0100, Anthony PERARD wrote:
> > > In case QEMU have restricted access to the system, open the file for it,
> > > and QEMU will save its state to this file descritor.
> > > 
> > > Signed-off-by: Anthony PERARD <anthony.perard@citrix.com>
> > 
> > I think this is going to break FreeBSD?
> 
> If the previous patch works on FreeBSD (Learned to send FD through QMP
> to QEMU), this patch shouldn't break anything. Looking at how
> libxl__sendmsg_fds() is implemented, and how the receive side is
> implemented in QEMU, there doesn't seems to be any difference on
> FreeBSD, so I guess it's going to work fine.
> 
> > And what is /dev/fdset exactly? I don't seem to have it on my Debian
> > workstation (with Linux 4.15). So this change can potentially be broken
> > on Linux as well?
> 
> /dev/fdset is a QEMU internal API. You can add a file descriptor to a
> fd-set via QMP or via the command line. And later, you can give a path
> to something in QEMU (maybe a block driver) which refer to a fd-set
> created earlier. The path would be "/dev/fdset/$fdset_number". There can
> be several fd in a fd-set, qemu will just look for the first one which
> have the right permission, like read or write permission.

Oh, I was thinking /dev/fdset was some sort of Linux specific thing. It
is interesting that QEMU actually creates /dev/fdset. That means it
should work fine (at least in theory) for both FreeBSD and Linux.

Wei.

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xenproject.org
https://lists.xenproject.org/mailman/listinfo/xen-devel

  reply	other threads:[~2018-04-24  9:37 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-16 17:32 [RFC v2 0/9] libxl: Enable save/restore/migration of a restricted QEMU Anthony PERARD
2018-04-16 17:32 ` [RFC v2 1/9] libxl_event: Fix DEBUG prints Anthony PERARD
2018-04-19  8:17   ` Wei Liu
2018-04-19 11:01     ` Anthony PERARD
2018-04-16 17:32 ` [RFC v2 2/9] libxl_qmp: Documentation of the logic of the QMP client Anthony PERARD
2018-04-19  8:19   ` Wei Liu
2018-04-16 17:32 ` [RFC v2 3/9] libxl_qmp: Fix use of DEBUG_RECEIVED Anthony PERARD
2018-04-19  8:22   ` Wei Liu
2018-04-16 17:32 ` [RFC v2 4/9] libxl_qmp: Move the buffer realloc to the same scope level as read Anthony PERARD
2018-04-23  9:03   ` Wei Liu
2018-04-23 14:50     ` Anthony PERARD
2018-04-23 15:01       ` Wei Liu
2018-04-16 17:32 ` [RFC v2 5/9] libxl: Learned to send FD through QMP to QEMU Anthony PERARD
2018-04-23  9:04   ` Wei Liu
2018-04-16 17:32 ` [RFC v2 6/9] libxl: Have QEMU save its state to a file descriptor Anthony PERARD
2018-04-23  9:20   ` Wei Liu
2018-04-23 15:45     ` Anthony PERARD
2018-04-24  9:37       ` Wei Liu [this message]
2018-04-24  9:46   ` Wei Liu
2018-04-16 17:32 ` [RFC v2 7/9] libxl_qmp: Implement query-status command Anthony PERARD
2018-04-23  9:24   ` Wei Liu
2018-04-16 17:32 ` [RFC v2 8/9] HACK libxl_exec: Check QEMU status via QMP instead of xenstore Anthony PERARD
2018-04-16 18:09   ` Anthony PERARD
2018-04-17  9:18   ` Anthony PERARD
2018-04-20 18:37   ` Ian Jackson
2018-04-23 16:54     ` Anthony PERARD
2018-04-23 16:56       ` Ian Jackson
2018-04-16 17:32 ` [RFC v2 9/9] libxl_qmp: Add a warning to not trust QEMU Anthony PERARD

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=20180424093746.5e4mj6fm4kxmlhfs@citrix.com \
    --to=wei.liu2@citrix.com \
    --cc=anthony.perard@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=xen-devel@lists.xenproject.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.