* [PATCH 1/6] net/ethernet/atl1c: Disable ASPM on various chipsets
[not found] <1321027511-31229-1-git-send-email-mjg@redhat.com>
@ 2011-11-11 16:05 ` Matthew Garrett
2011-11-11 16:05 ` [PATCH 2/6] net/ethernet/atl1e: Disable ASPM Matthew Garrett
2011-11-11 16:05 ` [PATCH 3/6] net/ethernet/jme: " Matthew Garrett
2 siblings, 0 replies; 3+ messages in thread
From: Matthew Garrett @ 2011-11-11 16:05 UTC (permalink / raw)
To: linux-kernel; +Cc: Matthew Garrett, netdev, jcliburn, chris.snook
The Windows driver disables ASPM support for various chipsets supported
by atl1c. This adds the same set of logic to the Linux driver. ASPM is
disabled on l1c, l2c, l2cb and l2cb2 devices except for those in Toshiba
or Lenovo devices. Data taken from
http://www.atheros.cz/atheros-inf-file.php?inf=199&chipset=51&system=6
Signed-off-by: Matthew Garrett <mjg@redhat.com>
Cc: netdev@vger.kernel.org
Cc: jcliburn@gmail.com
Cc: chris.snook@gmail.com
---
drivers/net/ethernet/atheros/atl1c/atl1c_main.c | 15 +++++++++++++++
1 files changed, 15 insertions(+), 0 deletions(-)
diff --git a/drivers/net/ethernet/atheros/atl1c/atl1c_main.c b/drivers/net/ethernet/atheros/atl1c/atl1c_main.c
index 02c7ed8..d91dabd 100644
--- a/drivers/net/ethernet/atheros/atl1c/atl1c_main.c
+++ b/drivers/net/ethernet/atheros/atl1c/atl1c_main.c
@@ -19,6 +19,7 @@
* Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
+#include <linux/pci-aspm.h>
#include "atl1c.h"
#define ATL1C_DRV_VERSION "1.0.1.0-NAPI"
@@ -2652,6 +2653,20 @@ static int __devinit atl1c_probe(struct pci_dev *pdev,
int err = 0;
+ switch (pdev->device) {
+ case PCI_DEVICE_ID_ATTANSIC_L1C:
+ case PCI_DEVICE_ID_ATTANSIC_L2C:
+ case PCI_DEVICE_ID_ATHEROS_L2C_B:
+ case PCI_DEVICE_ID_ATHEROS_L2C_B2:
+ if (pdev->subsystem_vendor == PCI_VENDOR_ID_TOSHIBA ||
+ pdev->subsystem_vendor == PCI_VENDOR_ID_LENOVO)
+ break;
+ pci_disable_link_state(pdev, PCIE_LINK_STATE_L0S |
+ PCIE_LINK_STATE_L1 |
+ PCIE_LINK_STATE_CLKPM);
+ break;
+ }
+
/* enable device (incl. PCI PM wakeup and hotplug setup) */
err = pci_enable_device_mem(pdev);
if (err) {
--
1.7.7.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH 2/6] net/ethernet/atl1e: Disable ASPM
[not found] <1321027511-31229-1-git-send-email-mjg@redhat.com>
2011-11-11 16:05 ` [PATCH 1/6] net/ethernet/atl1c: Disable ASPM on various chipsets Matthew Garrett
@ 2011-11-11 16:05 ` Matthew Garrett
2011-11-11 16:05 ` [PATCH 3/6] net/ethernet/jme: " Matthew Garrett
2 siblings, 0 replies; 3+ messages in thread
From: Matthew Garrett @ 2011-11-11 16:05 UTC (permalink / raw)
To: linux-kernel; +Cc: Matthew Garrett, netdev, jcliburn, chris.snook
http://www.atheros.cz/atheros-inf-file.php?inf=209&chipset=45&system=6
indicates that ASPM is disabled on all L1E hardware. Duplicate for sanity.
Signed-off-by: Matthew Garrett <mjg@redhat.com>
Cc: netdev@vger.kernel.org
Cc: jcliburn@gmail.com
Cc: chris.snook@gmail.com
---
drivers/net/ethernet/atheros/atl1e/atl1e_main.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/drivers/net/ethernet/atheros/atl1e/atl1e_main.c b/drivers/net/ethernet/atheros/atl1e/atl1e_main.c
index 95483bc..fc74dd1 100644
--- a/drivers/net/ethernet/atheros/atl1e/atl1e_main.c
+++ b/drivers/net/ethernet/atheros/atl1e/atl1e_main.c
@@ -2264,6 +2264,9 @@ static int __devinit atl1e_probe(struct pci_dev *pdev,
int err = 0;
+ pci_disable_link_state(pdev, PCIE_LINK_STATE_L0S | PCIE_LINK_STATE_L1 |
+ PCIE_LINK_STATE_CLKPM);
+
err = pci_enable_device(pdev);
if (err) {
dev_err(&pdev->dev, "cannot enable PCI device\n");
--
1.7.7.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH 3/6] net/ethernet/jme: Disable ASPM
[not found] <1321027511-31229-1-git-send-email-mjg@redhat.com>
2011-11-11 16:05 ` [PATCH 1/6] net/ethernet/atl1c: Disable ASPM on various chipsets Matthew Garrett
2011-11-11 16:05 ` [PATCH 2/6] net/ethernet/atl1e: Disable ASPM Matthew Garrett
@ 2011-11-11 16:05 ` Matthew Garrett
2 siblings, 0 replies; 3+ messages in thread
From: Matthew Garrett @ 2011-11-11 16:05 UTC (permalink / raw)
To: linux-kernel; +Cc: Matthew Garrett, netdev, cooldavid
http://driveragent.com/archive/30421/7-0-14 indicates that ASPM is
disabled on the 250 and 260. Duplicate for sanity.
Signed-off-by: Matthew Garrett <mjg@redhat.com>
Cc: netdev@vger.kernel.org
Cc: cooldavid@cooldavid.org
---
drivers/net/ethernet/jme.c | 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/drivers/net/ethernet/jme.c b/drivers/net/ethernet/jme.c
index 7becff1..b28a873 100644
--- a/drivers/net/ethernet/jme.c
+++ b/drivers/net/ethernet/jme.c
@@ -2860,6 +2860,9 @@ jme_init_one(struct pci_dev *pdev,
/*
* set up PCI device basics
*/
+ pci_disable_link_state(pdev, PCIE_LINK_STATE_L0S | PCIE_LINK_STATE_L1 |
+ PCIE_LINK_STATE_CLKPM);
+
rc = pci_enable_device(pdev);
if (rc) {
pr_err("Cannot enable PCI device\n");
--
1.7.7.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-11-11 16:05 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <1321027511-31229-1-git-send-email-mjg@redhat.com>
2011-11-11 16:05 ` [PATCH 1/6] net/ethernet/atl1c: Disable ASPM on various chipsets Matthew Garrett
2011-11-11 16:05 ` [PATCH 2/6] net/ethernet/atl1e: Disable ASPM Matthew Garrett
2011-11-11 16:05 ` [PATCH 3/6] net/ethernet/jme: " Matthew Garrett
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).