From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:51378) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VGrJ1-0000VB-0B for qemu-devel@nongnu.org; Tue, 03 Sep 2013 10:10:13 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VGrIv-0003cQ-1J for qemu-devel@nongnu.org; Tue, 03 Sep 2013 10:10:06 -0400 Received: from mx1.redhat.com ([209.132.183.28]:33829) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VGrIu-0003cE-QQ for qemu-devel@nongnu.org; Tue, 03 Sep 2013 10:10:00 -0400 Message-ID: <5225EDAF.2010302@redhat.com> Date: Tue, 03 Sep 2013 16:09:51 +0200 From: Paolo Bonzini MIME-Version: 1.0 References: <1377878817-4513-1-git-send-email-ncmike@ncultra.org> <5220CA9A.7050006@redhat.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [RFC PATCH] Convert ram_list to RCU DQ V2 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Mike Day Cc: Paul Mckenney , Mathew Desnoyers , qemu-devel@nongnu.org, Anthony Liguori Il 03/09/2013 15:56, Mike Day ha scritto: >> > + /* this implements a long-running RCU critical section. >> > + * When rcu reclaims in the code start to become numerous >> > + * it will be necessary to reduce the granularity of this critical >> > + * section. >> > + */ >> >> Please add the same comment (and a rcu_read_lock/unlock pair replacing >> the ramlist mutex) in ram_save_iterate, too. > > Just double checking on this particular change. In practice ram_save > manipulates the ram_list indirectly through ram_save_block. But I'm > assuming you want this change because of the ram state info that > persists between calls to ram_save (ram_list version in particular). ram_list.version is not really a problem, but last_seen_block has to persist across ram_save_block calls. > Also, there is potential for the callback functions > ram_control_*_iterate to manipulate the ram_list. I think that's right now not possible (and they could use rcu_read_lock/unlock as well). Paolo