mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-29 01:59:02 +00:00
6d2136c3f2
Without this patch we treated only phy addr 30 as an external phy, but there is a register to check that. Now we do not have to try to reset the switch to check for an external switch. Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de> SVN-Revision: 38502
26 lines
858 B
Diff
26 lines
858 B
Diff
From c2ecc401a08f0bda3b2483b93989d9792cadf6b2 Mon Sep 17 00:00:00 2001
|
|
From: Hauke Mehrtens <hauke@hauke-m.de>
|
|
Date: Mon, 21 Oct 2013 20:30:04 +0200
|
|
Subject: [PATCH 8/9] b44: do not set phy addr to 30 for every ext phy
|
|
|
|
---
|
|
drivers/net/ethernet/broadcom/b44.c | 7 +++++--
|
|
1 file changed, 5 insertions(+), 2 deletions(-)
|
|
|
|
--- a/drivers/net/ethernet/broadcom/b44.c
|
|
+++ b/drivers/net/ethernet/broadcom/b44.c
|
|
@@ -2408,8 +2408,11 @@ static int b44_init_one(struct ssb_devic
|
|
b44_chip_reset(bp, B44_CHIP_RESET_FULL);
|
|
|
|
/* do a phy reset to test if there is an active phy */
|
|
- if (b44_phy_reset(bp) < 0)
|
|
- bp->phy_addr = B44_PHY_ADDR_NO_LOACL_PHY;
|
|
+ err = b44_phy_reset(bp);
|
|
+ if (err < 0) {
|
|
+ dev_err(sdev->dev, "phy reset failed\n");
|
|
+ goto err_out_unregister_netdev;
|
|
+ }
|
|
|
|
if (bp->flags & B44_FLAG_EXTERNAL_PHY) {
|
|
err = b44_register_phy_one(bp);
|