From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:55098) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YbNKd-0000QN-2o for qemu-devel@nongnu.org; Fri, 27 Mar 2015 02:01:23 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YbNKZ-00038S-Rm for qemu-devel@nongnu.org; Fri, 27 Mar 2015 02:01:23 -0400 Received: from mail-wg0-x22e.google.com ([2a00:1450:400c:c00::22e]:34592) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YbNKZ-000389-MF for qemu-devel@nongnu.org; Fri, 27 Mar 2015 02:01:19 -0400 Received: by wgs2 with SMTP id 2so88218236wgs.1 for ; Thu, 26 Mar 2015 23:01:19 -0700 (PDT) Sender: Paolo Bonzini Message-ID: <5514F22A.3090004@redhat.com> Date: Fri, 27 Mar 2015 07:01:14 +0100 From: Paolo Bonzini MIME-Version: 1.0 References: <1427391520-29497-1-git-send-email-pbonzini@redhat.com> <1427391520-29497-6-git-send-email-pbonzini@redhat.com> <20150327054458.GA16079@ad.nay.redhat.com> In-Reply-To: <20150327054458.GA16079@ad.nay.redhat.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 05/22] memory: return bitmap from memory_region_is_logging List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Fam Zheng Cc: qemu-devel@nongnu.org, "Michael S. Tsirkin" On 27/03/2015 06:44, Fam Zheng wrote: > Based on the commit log that said memory_region_is_logging() only returns 0 or > (1 << DIRTY_MEMORY_VGA), the new code keeps the truth table. But I don't > understand why is DIRTY_MEMORY_MIGRATION excluded here and below? Because DIRTY_MEMORY_MIGRATION is handled via the log_global_start/log_global_stop mechanism. The functions I'm patching here are called only through region_add and region_del, so they do not care about DIRTY_MEMORY_MIGRATION. The plan is to remove this special case: > This is the ugliest patch in the series. My long-term plan > is to get rid of the global start/stop hooks in the > MemoryListeners. but it is not trivial so it's better done in a different patch series. Paolo