From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Blue Swirl" Subject: Re: [Qemu-devel] [PATCH 2 of 5] add can_dma/post_dma for direct IO Date: Fri, 12 Dec 2008 21:00:19 +0200 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: "Anthony Liguori" , chrisw@redhat.com, avi@redhat.com, "Gerd Hoffmann" , kvm@vger.kernel.org To: qemu-devel@nongnu.org Return-path: Received: from mail-bw0-f13.google.com ([209.85.218.13]:58688 "EHLO mail-bw0-f13.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753365AbYLLTJY (ORCPT ); Fri, 12 Dec 2008 14:09:24 -0500 Received: by bwz6 with SMTP id 6so3758498bwz.13 for ; Fri, 12 Dec 2008 11:09:22 -0800 (PST) In-Reply-To: Content-Disposition: inline Sender: kvm-owner@vger.kernel.org List-ID: On 12/12/08, Andrea Arcangeli wrote: > From: Andrea Arcangeli > > Add can_dma and post_dma methods needed before/after direct IO to guest > physical memory. > > Signed-off-by: Andrea Arcangeli > + /* nonlinear range */ > + if (pd_first != pd) > + return NULL; In my tests on Sparc32, IOMMU can map a linear DVMA range to several non-linear physical pages, so this case should be handled correctly. From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LBDFP-00036c-Ay for qemu-devel@nongnu.org; Fri, 12 Dec 2008 14:00:23 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LBDFN-000361-Ou for qemu-devel@nongnu.org; Fri, 12 Dec 2008 14:00:22 -0500 Received: from [199.232.76.173] (port=53529 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LBDFN-00035v-II for qemu-devel@nongnu.org; Fri, 12 Dec 2008 14:00:21 -0500 Received: from mail-fx0-f11.google.com ([209.85.220.11]:62621) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LBDFN-0006ej-4a for qemu-devel@nongnu.org; Fri, 12 Dec 2008 14:00:21 -0500 Received: by fxm4 with SMTP id 4so602415fxm.10 for ; Fri, 12 Dec 2008 11:00:19 -0800 (PST) Message-ID: Date: Fri, 12 Dec 2008 21:00:19 +0200 From: "Blue Swirl" Subject: Re: [Qemu-devel] [PATCH 2 of 5] add can_dma/post_dma for direct IO In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: chrisw@redhat.com, kvm@vger.kernel.org, avi@redhat.com, Gerd Hoffmann On 12/12/08, Andrea Arcangeli wrote: > From: Andrea Arcangeli > > Add can_dma and post_dma methods needed before/after direct IO to guest > physical memory. > > Signed-off-by: Andrea Arcangeli > + /* nonlinear range */ > + if (pd_first != pd) > + return NULL; In my tests on Sparc32, IOMMU can map a linear DVMA range to several non-linear physical pages, so this case should be handled correctly.