mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH] net: phy: ar8327: fix ar8327n_reg_read
@ 2018-01-30 20:02 Oleksij Rempel
  2018-02-05  7:24 ` Sascha Hauer
  0 siblings, 1 reply; 2+ messages in thread
From: Oleksij Rempel @ 2018-01-30 20:02 UTC (permalink / raw)
  To: barebox; +Cc: Oleksij Rempel

Actual read value was lost and only by accident worked properly.

Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
---
 drivers/net/phy/ar8327.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/phy/ar8327.c b/drivers/net/phy/ar8327.c
index a0b10021d..e9ac3d49e 100644
--- a/drivers/net/phy/ar8327.c
+++ b/drivers/net/phy/ar8327.c
@@ -83,7 +83,7 @@ static u32 ar8327n_reg_read(struct phy_device *phydev, u32 reg_addr)
 	reg_word_addr++;
 	phy_addr = 0x10 | ((reg_word_addr >> 5) & 0x7); /* bit7-5 of reg address */
 	phy_reg = (u8) (reg_word_addr & 0x1f);   /* bit4-0 of reg address */
-	reg_val = (u32) mdiobus_read(phydev->bus, phy_addr, phy_reg);
+	tmp_val = (u32) mdiobus_read(phydev->bus, phy_addr, phy_reg);
 	reg_val |= (tmp_val << 16);
 
 	return reg_val;
-- 
2.14.1


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] net: phy: ar8327: fix ar8327n_reg_read
  2018-01-30 20:02 [PATCH] net: phy: ar8327: fix ar8327n_reg_read Oleksij Rempel
@ 2018-02-05  7:24 ` Sascha Hauer
  0 siblings, 0 replies; 2+ messages in thread
From: Sascha Hauer @ 2018-02-05  7:24 UTC (permalink / raw)
  To: Oleksij Rempel; +Cc: barebox

On Tue, Jan 30, 2018 at 09:02:21PM +0100, Oleksij Rempel wrote:
> Actual read value was lost and only by accident worked properly.
> 
> Signed-off-by: Oleksij Rempel <linux@rempel-privat.de>
> ---
>  drivers/net/phy/ar8327.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Applied, thanks

Sascha

> 
> diff --git a/drivers/net/phy/ar8327.c b/drivers/net/phy/ar8327.c
> index a0b10021d..e9ac3d49e 100644
> --- a/drivers/net/phy/ar8327.c
> +++ b/drivers/net/phy/ar8327.c
> @@ -83,7 +83,7 @@ static u32 ar8327n_reg_read(struct phy_device *phydev, u32 reg_addr)
>  	reg_word_addr++;
>  	phy_addr = 0x10 | ((reg_word_addr >> 5) & 0x7); /* bit7-5 of reg address */
>  	phy_reg = (u8) (reg_word_addr & 0x1f);   /* bit4-0 of reg address */
> -	reg_val = (u32) mdiobus_read(phydev->bus, phy_addr, phy_reg);
> +	tmp_val = (u32) mdiobus_read(phydev->bus, phy_addr, phy_reg);
>  	reg_val |= (tmp_val << 16);
>  
>  	return reg_val;
> -- 
> 2.14.1
> 
> 
> _______________________________________________
> barebox mailing list
> barebox@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/barebox
> 

-- 
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-02-05  7:24 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-30 20:02 [PATCH] net: phy: ar8327: fix ar8327n_reg_read Oleksij Rempel
2018-02-05  7:24 ` Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox