tree 883fa60cf8087f720e8c810ba29ba034a1de0f48
parent 314fba348e1f64a30b53d3cff5d96872424e8498
author Michael Chan <[EMAIL PROTECTED]> Fri, 22 Apr 2005 07:09:08 -0700
committer David S. Miller <[EMAIL PROTECTED]> Fri, 22 Apr 2005 07:09:08 -0700
[TG3]: Fix tg3_set_power_state()
Fix tg3_set_power_state to drive GPIOs properly based on the
TG3_FLAG_EEPROM_WRITE_PROTECT flag. Some delays are also added after D0
and D3 power state changes.
Signed-off-by: Michael Chan <[EMAIL PROTECTED]>
Signed-off-by: David S. Miller <[EMAIL PROTECTED]>
net/tg3.c | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
Index: drivers/net/tg3.c
===================================================================
--- 0f167465d14b4d8e6170097651eced60ab48be95/drivers/net/tg3.c (mode:100644
sha1:742340aebf7e6f6c405516a6cc8249ae08ccdf79)
+++ 883fa60cf8087f720e8c810ba29ba034a1de0f48/drivers/net/tg3.c (mode:100644
sha1:f0b5dc7766bb5b1fd27ee977652b62b8c113a86e)
@@ -1005,8 +1005,13 @@ static int tg3_set_power_state(struct tg
pci_write_config_word(tp->pdev,
pm + PCI_PM_CTRL,
power_control);
- tw32_f(GRC_LOCAL_CTRL, tp->grc_local_ctrl);
- udelay(100);
+ udelay(100); /* Delay after power state change */
+
+ /* Switch out of Vaux if it is not a LOM */
+ if (!(tp->tg3_flags & TG3_FLAG_EEPROM_WRITE_PROT)) {
+ tw32_f(GRC_LOCAL_CTRL, tp->grc_local_ctrl);
+ udelay(100);
+ }
return 0;
@@ -1151,6 +1156,7 @@ static int tg3_set_power_state(struct tg
/* Finally, set the new power state. */
pci_write_config_word(tp->pdev, pm + PCI_PM_CTRL, power_control);
+ udelay(100); /* Delay after power state change */
tg3_write_sig_post_reset(tp, RESET_KIND_SHUTDOWN);
-
To unsubscribe from this list: send the line "unsubscribe bk-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html