Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1543980
| From | Lukas Wunner <lukas@wunner.de> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH v3 2/7] PCI: Allow runtime PM on Thunderbolt ports |
| Date | 2016-12-17 15:50 +0100 |
| Message-ID | <sPotb-2qh-5@gated-at.bofh.it> (permalink) |
| References | <sPojw-2mJ-25@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
Currently PCIe ports are only allowed to go to D3 if the BIOS is dated
2015 or newer to avoid potential issues with old chipsets. However for
Thunderbolt we know that even the oldest controller, Light Ridge (2010),
is able to suspend its ports to D3 just fine.
We're about to add runtime PM for Thunderbolt on the Mac. Apple has
released two EFI security updates in 2015 which encompass all machines
with Thunderbolt, but the achieved power saving should be made available
to users even if they haven't updated their BIOS. To this end,
special-case Thunderbolt in pci_bridge_d3_possible().
This allows the Thunderbolt controller to power down but the root port
to which the Thunderbolt controller is attached remains in D0 unless
the EFI update is installed. Users can pass pcie_port_pm=force on the
kernel command line if they cannot install the EFI update but still want
to benefit from the additional power saving of putting the root port
into D3. In practice, root ports can be suspended to D3 without issues
at least on 2012 Ivy Bridge machines.
If the BIOS cut-off date is ever lowered to 2010, the Thunderbolt
special case can be removed.
Cc: Mika Westerberg <mika.westerberg@linux.intel.com>
Cc: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Cc: Andreas Noever <andreas.noever@gmail.com>
Cc: Tomas Winkler <tomas.winkler@intel.com>
Cc: Amir Levy <amir.jer.levy@intel.com>
Signed-off-by: Lukas Wunner <lukas@wunner.de>
---
drivers/pci/pci.c | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c
index a881c0d..8ed098d 100644
--- a/drivers/pci/pci.c
+++ b/drivers/pci/pci.c
@@ -2224,7 +2224,7 @@ void pci_config_pm_runtime_put(struct pci_dev *pdev)
* @bridge: Bridge to check
*
* This function checks if it is possible to move the bridge to D3.
- * Currently we only allow D3 for recent enough PCIe ports.
+ * Currently we only allow D3 for recent enough PCIe ports and Thunderbolt.
*/
bool pci_bridge_d3_possible(struct pci_dev *bridge)
{
@@ -2258,6 +2258,11 @@ bool pci_bridge_d3_possible(struct pci_dev *bridge)
year >= 2015) {
return true;
}
+
+ /* Even the oldest 2010 Thunderbolt controller supports D3. */
+ if (bridge->is_thunderbolt)
+ return true;
+
break;
}
--
2.10.2
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH v3 0/7] Runtime PM for Thunderbolt on Macs Lukas Wunner <lukas@wunner.de> - 2016-12-17 15:40 +0100
[PATCH v3 5/7] PM: Make requirements of dev_pm_domain_set() more precise Lukas Wunner <lukas@wunner.de> - 2016-12-17 15:50 +0100
[PATCH v3 4/7] Revert "PM / Runtime: Remove the exported function pm_children_suspended()" Lukas Wunner <lukas@wunner.de> - 2016-12-17 15:50 +0100
[PATCH v3 6/7] thunderbolt: Power down controller when idle Lukas Wunner <lukas@wunner.de> - 2016-12-17 15:50 +0100
Re: [PATCH v3 6/7] thunderbolt: Power down controller when idle Andy Shevchenko <andy.shevchenko@gmail.com> - 2016-12-19 00:10 +0100
Re: [PATCH v3 6/7] thunderbolt: Power down controller when idle Lukas Wunner <lukas@wunner.de> - 2016-12-20 12:30 +0100
Re: [PATCH v3 6/7] thunderbolt: Power down controller when idle Andy Shevchenko <andy.shevchenko@gmail.com> - 2016-12-20 14:50 +0100
Re: [PATCH v3 6/7] thunderbolt: Power down controller when idle Lukas Wunner <lukas@wunner.de> - 2016-12-21 12:00 +0100
[PATCH v3 2/7] PCI: Allow runtime PM on Thunderbolt ports Lukas Wunner <lukas@wunner.de> - 2016-12-17 15:50 +0100
[PATCH v3 7/7] thunderbolt: Runtime suspend NHI when idle Lukas Wunner <lukas@wunner.de> - 2016-12-17 15:50 +0100
[PATCH v3 1/7] PCI: Recognize Thunderbolt devices Lukas Wunner <lukas@wunner.de> - 2016-12-17 15:50 +0100
[PATCH v3 3/7] PCI: Don't block runtime PM for Thunderbolt host hotplug ports Lukas Wunner <lukas@wunner.de> - 2016-12-17 15:50 +0100
csiph-web