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]
Date:   Wed, 04 Sep 2019 20:53:38 +0700
From:   Arseny Solokha <asolokha@...kras.ru>
To:     Vladimir Oltean <olteanv@...il.com>
Cc:     Claudiu Manoil <claudiu.manoil@....com>,
        Russell King <linux@...linux.org.uk>,
        Ioana Ciornei <ioana.ciornei@....com>,
        Andrew Lunn <andrew@...n.ch>, netdev <netdev@...r.kernel.org>,
        Florian Fainelli <f.fainelli@...il.com>
Subject: Re: [RFC PATCH 1/2] gianfar: convert to phylink

Hi,


>> @@ -1964,7 +1966,7 @@ void stop_gfar(struct net_device *dev)
>>         /* disable ints and gracefully shut down Rx/Tx DMA */
>>         gfar_halt(priv);
>>
>> -       phy_stop(dev->phydev);
>> +       phylink_stop(priv->phylink);
>>
>>         free_skb_resources(priv);
>>  }
>> @@ -2219,12 +2221,7 @@ int startup_gfar(struct net_device *ndev)
>>         /* Start Rx/Tx DMA and enable the interrupts */
>>         gfar_start(priv);
>>
>> -       /* force link state update after mac reset */
>> -       priv->oldlink = 0;
>> -       priv->oldspeed = 0;
>> -       priv->oldduplex = -1;
>> -
>> -       phy_start(ndev->phydev);
>> +       phylink_start(priv->phylink);
>>
>>         enable_napi(priv);
>>
>> @@ -2593,7 +2590,7 @@ static int gfar_close(struct net_device *dev)
>>         stop_gfar(dev);
>>
>>         /* Disconnect from the PHY */
>> -       phy_disconnect(dev->phydev);
>> +       phylink_disconnect_phy(priv->phylink);
>
> It is very odd to disconnect from the PHY on ndo_close and connect
> back on ndo_open. I don't know of any other driver that does that.
> Can't you change the behavior to simply start and stop phylink here?

I surely can. But I've just looked at xilinx_axienet, mvneta, mvpp2, and stmmac,
and they all call phylink_stop() and phylink_disconnect_phy() in ndo_stop. What
do you think would justify such a change?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ