From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754462AbbIWMId (ORCPT ); Wed, 23 Sep 2015 08:08:33 -0400 Received: from eu-smtp-delivery-143.mimecast.com ([207.82.80.143]:56185 "EHLO eu-smtp-delivery-143.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753467AbbIWMIb convert rfc822-to-8bit (ORCPT ); Wed, 23 Sep 2015 08:08:31 -0400 Subject: Re: How to ensure that different peripherals getting different IOVA address in kernel? To: chenfeng , "joro@8bytes.org" , "iommu@lists.linux-foundation.org" , "linux-kernel@vger.kernel.org" , "rcallicotte@gmail.com" , "jiang.liu@linux.intel.com" References: <5600AF72.2000106@hisilicon.com> <560206AE.4020608@hisilicon.com> Cc: Dan zhao , qijiwen , Peter Panshilin , Suzhuangluan , Yiping Xu , "Wangfei (William, Euler)" From: Robin Murphy Message-ID: <5602963C.8030601@arm.com> Date: Wed, 23 Sep 2015 13:08:28 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 MIME-Version: 1.0 In-Reply-To: <560206AE.4020608@hisilicon.com> X-OriginalArrivalTime: 23 Sep 2015 12:08:28.0711 (UTC) FILETIME=[8E9D4370:01D0F5F8] X-MC-Unique: IEot0qb_SMW6eOZ4BdvIcA-1 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8BIT Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 23/09/15 02:55, chenfeng wrote: > Hi all, > > In IOMMU architecture , how to make two different peripherals share the same page table ? > > In other words , is there a mechanism or structure to make two peripherals get completely different address. > > eg: > > peri-A、peri-B and peri-C share the same iova address 0-1G for some performance requests. > > So the A,B,C need to use the same IOVA generator to ensure this,but I don't find an architecture to make this. This is what IOMMU domains are all about: devices in one domain are isolated from devices in different domains, so all you need to do is make sure all devices that want to share buffers are attached to the same domain, then they will all share that domain's IOVA space. Robin. > > Any help will be appreciated. > > Puck > >