lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2d1d297c-e252-98df-bf96-d6630dd9a423@ti.com>
Date:   Mon, 13 Jul 2020 10:50:29 -0500
From:   Dan Murphy <dmurphy@...com>
To:     Andrew Lunn <andrew@...n.ch>
CC:     <f.fainelli@...il.com>, <hkallweit1@...il.com>,
        <davem@...emloft.net>, <robh@...nel.org>, <netdev@...r.kernel.org>,
        <linux-kernel@...r.kernel.org>, <devicetree@...r.kernel.org>
Subject: Re: [PATCH net-next v2 2/2] net: phy: DP83822: Add ability to
 advertise Fiber connection

Andrew

On 7/11/20 1:54 PM, Andrew Lunn wrote:
>> @@ -302,6 +357,48 @@ static int dp83822_config_init(struct phy_device *phydev)
>>   		}
>>   	}
>>   
>> +	if (dp83822->fx_enabled) {
>> +		err = phy_modify(phydev, MII_DP83822_CTRL_2,
>> +				 DP83822_FX_ENABLE, 1);
>> +		if (err < 0)
>> +			return err;
>> +
>> +		linkmode_set_bit(ETHTOOL_LINK_MODE_FIBRE_BIT,
>> +				 phydev->supported);
>> +		linkmode_set_bit(ETHTOOL_LINK_MODE_FIBRE_BIT,
>> +				 phydev->advertising);
>> +
>> +		/* Auto neg is not supported in fiber mode */
>> +		bmcr = phy_read(phydev, MII_BMCR);
>> +		if (bmcr < 0)
>> +			return bmcr;
>> +
>> +		if (bmcr & BMCR_ANENABLE) {
>> +			err =  phy_modify(phydev, MII_BMCR, BMCR_ANENABLE, 0);
>> +			if (err < 0)
>> +				return err;
>> +		}
>> +		phydev->autoneg = AUTONEG_DISABLE;
> You should also be removing ETHTOOL_LINK_MODE_Autoneg_BIT from
> phydev->supported, to make it clear autoneg is not supported. Assuming
> genphy_read_abilities() cannot figure this out for itself.

In our testing we are finding that it cannot determine that for itself 
so I will have to clear the bit.

Dan

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ