From mboxrd@z Thu Jan 1 00:00:00 1970 From: Anatolij Gustschin Date: Fri, 26 Jul 2019 16:48:26 +0200 Subject: [U-Boot] [PATCH v2 1/6] net: phy: mv88e61xx: rework to enable detection of 88E6071 devices In-Reply-To: References: <20190709232251.31746-1-agust@denx.de> <20190709232251.31746-2-agust@denx.de> Message-ID: <20190726164826.04818ae6@crub> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Tue, 23 Jul 2019 04:07:04 +0000 Joe Hershberger joe.hershberger at ni.com wrote: > > > static int mv88e61xx_phy_wait(struct phy_device *phydev) > > > { > > > + struct mv88e61xx_phy_priv *priv = phydev->priv; > > > int val; > > > u32 timeout = 100; > > > > > > do { > > > - val = mv88e61xx_reg_read(phydev, DEVADDR_GLOBAL_2, > > > + val = mv88e61xx_reg_read(phydev, priv->global2, > > > > Probably just use phydev->priv->global2 instead of the local variable. No, I'll stick with local variable. priv is void*, we will get +drivers/net/phy/mv88e61xx.c:338:48: error: dereferencing 'void *' pointer [-Werror] + val = mv88e61xx_reg_read(phydev, phydev->priv->global2, -- Anatolij