lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ZstGP0EgttNAxjp2@wunner.de>
Date: Sun, 25 Aug 2024 16:57:03 +0200
From: Lukas Wunner <lukas@...ner.de>
To: Bjorn Helgaas <helgaas@...nel.org>
Cc: Esther Shimanovich <eshimanovich@...omium.org>,
	Bjorn Helgaas <bhelgaas@...gle.com>,
	Rajat Jain <rajatja@...gle.com>,
	"Rafael J. Wysocki" <rafael.j.wysocki@...el.com>,
	Mika Westerberg <mika.westerberg@...ux.intel.com>,
	linux-pci@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] PCI: Detect and trust built-in TBT chips

On Tue, Aug 06, 2024 at 05:04:06PM -0500, Bjorn Helgaas wrote:
> On Tue, Aug 06, 2024 at 09:39:11PM +0000, Esther Shimanovich wrote:
> > Some computers with CPUs that lack Thunderbolt features use discrete
> > Thunderbolt chips to add Thunderbolt functionality. These Thunderbolt
> > chips are located within the chassis; between the root port labeled
> > ExternalFacingPort and the USB-C port.
> 
> So is this fundamentally a firmware defect?  ACPI says a Root Port is
> an "ExternalFacingPort", but the Root Port is actually connected to an
> internal Thunderbolt chip, not an external connector?

We're the victim of an ambiguity in Microsoft's spec here:

The spec says that ExternalFacingPort is used to identify externally
exposed PCIe hierarchies.  But the spec mandates that the property
shall only exist under the Root Port ACPI device scope.

OEMs follow that spec to a T by specifying ExternalFacingPort below
the Root Port, even though the Root Port itself is not external facing
but connects to a discrete Thunderbolt controller which is soldered down
to the mainboard.  In reality the external facing ports extend from the
discrete controller, but Microsoft's spec doesn't allow marking them
as such.

Here's the relevant spec language:

   "This ACPI object enables the operating system to identify externally
    exposed PCIe hierarchies, such as Thunderbolt. This object must be
    implemented in the Root Port ACPI device scope.

    Note: On systems shipping with Windows 10, version 1803, this object
    should only be implemented on PCIe Root Ports of Thunderbolt hierarchies."

    https://learn.microsoft.com/en-us/windows-hardware/drivers/pci/dsd-for-pcie-root-ports#identifying-externally-exposed-pcie-root-ports

It's probably safe to assume that Microsoft intended the ExternalFacingPort
property to only be used on SoC-integrated Thunderbolt controllers,
in which case a Root Port is indeed external facing.  But that didn't
stop OEMs from also specifying the property on Root Ports above
soldered-down discrete Thunderbolt controllers.  The spec doesn't
explicitly forbid that.

Thanks,

Lukas

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ