netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Kok, Auke" <auke-jan.h.kok@intel.com>
To: "Garzik, Jeff" <jgarzik@pobox.com>,
	netdev@vger.kernel.org, "Miller, David" <davem@davemloft.net>
Cc: "Ronciak, John" <john.ronciak@intel.com>,
	"Brandeburg, Jesse" <jesse.brandeburg@intel.com>,
	"Kirsher, Jeff" <Jeffrey.t.kirsher@intel.com>,
	"Kok, Auke" <auke@foo-projects.org>
Subject: [PATCH 01/10] e1000: Remove PM warning DPRINTKs breaking 2.4.x kernels
Date: Fri, 14 Apr 2006 11:36:49 -0700	[thread overview]
Message-ID: <20060414183649.3461.54520.stgit@gitlost.site> (raw)
In-Reply-To: <20060414183423.3461.32772.stgit@gitlost.site>


remove DPRINTKs that were printing warnings about power management on
2.4 kernels.  Since we really don't react differently these printk
statements are not needed.  This code was originally added to fix
some compile time warnings that got fixed by newer kernels.


Signed-off-by: Jesse Brandeburg <jesse.brandeburg@intel.com>
Signed-off-by: Auke Kok <auke-jan.h.kok@intel.com>
Signed-off-by: John Ronciak <john.ronciak@intel.com>
---

 drivers/net/e1000/e1000_main.c |   42 ++++++++++------------------------------
 1 files changed, 10 insertions(+), 32 deletions(-)

diff --git a/drivers/net/e1000/e1000_main.c b/drivers/net/e1000/e1000_main.c
index add8dc4..ac1e838 100644
--- a/drivers/net/e1000/e1000_main.c
+++ b/drivers/net/e1000/e1000_main.c
@@ -4515,21 +4515,13 @@ e1000_suspend(struct pci_dev *pdev, pm_m
 
 		E1000_WRITE_REG(&adapter->hw, WUC, E1000_WUC_PME_EN);
 		E1000_WRITE_REG(&adapter->hw, WUFC, wufc);
-		retval = pci_enable_wake(pdev, PCI_D3hot, 1);
-		if (retval)
-			DPRINTK(PROBE, ERR, "Error enabling D3 wake\n");
-		retval = pci_enable_wake(pdev, PCI_D3cold, 1);
-		if (retval)
-			DPRINTK(PROBE, ERR, "Error enabling D3 cold wake\n");
+		pci_enable_wake(pdev, PCI_D3hot, 1);
+		pci_enable_wake(pdev, PCI_D3cold, 1);
 	} else {
 		E1000_WRITE_REG(&adapter->hw, WUC, 0);
 		E1000_WRITE_REG(&adapter->hw, WUFC, 0);
-		retval = pci_enable_wake(pdev, PCI_D3hot, 0);
-		if (retval)
-			DPRINTK(PROBE, ERR, "Error enabling D3 wake\n");
-		retval = pci_enable_wake(pdev, PCI_D3cold, 0);
-		if (retval)
-			DPRINTK(PROBE, ERR, "Error enabling D3 cold wake\n");
+		pci_enable_wake(pdev, PCI_D3hot, 0);
+		pci_enable_wake(pdev, PCI_D3cold, 0);
 	}
 
 	if (adapter->hw.mac_type >= e1000_82540 &&
@@ -4538,13 +4530,8 @@ e1000_suspend(struct pci_dev *pdev, pm_m
 		if (manc & E1000_MANC_SMBUS_EN) {
 			manc |= E1000_MANC_ARP_EN;
 			E1000_WRITE_REG(&adapter->hw, MANC, manc);
-			retval = pci_enable_wake(pdev, PCI_D3hot, 1);
-			if (retval)
-				DPRINTK(PROBE, ERR, "Error enabling D3 wake\n");
-			retval = pci_enable_wake(pdev, PCI_D3cold, 1);
-			if (retval)
-				DPRINTK(PROBE, ERR,
-				        "Error enabling D3 cold wake\n");
+			pci_enable_wake(pdev, PCI_D3hot, 1);
+			pci_enable_wake(pdev, PCI_D3cold, 1);
 		}
 	}
 
@@ -4554,9 +4541,7 @@ e1000_suspend(struct pci_dev *pdev, pm_m
 
 	pci_disable_device(pdev);
 
-	retval = pci_set_power_state(pdev, pci_choose_state(pdev, state));
-	if (retval)
-		DPRINTK(PROBE, ERR, "Error in setting power state\n");
+	pci_set_power_state(pdev, pci_choose_state(pdev, state));
 
 	return 0;
 }
@@ -4567,22 +4552,15 @@ e1000_resume(struct pci_dev *pdev)
 {
 	struct net_device *netdev = pci_get_drvdata(pdev);
 	struct e1000_adapter *adapter = netdev_priv(netdev);
-	int retval;
 	uint32_t manc, ret_val;
 
-	retval = pci_set_power_state(pdev, PCI_D0);
-	if (retval)
-		DPRINTK(PROBE, ERR, "Error in setting power state\n");
+	pci_set_power_state(pdev, PCI_D0);
 	e1000_pci_restore_state(adapter);
 	ret_val = pci_enable_device(pdev);
 	pci_set_master(pdev);
 
-	retval = pci_enable_wake(pdev, PCI_D3hot, 0);
-	if (retval)
-		DPRINTK(PROBE, ERR, "Error enabling D3 wake\n");
-	retval = pci_enable_wake(pdev, PCI_D3cold, 0);
-	if (retval)
-		DPRINTK(PROBE, ERR, "Error enabling D3 cold wake\n");
+	pci_enable_wake(pdev, PCI_D3hot, 0);
+	pci_enable_wake(pdev, PCI_D3cold, 0);
 
 	e1000_reset(adapter);
 	E1000_WRITE_REG(&adapter->hw, WUS, ~0);



--
Auke Kok <auke-jan.h.kok@intel.com>
Intel Pro Ethernet Driver Group
LAN Access Division / Digital Enterprise Group 

  reply	other threads:[~2006-04-14 18:33 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-04-14 18:34 [PATCH 00/10] e1000: Driver fixes and update to 7.0.38-k2 Kok, Auke
2006-04-14 18:36 ` Kok, Auke [this message]
2006-04-14 18:36 ` [PATCH 02/10] e1000: Esb2 wol link cycle bug and uninitialized registers Kok, Auke
2006-04-14 18:36 ` [PATCH 03/10] e1000: De-inline functions to benefit from compiler smartness Kok, Auke
2006-04-14 18:36 ` [PATCH 04/10] e1000: Made an adapter struct variable into a local (txb2b) Kok, Auke
2006-04-14 18:36 ` [PATCH 05/10] e1000: Update truesize with the length of the packet for packet split Kok, Auke
2006-04-14 21:16   ` Jeff Garzik
2006-04-14 22:13     ` Jesse Brandeburg
2006-04-14 22:32       ` David S. Miller
2006-04-14 22:43         ` Jesse Brandeburg
2006-04-14 22:51           ` David S. Miller
2006-04-14 23:04             ` Jesse Brandeburg
2006-04-14 23:45               ` David S. Miller
2006-04-14 23:52                 ` Jesse Brandeburg
2006-04-14 18:37 ` [PATCH 06/10] e1000: Dead variable cleanup Kok, Auke
2006-04-14 18:37 ` [PATCH 07/10] e1000: Buffer optimizations for small MTU Kok, Auke
2006-04-14 18:37 ` [PATCH 08/10] e1000: implement more efficient tx queue locking Kok, Auke
2006-04-14 18:37 ` [PATCH 09/10] e1000: Version bump, contact fix, year string change Kok, Auke
2006-04-14 18:37 ` [PATCH 10/10] {e100{,0},ixgb}: Add Auke Kok as new patch maintainer for e{100,1000} and ixgb Kok, Auke
2006-04-14 19:01 ` [PATCH 00/10] e1000: Driver fixes and update to 7.0.38-k2 Jeff Garzik
2006-04-14 19:32   ` Auke Kok
2006-04-22  5:22   ` Herbert Xu
2006-04-23  5:53     ` David S. Miller
2006-04-23 14:13       ` Auke Kok

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20060414183649.3461.54520.stgit@gitlost.site \
    --to=auke-jan.h.kok@intel.com \
    --cc=Jeffrey.t.kirsher@intel.com \
    --cc=auke@foo-projects.org \
    --cc=davem@davemloft.net \
    --cc=jesse.brandeburg@intel.com \
    --cc=jgarzik@pobox.com \
    --cc=john.ronciak@intel.com \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).