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]
Message-ID: <20200630011914.GE597495@lunn.ch>
Date:   Tue, 30 Jun 2020 03:19:14 +0200
From:   Andrew Lunn <andrew@...n.ch>
To:     Andre.Edich@...rochip.com
Cc:     netdev@...r.kernel.org, UNGLinuxDriver@...rochip.com,
        steve.glendinning@...well.net, Parthiban.Veerasooran@...rochip.com
Subject: Re: [PATCH net-next 3/8] smsc95xx: add PAL support to use external
 PHY drivers

> +static int smsc95xx_start_phy(struct usbnet *dev)
> +{
> +	struct smsc95xx_priv *pdata = (struct smsc95xx_priv *)(dev-
> >data[0]);
> +	struct net_device *net = dev->net;
> +	int ret;
> +
> +	ret = smsc95xx_reset(dev);
> +	if (ret < 0)
> +		return ret;
> +
> +	/* attach the mac to the phy */
> +	ret = phy_connect_direct(net, pdata->phydev,
> +				 &smsc95xx_handle_link_change,
> +				 PHY_INTERFACE_MODE_MII);
> +	if (ret) {
> +		netdev_err(net, "can't attach PHY to %s\n", pdata-
> >mdiobus->id);
> +		return ret;
> +	}
> +
> +	phy_attached_info(net->phydev);
> +	phy_start(net->phydev);
> +	mii_nway_restart(&dev->mii);

Is mii_nway_restart() needed? phy_start will start auto-neg if needed.

It looks like after this patch you have a mixture of old MII and new
phylib. Does that work? If somebody doing a git bisect was to land on
one of these intermediary patches, so they have working Ethernet?

    Andrew

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ