sfc: Fix failure paths in efx_probe_port()
authorBen Hutchings <bhutchings@solarflare.com>
Fri, 10 Sep 2010 06:41:19 +0000 (06:41 +0000)
committerDavid S. Miller <davem@davemloft.net>
Fri, 10 Sep 2010 19:27:30 +0000 (12:27 -0700)
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/sfc/efx.c

index b385f895bf239364c5ca50f86acde165634d7196..a57604527a42c48cd4e00facb27e2ee2ed0071db 100644 (file)
@@ -761,7 +761,7 @@ static int efx_probe_port(struct efx_nic *efx)
        /* Connect up MAC/PHY operations table */
        rc = efx->type->probe_port(efx);
        if (rc)
-               goto err;
+               return rc;
 
        /* Sanity check MAC address */
        if (is_valid_ether_addr(efx->mac_address)) {
@@ -782,7 +782,7 @@ static int efx_probe_port(struct efx_nic *efx)
        return 0;
 
  err:
-       efx_remove_port(efx);
+       efx->type->remove_port(efx);
        return rc;
 }