From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:39838) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bKk8g-0004Um-Rl for qemu-devel@nongnu.org; Wed, 06 Jul 2016 06:33:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bKk8b-0007gj-QX for qemu-devel@nongnu.org; Wed, 06 Jul 2016 06:33:06 -0400 Received: from mx1.redhat.com ([209.132.183.28]:38221) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bKk8b-0007gY-Kj for qemu-devel@nongnu.org; Wed, 06 Jul 2016 06:33:01 -0400 Date: Wed, 6 Jul 2016 13:32:57 +0300 From: "Michael S. Tsirkin" Message-ID: <20160706132529-mutt-send-email-mst@redhat.com> References: <1467772593-29703-1-git-send-email-liang.z.li@intel.com> <20160706111832-mutt-send-email-mst@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Subject: Re: [Qemu-devel] [PATCH v2] balloon: Fix failure of updating guest memory status List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Li, Liang Z" Cc: "qemu-devel@nongnu.org" , Ladi Prosek , Paolo Bonzini , "dgilbert@redhat.com" On Wed, Jul 06, 2016 at 09:23:46AM +0000, Li, Liang Z wrote: > > On Wed, Jul 06, 2016 at 10:36:33AM +0800, Liang Li wrote: > > > After live migration, 'guest-stats' can't get the expected memory > > > status in the guest. This issue is caused by commit 4eae2a657d. > > > The value of 's->stats_vq_elem' will be NULL after live migration, and > > > the check in the function 'balloon_stats_poll_cb()' will prevent the > > > 'virtio_notify()' from executing. So guest will not update the memory > > > status. > > > > > > Commit 4eae2a657d is doing the right thing, but 's->stats_vq_elem' > > > should be treated as part of balloon device state and migrated to > > > destination if it's not NULL to make everything works well. > > > > > > Signed-off-by: Liang Li > > > Suggested-by: Paolo Bonzini > > > Cc: Michael S. Tsirkin > > > Cc: Ladi Prosek > > > Cc: Paolo Bonzini > > > > I agree there's an issue but we don't change versions anymore. > > Breaking migrations for everyone is also not nice. > > > > How about queueing virtio_balloon_receive_stats so it will get invoked when > > vm starts? > > > > Could you give more explanation about how it works? I can't catch you. > > Thanks! > Liang virtqueue_discard before migration virtio_balloon_receive_stats after migration -- MST