Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1333565

Re: [PATCH] phy: marvell: Fix reg-init bug on 88E1510

Path csiph.com!news.freedyn.net!aioe.org!bofh.it!news.nic.it!robomod
From Andrew Lunn <andrew@lunn.ch>
Newsgroups linux.kernel
Subject Re: [PATCH] phy: marvell: Fix reg-init bug on 88E1510
Date Sun, 14 Feb 2016 21:50:02 +0100
Message-ID <r2bMe-7Rl-11@gated-at.bofh.it> (permalink)
References <r2bCy-7Mr-25@gated-at.bofh.it>
MIME-Version 1.0
Content-Type text/plain; charset=us-ascii
Content-Disposition inline
User-Agent Mutt/1.5.21 (2010-09-15)
Sender robomod@news.nic.it
List-ID <linux-kernel.vger.kernel.org>
X-Mailing-List linux-kernel@vger.kernel.org
Approved robomod@news.nic.it
Lines 32
Organization linux.* mail to news gateway
X-Original-Cc netdev@vger.kernel.org, Florian Fainelli <f.fainelli@gmail.com>, linux-kernel@vger.kernel.org, "David S . Miller" <davem@davemloft.net>
X-Original-Date Sun, 14 Feb 2016 21:48:22 +0100
X-Original-Message-ID <20160214204822.GB4802@lunn.ch>
X-Original-References <1455481885-11395-1-git-send-email-clemens.gruber@pqgruber.com>
X-Original-Sender linux-kernel-owner@vger.kernel.org
Xref csiph.com linux.kernel:1333565

Show key headers only | View raw


On Sun, Feb 14, 2016 at 09:31:25PM +0100, Clemens Gruber wrote:
> The function marvell_of_reg_init was called too late, in
> m88e1510_config_aneg. This function was not reached, due to the phy
> state machine being stuck at waiting for interrupts (which were not
> enabled and off by default on the 88E1510)
> It lead to the ethernet link not coming up at boot.
> 
> This commit moves the call of marvell_of_reg_init to config_init.
> Now, a marvell,reg-init option to enable PHY interrupts on pin LED[2] is
> set early on and the phy state machine does not get stuck anymore.
> Tested on i.MX6Q boards with Marvell 88E1510 PHYs.

This looks like a good fix for you board. But maybe we should look at
the bigger picture. How about calling your new 

> +static int m88e1510_config_init(struct phy_device *phydev)
> +{
> +	int err;
> +
> +	err = marvell_of_reg_init(phydev);
> +	if (err < 0)
> +		return err;
> +
> +	return 0;
> +}

marvell_config_init() and adding it to all PHYs which don't have a
specific config_init function.

We then get more consistent behaviour across Marvell PHYs.

   Andrew

Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH] phy: marvell: Fix reg-init bug on 88E1510 Clemens Gruber <clemens.gruber@pqgruber.com> - 2016-02-14 21:40 +0100
  Re: [PATCH] phy: marvell: Fix reg-init bug on 88E1510 Andrew Lunn <andrew@lunn.ch> - 2016-02-14 21:50 +0100
    Re: [PATCH] phy: marvell: Fix reg-init bug on 88E1510 Clemens Gruber <clemens.gruber@pqgruber.com> - 2016-02-15 00:30 +0100

csiph-web