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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5554AC433EF for ; Fri, 28 Jan 2022 07:49:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1347101AbiA1HtF (ORCPT ); Fri, 28 Jan 2022 02:49:05 -0500 Received: from mga04.intel.com ([192.55.52.120]:13161 "EHLO mga04.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S243077AbiA1Hsv (ORCPT ); Fri, 28 Jan 2022 02:48:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1643356131; x=1674892131; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=yA9I1TVBAWLRwxa+kG83/UciNiFWOt5jTTLojABMHJc=; b=Hhu+Kw+mPXfXIHz19qz9thMoPF0gyxQP4SpeBcZG4THqproq5YZPF4ks qDf9fhpvonXqMdct9BXAZRJQlCxIMtETgFycaEmQfnxMyfKfchyziHHWa vUdF3gGylf/YZ70PPH/Omqpz4ekYVfbLyKDoIEdJUk3WT0oZkXYzhmDuN N87GOhzAJBxe4ZCJe1czyrq16coK2W8iMlzVDxECKdVyRyB8URWStTE1U /3p4BvzGav3Msl8RWkLBoxbavzu1cedbORNhSKzrE97IeXt4WjNlpLKti h2GRuVpY36hhuZeWoInJ6kSdav+C/U8cQ4IAlEMbPA7CWWi/iuPi/kbER g==; X-IronPort-AV: E=McAfee;i="6200,9189,10240"; a="245912884" X-IronPort-AV: E=Sophos;i="5.88,322,1635231600"; d="scan'208";a="245912884" Received: from fmsmga008.fm.intel.com ([10.253.24.58]) by fmsmga104.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Jan 2022 23:48:50 -0800 X-IronPort-AV: E=Sophos;i="5.88,322,1635231600"; d="scan'208";a="581776906" Received: from lahna.fi.intel.com (HELO lahna) ([10.237.72.162]) by fmsmga008-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 27 Jan 2022 23:48:43 -0800 Received: by lahna (sSMTP sendmail emulation); Fri, 28 Jan 2022 09:48:41 +0200 Date: Fri, 28 Jan 2022 09:48:41 +0200 From: Mika Westerberg To: Rajat Jain Cc: "Rafael J. Wysocki" , Greg Kroah-Hartman , Bjorn Helgaas , Len Brown , Bjorn Helgaas , ACPI Devel Maling List , Linux PCI , Linux Kernel Mailing List , Rajat Jain , Dmitry Torokhov , Jesse Barnes , Jean-Philippe Brucker , Pavel Machek , Oliver O'Halloran , Joerg Roedel Subject: Re: [PATCH] PCI: ACPI: Allow internal devices to be marked as untrusted Message-ID: References: <20220120000409.2706549-1-rajatja@google.com> <20220121214117.GA1154852@bhelgaas> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On Thu, Jan 27, 2022 at 02:26:07PM -0800, Rajat Jain wrote: > Hello Rafael, Bjorn, Mika, Dmitry, Greg, > > Thanks a lot for your comments. > > On Tue, Jan 25, 2022 at 6:45 AM Rafael J. Wysocki wrote: > > > > On Tue, Jan 25, 2022 at 1:55 PM Mika Westerberg > > wrote: > > > > > > On Tue, Jan 25, 2022 at 12:15:02PM +0100, Greg Kroah-Hartman wrote: > > > > On Tue, Jan 25, 2022 at 12:58:52PM +0200, Mika Westerberg wrote: > > > > > On Mon, Jan 24, 2022 at 08:27:17AM +0200, Mika Westerberg wrote: > > > > > > > > This patch introduces a new "UntrustedDevice" property that can be used > > > > > > > > by the firmware to mark any device as untrusted. > > > > > > > > > > > > I think this new property should be documented somewhere too (also > > > > > > explain when to use it instead of ExternalFacingPort). If not in the > > > > > > next ACPI spec or some supplemental doc then perhaps in the DT bindings > > > > > > under Documentation/devicetree/bindings. > > > > > > > > > > Actually Microsoft has similar already: > > > > > > > > > > https://docs.microsoft.com/en-us/windows-hardware/drivers/pci/dsd-for-pcie-root-ports#identifying-internal-pcie-ports-accessible-to-users-and-requiring-dma-protection > > > > > > > > > > I think we should use that too here. > > But because this property also applies to a root port (only), it only > helps if the device is downstream a PCIe root port. In our case, we > have an internal (wifi) device 00:14.3 (sits on the internal PCI bus > 0), so cannot use this. Right. I wonder if we can expand it to cover all internal devices, not just PCIe root ports? We anyways need to support that property so does not make much sense to me to invent yet another that does pretty much the same thing.