From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jan Kiszka Subject: Re: [PATCH 3/5] memory: Flush coalesced MMIO on mapping and state changes Date: Mon, 25 Jun 2012 13:13:14 +0200 Message-ID: <4FE847CA.6010906@siemens.com> References: <47c076c8519f27cdfbf3f1e55432a162e5334e02.1340607659.git.jan.kiszka@siemens.com> <4FE827EA.6000603@redhat.com> <4FE83A2F.8010201@siemens.com> <4FE83CD6.7000607@siemens.com> <4FE84511.2020003@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: Anthony Liguori , Liu Ping Fan , qemu-devel , kvm , Marcelo Tosatti To: Avi Kivity Return-path: In-Reply-To: <4FE84511.2020003@redhat.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+gceq-qemu-devel=gmane.org@nongnu.org Sender: qemu-devel-bounces+gceq-qemu-devel=gmane.org@nongnu.org List-Id: kvm.vger.kernel.org On 2012-06-25 13:01, Avi Kivity wrote: > On 06/25/2012 01:26 PM, Jan Kiszka wrote: >> On 2012-06-25 12:15, Jan Kiszka wrote: >>> On 2012-06-25 10:57, Avi Kivity wrote: >>>> The repetitiveness of this code suggests a different way of doing this: >>>> make every API call be its own subtransaction and perform the flush in >>>> memory_region_begin_transaction() (maybe that's the answer to my >>>> question above). >>> >>> So you want me to wrap the core of those services in >>> begin/commit_transaction instead? Just to be sure I got the idea. >> >> What we would lose this way (transaction_commit) is the ability to skip >> updates on !mr->enabled. > > We could have an internal memory_region_begin_transaction_mr() which > checks mr->enabled and notes it if its clear (but anything else would > have to undo this). I don't think it's worth it, let's lose the > optimization and see if it shows up anywhere. OK, will send a new series with a conversion of this included. Jan -- Siemens AG, Corporate Technology, CT T DE IT 1 Corporate Competence Center Embedded Linux