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-next>] [day] [month] [year] [list]
Date:	Wed, 08 Oct 2008 15:16:32 +0300
From:	Paulius Zaleckas <paulius.zaleckas@...tonika.lt>
To:	netdev <netdev@...r.kernel.org>
Subject: [PATCH] phy_device: Interrupt number 0 is valid

If interrupt number 0(valid interrupt number) will be passed as
phy interrupt it should be used. In current situation even phy
polling will not work since PHY_POLL = -1

Signed-off-by: Paulius Zaleckas <paulius.zaleckas@...tonika.lt>

Index: linux-2.6/drivers/net/phy/phy_device.c
===================================================================
--- linux-2.6.orig/drivers/net/phy/phy_device.c
+++ linux-2.6/drivers/net/phy/phy_device.c
@@ -285,7 +285,7 @@ struct phy_device * phy_connect(struct n
 
 	phy_start_machine(phydev, NULL);
 
-	if (phydev->irq > 0)
+	if (phydev->irq >= 0)
 		phy_start_interrupts(phydev);
 
 	return phydev;
@@ -298,7 +298,7 @@ EXPORT_SYMBOL(phy_connect);
  */
 void phy_disconnect(struct phy_device *phydev)
 {
-	if (phydev->irq > 0)
+	if (phydev->irq >= 0)
 		phy_stop_interrupts(phydev);
 
 	phy_stop_machine(phydev);

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ