]> pilppa.com Git - linux-2.6-omap-h63xx.git/commitdiff
sfc: Restore phy_flash_cfg module parameter
authorBen Hutchings <bhutchings@solarflare.com>
Sat, 13 Dec 2008 05:34:54 +0000 (21:34 -0800)
committerDavid S. Miller <davem@davemloft.net>
Sat, 13 Dec 2008 05:57:44 +0000 (21:57 -0800)
This is needed for recovery in case a PHY firmware upgrade is aborted.

Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/sfc/efx.c

index 127b4da0a5e7645e00d29e3dce14693cb74ee94e..15ae2fcf64169a74d4165dd66c0c0868577b4728 100644 (file)
@@ -129,6 +129,10 @@ static unsigned int rss_cpus;
 module_param(rss_cpus, uint, 0444);
 MODULE_PARM_DESC(rss_cpus, "Number of CPUs to use for Receive-Side Scaling");
 
+static int phy_flash_cfg;
+module_param(phy_flash_cfg, int, 0644);
+MODULE_PARM_DESC(phy_flash_cfg, "Set PHYs into reflash mode initially");
+
 /**************************************************************************
  *
  * Utility functions and prototypes
@@ -609,6 +613,9 @@ static int efx_probe_port(struct efx_nic *efx)
        if (rc)
                goto err;
 
+       if (phy_flash_cfg)
+               efx->phy_mode = PHY_MODE_SPECIAL;
+
        /* Sanity check MAC address */
        if (is_valid_ether_addr(efx->mac_address)) {
                memcpy(efx->net_dev->dev_addr, efx->mac_address, ETH_ALEN);