From: Ian Jackson Subject: Re: [PATCH v8 21/21] libxl: add support for migrating HVM guests without a device model Date: Wed, 11 Nov 2015 15:55:48 +0000 Message-ID: <22083.25860.176143.872220@mariner.uk.xensource.com> References: <1446825955-11842-1-git-send-email-roger.pau@citrix.com> <1446825955-11842-22-git-send-email-roger.pau@citrix.com> <20151111154922.GE10274@zion.uk.xensource.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1ZwXkn-00079K-G0 for xen-devel@lists.xenproject.org; Wed, 11 Nov 2015 15:56:09 +0000 In-Reply-To: <20151111154922.GE10274@zion.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Wei Liu Cc: xen-devel@lists.xenproject.org, Andrew Cooper , Ian Campbell , Roger Pau Monne List-Id: xen-devel@lists.xenproject.org Wei Liu writes ("Re: [PATCH v8 21/21] libxl: add support for migrating HVM guests without a device model"): > On Fri, Nov 06, 2015 at 05:05:55PM +0100, Roger Pau Monne wrote: > > @@ -387,6 +396,7 @@ static void emulator_xenstore_record_done(libxl__egc *egc, > > libxl__stream_write_state *stream) > > { > > libxl__domain_suspend_state *dss = stream->dss; > > + STATE_AO_GC(stream->ao); > > > > This is redundant. `Unneeded' calls to STATE_AO_GC (ie ones in functions which do not actually use anything from ao or gc) are at worst harmless. In fact, such uses of STATE_AO_GC provide additional safety, because they call libxl__ao_inprogress_gc which checks that the ao is in the right state. So I think there is nothing wrong with adding this call here (even if it is a left-over addition from a previous version or draft of this patch, or from wanting to add some calls to LOG* for debugging). There would also be nothing wrong with not adding it. Ian.