From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1761239Ab2EQHTy (ORCPT ); Thu, 17 May 2012 03:19:54 -0400 Received: from mail-gg0-f174.google.com ([209.85.161.174]:40176 "EHLO mail-gg0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1761142Ab2EQHTw convert rfc822-to-8bit (ORCPT ); Thu, 17 May 2012 03:19:52 -0400 MIME-Version: 1.0 In-Reply-To: <20120511225555.30496.80525.stgit@bling.home> References: <20120511222148.30496.68571.stgit@bling.home> <20120511225555.30496.80525.stgit@bling.home> Date: Thu, 17 May 2012 15:19:51 +0800 X-Google-Sender-Auth: x1afFdZAnynH0rfBTepEkLBjIQA Message-ID: Subject: Re: [PATCH 04/13] pci: New pci_dma_quirk() From: Anonymous To: Alex Williamson Cc: benh@kernel.crashing.org, aik@ozlabs.ru, david@gibson.dropbear.id.au, joerg.roedel@amd.com, dwmw2@infradead.org, kvm@vger.kernel.org, B07421@freescale.com, linux-pci@vger.kernel.org, agraf@suse.de, qemu-devel@nongnu.org, chrisw@sous-sol.org, B08248@freescale.com, iommu@lists.linux-foundation.org, avi@redhat.com, gregkh@linuxfoundation.org, bhelgaas@google.com, linux-kernel@vger.kernel.org, benve@cisco.com Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Alex, On Sat, May 12, 2012 at 6:55 AM, Alex Williamson wrote: > Integrating IOMMU groups more closely into the driver core allows > us to more easily work around DMA quirks.  The Ricoh multifunction > controller is a favorite example of devices that are currently > incompatible with IOMMU isolation as all the functions use the > requestor ID of function 0 for DMA.  Passing this device into > pci_dma_quirk returns the PCI device to use for DMA.  The IOMMU > driver can then construct an IOMMU group including both devices. > Please give some thought to the Marvell SATA controller quirk as well. Instead of multiple visible functions using the same requester ID of function 0, the Marvell device only makes function 0 visible, but uses the requestor ID of function 1 as well during DMA. See https://bugzilla.redhat.com/show_bug.cgi?id=757166 -- A. From mboxrd@z Thu Jan 1 00:00:00 1970 From: Anonymous Subject: Re: [PATCH 04/13] pci: New pci_dma_quirk() Date: Thu, 17 May 2012 15:19:51 +0800 Message-ID: References: <20120511222148.30496.68571.stgit@bling.home> <20120511225555.30496.80525.stgit@bling.home> Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Cc: B07421-KZfg59tc24xl57MIdRCFDg@public.gmane.org, kvm-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, gregkh-hQyY1W1yCW8ekmWlsbkhG0B+6BGkLq7r@public.gmane.org, aik-sLpHqDYs0B2HXe+LvDLADg@public.gmane.org, benh-XVmvHMARGAS8U2dJNN8I7kB+6BGkLq7r@public.gmane.org, linux-pci-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, agraf-l3A5Bk7waGM@public.gmane.org, qemu-devel-qX2TKyscuCcdnm+yROfE0A@public.gmane.org, chrisw-69jw2NvuJkxg9hUCZPvPmw@public.gmane.org, B08248-KZfg59tc24xl57MIdRCFDg@public.gmane.org, iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org, avi-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org, bhelgaas-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org, benve-FYB4Gu1CFyUAvxtiuMwx3w@public.gmane.org, dwmw2-wEGCiKHe2LqWVfeAwA7xHQ@public.gmane.org, linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, david-xT8FGy+AXnRB3Ne2BGzF6laj5H9X9Tb+@public.gmane.org To: Alex Williamson Return-path: In-Reply-To: <20120511225555.30496.80525.stgit-xdHQ/5r00wBBDLzU/O5InQ@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Errors-To: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org List-Id: kvm.vger.kernel.org Alex, On Sat, May 12, 2012 at 6:55 AM, Alex Williamson wrote: > Integrating IOMMU groups more closely into the driver core allows > us to more easily work around DMA quirks. =A0The Ricoh multifunction > controller is a favorite example of devices that are currently > incompatible with IOMMU isolation as all the functions use the > requestor ID of function 0 for DMA. =A0Passing this device into > pci_dma_quirk returns the PCI device to use for DMA. =A0The IOMMU > driver can then construct an IOMMU group including both devices. > Please give some thought to the Marvell SATA controller quirk as well. Instead of multiple visible functions using the same requester ID of function 0, the Marvell device only makes function 0 visible, but uses the requestor ID of function 1 as well during DMA. See https://bugzilla.redhat.com/show_bug.cgi?id=3D757166 -- A. From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:47896) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SUv0A-0002Pa-P6 for qemu-devel@nongnu.org; Thu, 17 May 2012 03:20:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SUv05-0001bP-S2 for qemu-devel@nongnu.org; Thu, 17 May 2012 03:19:58 -0400 Received: from mail-yw0-f45.google.com ([209.85.213.45]:33848) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SUv05-0001bG-L9 for qemu-devel@nongnu.org; Thu, 17 May 2012 03:19:53 -0400 Received: by yhoo21 with SMTP id o21so2053939yho.4 for ; Thu, 17 May 2012 00:19:51 -0700 (PDT) MIME-Version: 1.0 Sender: acooks@gmail.com In-Reply-To: <20120511225555.30496.80525.stgit@bling.home> References: <20120511222148.30496.68571.stgit@bling.home> <20120511225555.30496.80525.stgit@bling.home> Date: Thu, 17 May 2012 15:19:51 +0800 Message-ID: From: Anonymous Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH 04/13] pci: New pci_dma_quirk() List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Alex Williamson Cc: B07421@freescale.com, kvm@vger.kernel.org, gregkh@linuxfoundation.org, aik@ozlabs.ru, linux-pci@vger.kernel.org, agraf@suse.de, qemu-devel@nongnu.org, chrisw@sous-sol.org, B08248@freescale.com, iommu@lists.linux-foundation.org, avi@redhat.com, joerg.roedel@amd.com, bhelgaas@google.com, benve@cisco.com, dwmw2@infradead.org, linux-kernel@vger.kernel.org, david@gibson.dropbear.id.au Alex, On Sat, May 12, 2012 at 6:55 AM, Alex Williamson wrote: > Integrating IOMMU groups more closely into the driver core allows > us to more easily work around DMA quirks. =A0The Ricoh multifunction > controller is a favorite example of devices that are currently > incompatible with IOMMU isolation as all the functions use the > requestor ID of function 0 for DMA. =A0Passing this device into > pci_dma_quirk returns the PCI device to use for DMA. =A0The IOMMU > driver can then construct an IOMMU group including both devices. > Please give some thought to the Marvell SATA controller quirk as well. Instead of multiple visible functions using the same requester ID of function 0, the Marvell device only makes function 0 visible, but uses the requestor ID of function 1 as well during DMA. See https://bugzilla.redhat.com/show_bug.cgi?id=3D757166 -- A.