diff options
author | Divy Le Ray <divy@chelsio.com> | 2009-05-20 11:56:12 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2009-05-20 23:51:59 -0400 |
commit | 703cebabd173a7fe533d6f21df0347b1f2a9a1e1 (patch) | |
tree | cea9c6a7b8b5a4e733a3b2d6366cdcbbfedc8f49 /drivers/net/chelsio/mv88x201x.c | |
parent | 86c890ab1b183f8f17ce03c24b62c564e95f957f (diff) |
cxgb: set phy's mdio dev before the phy init sequence
mdio's dev field needs to be set before mdio ops occur.
Signed-off-by: Divy Le Ray <divy@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/chelsio/mv88x201x.c')
-rw-r--r-- | drivers/net/chelsio/mv88x201x.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/chelsio/mv88x201x.c b/drivers/net/chelsio/mv88x201x.c index d50907bf2eb..f7136b2fd1e 100644 --- a/drivers/net/chelsio/mv88x201x.c +++ b/drivers/net/chelsio/mv88x201x.c | |||
@@ -209,7 +209,7 @@ static struct cphy_ops mv88x201x_ops = { | |||
209 | MDIO_DEVS_PHYXS | MDIO_DEVS_WIS), | 209 | MDIO_DEVS_PHYXS | MDIO_DEVS_WIS), |
210 | }; | 210 | }; |
211 | 211 | ||
212 | static struct cphy *mv88x201x_phy_create(adapter_t *adapter, int phy_addr, | 212 | static struct cphy *mv88x201x_phy_create(struct net_device *dev, int phy_addr, |
213 | const struct mdio_ops *mdio_ops) | 213 | const struct mdio_ops *mdio_ops) |
214 | { | 214 | { |
215 | u32 val; | 215 | u32 val; |
@@ -218,7 +218,7 @@ static struct cphy *mv88x201x_phy_create(adapter_t *adapter, int phy_addr, | |||
218 | if (!cphy) | 218 | if (!cphy) |
219 | return NULL; | 219 | return NULL; |
220 | 220 | ||
221 | cphy_init(cphy, adapter, phy_addr, &mv88x201x_ops, mdio_ops); | 221 | cphy_init(cphy, dev, phy_addr, &mv88x201x_ops, mdio_ops); |
222 | 222 | ||
223 | /* Commands the PHY to enable XFP's clock. */ | 223 | /* Commands the PHY to enable XFP's clock. */ |
224 | cphy_mdio_read(cphy, MDIO_MMD_PCS, 0x8300, &val); | 224 | cphy_mdio_read(cphy, MDIO_MMD_PCS, 0x8300, &val); |