1
0

071-v4.8-0009-net-bgmac-fix-reversed-check-for-MII-registration-er.patch 1.0 KB

12345678910111213141516171819202122232425262728
  1. From b9f63ae7ba2de2ba19137c5757c0607ce40f3ed5 Mon Sep 17 00:00:00 2001
  2. From: =?UTF-8?q?Rafa=C5=82=20Mi=C5=82ecki?= <rafal@milecki.pl>
  3. Date: Wed, 17 Aug 2016 15:37:14 +0200
  4. Subject: [PATCH] net: bgmac: fix reversed check for MII registration error
  5. MIME-Version: 1.0
  6. Content-Type: text/plain; charset=UTF-8
  7. Content-Transfer-Encoding: 8bit
  8. It was failing on successful registration returning meaningless errors.
  9. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
  10. Fixes: 55954f3bfdac ("net: ethernet: bgmac: move BCMA MDIO Phy code into a separate file")
  11. Signed-off-by: David S. Miller <davem@davemloft.net>
  12. ---
  13. drivers/net/ethernet/broadcom/bgmac-bcma.c | 2 +-
  14. 1 file changed, 1 insertion(+), 1 deletion(-)
  15. --- a/drivers/net/ethernet/broadcom/bgmac-bcma.c
  16. +++ b/drivers/net/ethernet/broadcom/bgmac-bcma.c
  17. @@ -159,7 +159,7 @@ static int bgmac_probe(struct bcma_devic
  18. if (!bgmac_is_bcm4707_family(core)) {
  19. mii_bus = bcma_mdio_mii_register(core, bgmac->phyaddr);
  20. - if (!IS_ERR(mii_bus)) {
  21. + if (IS_ERR(mii_bus)) {
  22. err = PTR_ERR(mii_bus);
  23. goto err;
  24. }