From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.3 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_MUTT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 99A89C4321A for ; Tue, 11 Jun 2019 04:56:19 +0000 (UTC) Received: from mail.linuxfoundation.org (mail.linuxfoundation.org [140.211.169.12]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 679752086D for ; Tue, 11 Jun 2019 04:56:19 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 679752086D Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=intel.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=iommu-bounces@lists.linux-foundation.org Received: from mail.linux-foundation.org (localhost [127.0.0.1]) by mail.linuxfoundation.org (Postfix) with ESMTP id 31CFEB7D; Tue, 11 Jun 2019 04:56:19 +0000 (UTC) Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTPS id A6188B5F for ; Tue, 11 Jun 2019 04:56:17 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by smtp1.linuxfoundation.org (Postfix) with ESMTPS id 4200E63D for ; Tue, 11 Jun 2019 04:56:17 +0000 (UTC) X-Amp-Result: UNSCANNABLE X-Amp-File-Uploaded: False Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 Jun 2019 21:56:16 -0700 X-ExtLoop1: 1 Received: from araj-mobl1.jf.intel.com ([10.254.89.212]) by fmsmga004.fm.intel.com with ESMTP; 10 Jun 2019 21:56:15 -0700 Date: Mon, 10 Jun 2019 21:56:14 -0700 From: "Raj, Ashok" To: "Prakhya, Sai Praneeth" Subject: Re: Device specific pass through in host systems - discuss user interface Message-ID: <20190611045614.GB6469@araj-mobl1.jf.intel.com> References: <20190610135617.GA27166@araj-mobl1.jf.intel.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.1 (2017-09-22) Cc: "Shankar, Ravi V" , "Tian, Kevin" , "jroedel@suse.de" , "Lu, Baolu" , Will Deacon , "iommu@lists.linux-foundation.org" , "Pan, Jacob jun" , "robin.murphy@arm.com" , "hch@lst.de" , Ashok Raj X-BeenThere: iommu@lists.linux-foundation.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Development issues for Linux IOMMU support List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: iommu-bounces@lists.linux-foundation.org Errors-To: iommu-bounces@lists.linux-foundation.org On Mon, Jun 10, 2019 at 09:38:11PM -0700, Sai Praneeth Prakhya wrote: > Hi All, > > + Sohil and Rob Clark (as there are dropped from CC'list) > > > > > Most iommu vendor drivers have switched from per-device to per-group > > > > domain (a.k.a. default domain). So per-group pass-through mode makes > > more sense? > > > > > > > > By the way, can we extend this to "per-group default domain type", > > > > instead of only "per-group pass-through mode"? Currently we have > > > > system level default domain type, if we have finer granularity of > > > > default domain type, both iommu drivers and end users will benefit from it. > > > > > > Sure! Makes sense.. per-group default domain type sounds good. > > I am planning to implement an RFC (supporting only runtime case for now) which works as below > > 1. User unbinds the driver by writing to sysfs > 2. User puts a group in pass through mode by writing "1" to > /sys/kernel/iommu_groups//pt might be better to read current value of default domain for that group.. /sys/kernel/iommu_groups//default_domain reading the above value shows current setting. provide a differnet file next_def_domain, and you can echo "pt" or "dma_domain" to switch to pass-through, or normal dma isolation mode. For devices that automatically set to pass through today like graphics, or isoch audio you can show "pt" as default_domain. _______________________________________________ iommu mailing list iommu@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/iommu