Re: [PATCH net-next v2 1/3] net: dsa: use slave device phydev

2017-09-22 Thread Vivien Didelot
Hi Florian, Florian Fainelli writes: > On 09/22/2017 12:40 PM, Vivien Didelot wrote: >> There is no need to store a phy_device in dsa_slave_priv since >> net_device already provides one. Simply s/p->phy/dev->phydev/. > > You can therefore remove the phy_device from dsa_slave_priv, see below > fo

Re: [PATCH net-next v2 1/3] net: dsa: use slave device phydev

2017-09-22 Thread Andrew Lunn
On Fri, Sep 22, 2017 at 03:40:43PM -0400, Vivien Didelot wrote: > There is no need to store a phy_device in dsa_slave_priv since > net_device already provides one. Simply s/p->phy/dev->phydev/. > > While at it, return -ENODEV when it is NULL instead of -EOPNOTSUPP. I just did a quick poll for cal

Re: [PATCH net-next v2 1/3] net: dsa: use slave device phydev

2017-09-22 Thread Florian Fainelli
On 09/22/2017 12:40 PM, Vivien Didelot wrote: > There is no need to store a phy_device in dsa_slave_priv since > net_device already provides one. Simply s/p->phy/dev->phydev/. You can therefore remove the phy_device from dsa_slave_priv, see below for more comments. I will have to regress test the

[PATCH net-next v2 1/3] net: dsa: use slave device phydev

2017-09-22 Thread Vivien Didelot
There is no need to store a phy_device in dsa_slave_priv since net_device already provides one. Simply s/p->phy/dev->phydev/. While at it, return -ENODEV when it is NULL instead of -EOPNOTSUPP. Signed-off-by: Vivien Didelot --- net/dsa/slave.c | 126 ++---