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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Thu, 8 Sep 2016 14:39:13 +0530
From:   Raju Lakkaraju <Raju.Lakkaraju@...rosemi.com>
To:     Andrew Lunn <andrew@...n.ch>
CC:     "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "f.fainelli@...il.com" <f.fainelli@...il.com>,
        Allan Nielsen <Allan.Nielsen@...rosemi.com>
Subject: Re: [PATCH 2/4] net: phy: Add MAC-IF driver for Microsemi PHYs.

Hi Andrew,

Thank you for review the code and valuable comments.
I accepted your review comments.
I will re-send the code.

Thanks,
Raju.

On Wed, Aug 24, 2016 at 03:06:44PM +0200, Andrew Lunn wrote:
> EXTERNAL EMAIL
> 
> 
> > +static int vsc85xx_mac_if_set(struct phy_device *phydev,
> > +                             phy_interface_t   *interface)
> > +{
> > +       int rc;
> > +       u16 reg_val;
> > +
> > +       mutex_lock(&phydev->lock);
> > +       reg_val = phy_read(phydev, MSCC_PHY_EXT_PHY_CNTL_1);
> > +       switch (*interface) {
> > +       case PHY_INTERFACE_MODE_RGMII:
> > +               reg_val &= ~(MAC_IF_SELECTION_MASK);
> > +               reg_val |= (MAC_IF_SELECTION_RGMII << MAC_IF_SELECTION_POS);
> > +               break;
> > +       case PHY_INTERFACE_MODE_RMII:
> > +               reg_val &= ~(MAC_IF_SELECTION_MASK);
> > +               reg_val |= (MAC_IF_SELECTION_RMII << MAC_IF_SELECTION_POS);
> > +               break;
> > +       case PHY_INTERFACE_MODE_MII:
> > +       case PHY_INTERFACE_MODE_GMII:
> > +       default:
> > +               reg_val &= ~(MAC_IF_SELECTION_MASK);
> > +               reg_val |= (MAC_IF_SELECTION_GMII << MAC_IF_SELECTION_POS);
> > +               break;
> > +       }
> > +       rc = phy_write(phydev, MSCC_PHY_EXT_PHY_CNTL_1, reg_val);
> > +       if (rc != 0)
> > +               goto out_unlock;
> > +
> > +       rc = vsc85xx_soft_reset(phydev);
> > +
> > +out_unlock:
> > +       mutex_unlock(&phydev->lock);
> > +
> > +       return rc;
> > +}
> 
> Again, you need to justify why you are doing something completely
> different to all other phy drivers. You cannot you do what
> m88e1121_config_aneg(), mv88e111_config_init(), dp83867_config_init()
> does?
> 
>         Andrew

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ