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.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no 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 17CCDC433DF for ; Thu, 14 May 2020 19:56:31 +0000 (UTC) Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (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 7168B2065C for ; Thu, 14 May 2020 19:56:30 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 7168B2065C Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=8bytes.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=iommu-bounces@lists.linux-foundation.org Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 1F516271B3; Thu, 14 May 2020 19:56:30 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id qmhHN+UbozIq; Thu, 14 May 2020 19:56:25 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by silver.osuosl.org (Postfix) with ESMTP id 3BCC220464; Thu, 14 May 2020 19:56:25 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id 0DC1CC0178; Thu, 14 May 2020 19:56:25 +0000 (UTC) Received: from hemlock.osuosl.org (smtp2.osuosl.org [140.211.166.133]) by lists.linuxfoundation.org (Postfix) with ESMTP id 0349EC016F for ; Thu, 14 May 2020 19:56:24 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by hemlock.osuosl.org (Postfix) with ESMTP id E6B208898B for ; Thu, 14 May 2020 19:56:23 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from hemlock.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id XXkEHhvnWtZl for ; Thu, 14 May 2020 19:56:20 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from theia.8bytes.org (8bytes.org [81.169.241.247]) by hemlock.osuosl.org (Postfix) with ESMTPS id 4570D88235 for ; Thu, 14 May 2020 19:56:20 +0000 (UTC) Received: by theia.8bytes.org (Postfix, from userid 1000) id BDBA626F; Thu, 14 May 2020 21:56:16 +0200 (CEST) Date: Thu, 14 May 2020 21:56:15 +0200 From: Joerg Roedel To: "Prakhya, Sai Praneeth" Subject: Re: [PATCH] iommu: Remove functions that support private domain Message-ID: <20200514195615.GP18353@8bytes.org> References: <20200513224721.20504-1-sai.praneeth.prakhya@intel.com> <20200514131315.GJ18353@8bytes.org> <20200514183233.GO18353@8bytes.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Cc: "iommu@lists.linux-foundation.org" X-BeenThere: iommu@lists.linux-foundation.org X-Mailman-Version: 2.1.15 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 Errors-To: iommu-bounces@lists.linux-foundation.org Sender: "iommu" On Thu, May 14, 2020 at 06:44:16PM +0000, Prakhya, Sai Praneeth wrote: > Could you please explain why we shouldn't change default-domain for an > iommu group that has multiple devices? Because you can't be sure that a device is bound to a driver while the default domain of the group is changed. As long as this race condition exists we can't change the default domains of groups with multiple devices at runtime. > I am asking this particularly because the patch set I am working on > allows to change default-domain for an iommu group that has multiple > devices. The pre-requisite being that all the devices in the group > should already be unbounded from the device driver and the > default-domain preferences of all the devices in the group shouldn't > have conflicting types i.e. some devices cannot say they *only* need > identity domain while other devices in the same group say that they > *only* need to be in DMA domain. In this case, we will not be able to > decide upon a default-domain for the iommu group. Yeah, but as I wrote above, this is racy and there is currently no way to fix that. So we can't support it. Regards, Joerg _______________________________________________ iommu mailing list iommu@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/iommu