linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net v1 1/1] net: phy: c45: fix network interface initialization failures on xtensa, arm:cubieboard
@ 2023-02-25  7:16 Oleksij Rempel
  2023-02-25 16:43 ` Simon Horman
  2023-02-27 21:16 ` Jakub Kicinski
  0 siblings, 2 replies; 3+ messages in thread
From: Oleksij Rempel @ 2023-02-25  7:16 UTC (permalink / raw)
  To: Andrew Lunn, Heiner Kallweit, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni
  Cc: Oleksij Rempel, Guenter Roeck, kernel, linux-kernel, netdev,
	Russell King

Without proper initialization, "changed" returned random numbers and caused
interface initialization failures.

Fixes: 022c3f87f88e ("net: phy: add genphy_c45_ethtool_get/set_eee() support")
Reported-by: Guenter Roeck <linux@roeck-us.net>
Tested-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de>
---
 drivers/net/phy/phy-c45.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/phy/phy-c45.c b/drivers/net/phy/phy-c45.c
index 3813b86689d0..fee514b96ab1 100644
--- a/drivers/net/phy/phy-c45.c
+++ b/drivers/net/phy/phy-c45.c
@@ -672,7 +672,7 @@ EXPORT_SYMBOL_GPL(genphy_c45_read_mdix);
  */
 int genphy_c45_write_eee_adv(struct phy_device *phydev, unsigned long *adv)
 {
-	int val, changed;
+	int val, changed = 0;
 
 	if (linkmode_intersects(phydev->supported_eee, PHY_EEE_CAP1_FEATURES)) {
 		val = linkmode_to_mii_eee_cap1_t(adv);
-- 
2.30.2


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

* Re: [PATCH net v1 1/1] net: phy: c45: fix network interface initialization failures on xtensa, arm:cubieboard
  2023-02-25  7:16 [PATCH net v1 1/1] net: phy: c45: fix network interface initialization failures on xtensa, arm:cubieboard Oleksij Rempel
@ 2023-02-25 16:43 ` Simon Horman
  2023-02-27 21:16 ` Jakub Kicinski
  1 sibling, 0 replies; 3+ messages in thread
From: Simon Horman @ 2023-02-25 16:43 UTC (permalink / raw)
  To: Oleksij Rempel
  Cc: Andrew Lunn, Heiner Kallweit, David S. Miller, Eric Dumazet,
	Jakub Kicinski, Paolo Abeni, Guenter Roeck, kernel, linux-kernel,
	netdev, Russell King

On Sat, Feb 25, 2023 at 08:16:44AM +0100, Oleksij Rempel wrote:
> Without proper initialization, "changed" returned random numbers and caused
> interface initialization failures.
> 
> Fixes: 022c3f87f88e ("net: phy: add genphy_c45_ethtool_get/set_eee() support")
> Reported-by: Guenter Roeck <linux@roeck-us.net>
> Tested-by: Guenter Roeck <linux@roeck-us.net>
> Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de>

Reviewed-by: Simon Horman <simon.horman@corigine.com>


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

* Re: [PATCH net v1 1/1] net: phy: c45: fix network interface initialization failures on xtensa, arm:cubieboard
  2023-02-25  7:16 [PATCH net v1 1/1] net: phy: c45: fix network interface initialization failures on xtensa, arm:cubieboard Oleksij Rempel
  2023-02-25 16:43 ` Simon Horman
@ 2023-02-27 21:16 ` Jakub Kicinski
  1 sibling, 0 replies; 3+ messages in thread
From: Jakub Kicinski @ 2023-02-27 21:16 UTC (permalink / raw)
  To: Oleksij Rempel
  Cc: Andrew Lunn, Heiner Kallweit, David S. Miller, Eric Dumazet,
	Paolo Abeni, Guenter Roeck, kernel, linux-kernel, netdev,
	Russell King

On Sat, 25 Feb 2023 08:16:44 +0100 Oleksij Rempel wrote:
> Without proper initialization, "changed" returned random numbers and caused
> interface initialization failures.
> 
> Fixes: 022c3f87f88e ("net: phy: add genphy_c45_ethtool_get/set_eee() support")
> Reported-by: Guenter Roeck <linux@roeck-us.net>
> Tested-by: Guenter Roeck <linux@roeck-us.net>
> Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de>

Applied, thanks!

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

end of thread, other threads:[~2023-02-27 21:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-25  7:16 [PATCH net v1 1/1] net: phy: c45: fix network interface initialization failures on xtensa, arm:cubieboard Oleksij Rempel
2023-02-25 16:43 ` Simon Horman
2023-02-27 21:16 ` Jakub Kicinski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).