From mboxrd@z Thu Jan 1 00:00:00 1970 From: Will Deacon Subject: Re: [PATCH 00/22 v2] Introduce default domains for iommu groups Date: Fri, 5 Jun 2015 15:22:06 +0100 Message-ID: <20150605142206.GB7420@arm.com> References: <1432831305-11126-1-git-send-email-joro@8bytes.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: <1432831305-11126-1-git-send-email-joro-zLv9SwRftAIdnm+yROfE0A@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 To: Joerg Roedel Cc: "jroedel-l3A5Bk7waGM@public.gmane.org" , Laurent Pinchart , Heiko Stuebner , "linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org" , "iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org" , Thierry Reding , Kukjin Kim , David Woodhouse List-Id: iommu@lists.linux-foundation.org Hi Joerg, On Thu, May 28, 2015 at 05:41:23PM +0100, Joerg Roedel wrote: > here is the second version of my patch-set to introduce > default domains into the iommu core. This time it has a lot > more patches, mostly because I added a proof of concept > implementation by converting the AMD IOMMU driver to make > use of it. Most of this looks fine to me, modulo by comments about the dm regions (which I'm not sure how to implement for ARM). > Converting the first driver to the new concept triggered a > lot of changes and extensions in the patch-set to fit all > the needs of a more complex iommu driver. Converting other > drivers might need further changes, but that is something > for the future. > > A major change is that now the default domain has to be > allocated by the code that allocates the iommu group. For > PCI devices this happens in the IOMMU core, but drivers > allocating the group on their own can now implement a policy > that fits their needs (e.g. not allocate one domain per > group but let multiple groups share one domain). Makes sense. I really think we should be moving group allocation out of the IOMMU drivers and into the bus code, like we already have for PCI. Once we've got a way to describe groups of platform devices (e.g. in the device-tree), then we can have the group creation happen automatically as part of Laurent's of_iommu work. Will