Skip to contentSkip to conversation

sky2: phy power problems on 88e805X chips

PATCH Applied Stephen Hemminger 2 participants 2 messages Aug 9, 2006 – Aug 10, 2006

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 sky2: phy power problems on 88e805X chips

On the 88E805X chipsets (used in laptops), the PHY was not getting powered out of shutdown properly. The variable reg1 was getting reused incorrectly. This is probably the cause of the bug.

	http://bugzilla.kernel.org/show_bug.cgi?id=6471
drivers/net/sky2.c +2 -3
@@ -233,6 +233,8 @@
 			if (hw->ports > 1)
 				reg1 |= PCI_Y2_PHY2_COMA;
 		}
+		sky2_pci_write32(hw, PCI_DEV_REG1, reg1);
+		udelay(100);
 
 		if (hw->chip_id == CHIP_ID_YUKON_EC_U) {
 			sky2_pci_write32(hw, PCI_DEV_REG3, 0);
@@ -242,9 +244,6 @@
 			sky2_pci_write32(hw, PCI_DEV_REG5, 0);
 		}
 
-		sky2_pci_write32(hw, PCI_DEV_REG1, reg1);
-		udelay(100);
-
 		break;
 
 	case PCI_D3hot:
Applied
#1 lore raw
Quoted 10 lines · Stephen Hemminger

On the 88E805X chipsets (used in laptops), the PHY was not getting powered out of shutdown properly. The variable reg1 was getting reused incorrectly. This is probably the cause of the bug.

	http://bugzilla.kernel.org/show_bug.cgi?id=6471

drivers/net/sky2.c line 239

Quoted 7 lines
drivers/net/sky2.c +2 -0
@@ -233,6 +233,8 @@
 			if (hw->ports > 1)
 				reg1 |= PCI_Y2_PHY2_COMA;
 		}
+		sky2_pci_write32(hw, PCI_DEV_REG1, reg1);
+		udelay(100);
 
 		if (hw->chip_id == CHIP_ID_YUKON_EC_U) {

applied to #upstream-fixes, though I note that the obvious PCI posting bug remains.

You cannot be assured that the udelay(100) is truly effective without a flushing readl().

Jeff