From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LOwO1-00046f-57 for qemu-devel@nongnu.org; Mon, 19 Jan 2009 10:50:01 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LOwNz-00045i-Ch for qemu-devel@nongnu.org; Mon, 19 Jan 2009 10:50:00 -0500 Received: from [199.232.76.173] (port=33215 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LOwNz-00045c-8S for qemu-devel@nongnu.org; Mon, 19 Jan 2009 10:49:59 -0500 Received: from mail-qy0-f20.google.com ([209.85.221.20]:41486) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LOwNy-0000FN-Ll for qemu-devel@nongnu.org; Mon, 19 Jan 2009 10:49:59 -0500 Received: by qyk13 with SMTP id 13so4102845qyk.10 for ; Mon, 19 Jan 2009 07:49:58 -0800 (PST) Message-ID: <4974A117.2070206@codemonkey.ws> Date: Mon, 19 Jan 2009 09:49:43 -0600 From: Anthony Liguori MIME-Version: 1.0 References: <1232308399-21679-1-git-send-email-avi@redhat.com> <1232308399-21679-2-git-send-email-avi@redhat.com> <49749497.6040701@codemonkey.ws> <49749631.5090700@redhat.com> In-Reply-To: <49749631.5090700@redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Re: [PATCH 1/5] Add target memory mapping API Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Avi Kivity Cc: qemu-devel@nongnu.org Avi Kivity wrote: > Anthony Liguori wrote: >>> + if ((pd & ~TARGET_PAGE_MASK) != IO_MEM_RAM) { >>> + if (done || bounce.buffer) { >>> + break; >>> + } >>> + bounce.buffer = qemu_memalign(TARGET_PAGE_SIZE, >>> TARGET_PAGE_SIZE); >>> + bounce.addr = addr; >>> + bounce.len = l; >>> >> >> I like the bouncing approach. Namely, that it never bounces more >> than a page at a time. I think that's clever. > > I tried to make it as stupid as possible. Looks like I failed. Or your version of stupid is my version of clever :-) Regards, Anthony Liguori