Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 2a7e637d authored by Ben Hutchings's avatar Ben Hutchings Committed by David S. Miller
Browse files

sfc: SFT9001: Fix condition for LNPGA power-off



Only the SFX7101 requires software power control.  This was
incorrectly being applied to the SFT9001 rev A as well.

Signed-off-by: default avatarBen Hutchings <bhutchings@solarflare.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 4dbc242e
Loading
Loading
Loading
Loading
+3 −2
Original line number Original line Diff line number Diff line
@@ -636,10 +636,11 @@ static void tenxpress_phy_fini(struct efx_nic *efx)
{
{
	int reg;
	int reg;


	if (efx->phy_type == PHY_TYPE_SFT9001B) {
	if (efx->phy_type == PHY_TYPE_SFT9001B)
		device_remove_file(&efx->pci_dev->dev,
		device_remove_file(&efx->pci_dev->dev,
				   &dev_attr_phy_short_reach);
				   &dev_attr_phy_short_reach);
	} else {

	if (efx->phy_type == PHY_TYPE_SFX7101) {
		/* Power down the LNPGA */
		/* Power down the LNPGA */
		reg = (1 << PMA_PMD_LNPGA_POWERDOWN_LBN);
		reg = (1 << PMA_PMD_LNPGA_POWERDOWN_LBN);
		mdio_clause45_write(efx, efx->mii.phy_id, MDIO_MMD_PMAPMD,
		mdio_clause45_write(efx, efx->mii.phy_id, MDIO_MMD_PMAPMD,