From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tiwei Bie Subject: Re: [PATCH v5 09/19] vhost: enable fds passing when sending vhost-user messages Date: Wed, 10 Oct 2018 18:09:29 +0800 Message-ID: <20181010100928.GB2956@debian> References: <20181009205426.21219-1-maxime.coquelin@redhat.com> <20181009205426.21219-10-maxime.coquelin@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Cc: dev@dpdk.org, zhihong.wang@intel.com, jfreimann@redhat.com, nicknickolaev@gmail.com, i.maximets@samsung.com, bruce.richardson@intel.com, alejandro.lucero@netronome.com, dgilbert@redhat.com, stable@dpdk.org To: Maxime Coquelin Return-path: Content-Disposition: inline In-Reply-To: <20181009205426.21219-10-maxime.coquelin@redhat.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Tue, Oct 09, 2018 at 10:54:16PM +0200, Maxime Coquelin wrote: > Passing userfault fds to Qemu will be required for postcopy > live-migration feature. > > Signed-off-by: Dr. David Alan Gilbert > Signed-off-by: Maxime Coquelin > --- > lib/librte_vhost/vhost_user.c | 27 +++++++++++++++------------ > 1 file changed, 15 insertions(+), 12 deletions(-) > > diff --git a/lib/librte_vhost/vhost_user.c b/lib/librte_vhost/vhost_user.c > index bce2395a3..99adcedfa 100644 > --- a/lib/librte_vhost/vhost_user.c > +++ b/lib/librte_vhost/vhost_user.c > @@ -161,6 +161,7 @@ vhost_user_get_features(struct virtio_net **pdev, struct VhostUserMsg *msg, > > msg->payload.u64 = features; > msg->size = sizeof(msg->payload.u64); > + msg->fd_num = 0; When message handlers in this file return VH_RESULT_REPLY, the msg->fd_num will be zeroed explicitly. Do we also want to do this in vhost_crypto_msg_post_handler()? > > return VH_RESULT_REPLY; > } [...]