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]
Message-ID: <014901c83c06$da9223e0$2b00a8c0@ARV127>
Date:	Tue, 11 Dec 2007 16:02:31 +0100
From:	"Rini van Zetten" <rini@...oo.nl>
To:	<afleming@...escale.com>
Cc:	<netdev@...r.kernel.org>, <linux-kernel@...r.kernel.org>
Subject: [PATCH]drivers/net/phy/: default return value in ioctl phy.c

Hello Andy,

This patch (to 2.6.23.9) add a default return value EOPNOTSUPP to the ioctl 
function. The problem with the always 0 return value is that the iwconfig 
(wireless) tool found a valid device when an ethernet device uses the phy 
abstraction layer.
I 've tetsted this with the macb driver.


Signed-off-by: Rini van Zetten <rini@...oo.nl>

diff --git a/drivers/net/phy/phy.c b/drivers/net/phy/phy.c
index cb230f4..c07460d 100644
--- a/drivers/net/phy/phy.c
+++ b/drivers/net/phy/phy.c
@@ -405,6 +405,8 @@ int phy_mii_ioctl(struct phy_device *phydev,
                                && phydev->drv->config_init)
                        phydev->drv->config_init(phydev);
                break;
+       default:
+               return -EOPNOTSUPP;
        }

        return 0;

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ