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 for Android: free password hash cracker in your pocket
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Sun,  4 Dec 2011 10:37:24 +0100
From:	Heiko Schocher <hs@...x.de>
To:	unlisted-recipients:; (no To-header on input)
Cc:	Heiko Schocher <hs@...x.de>, netdev@...r.kernel.org,
	Vitaly Bordug <vbordug@...mvista.com>,
	Andrew Morton <akpm@...l.org>, Jeff Garzik <jeff@...zik.org>,
	Wolfgang Denk <wd@...x.de>
Subject: [PATCH] net, fixed phy: make BUSID configurable

Signed-off-by: Heiko Schocher <hs@...x.de>
Cc: netdev@...r.kernel.org
Cc: Vitaly Bordug <vbordug@...mvista.com>
Cc: Andrew Morton <akpm@...l.org>
Cc: Jeff Garzik <jeff@...zik.org>
Cc: Wolfgang Denk <wd@...x.de>
---
 drivers/net/phy/Kconfig |    5 +++++
 drivers/net/phy/fixed.c |    2 +-
 2 files changed, 6 insertions(+), 1 deletions(-)

diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig
index bb88e12..bed4bdd 100644
--- a/drivers/net/phy/Kconfig
+++ b/drivers/net/phy/Kconfig
@@ -101,6 +101,11 @@ config FIXED_PHY
 
 	  Currently tested with mpc866ads and mpc8349e-mitx.
 
+config FIXED_PHY_ID
+	int "BUS ID for fixed Bus/PHY emulation"
+	depends on FIXED_PHY
+	default "0"
+
 config MDIO_BITBANG
 	tristate "Support for bitbanged MDIO buses"
 	help
diff --git a/drivers/net/phy/fixed.c b/drivers/net/phy/fixed.c
index 1fa4d73..5c77478 100644
--- a/drivers/net/phy/fixed.c
+++ b/drivers/net/phy/fixed.c
@@ -220,7 +220,7 @@ static int __init fixed_mdio_bus_init(void)
 		goto err_mdiobus_reg;
 	}
 
-	snprintf(fmb->mii_bus->id, MII_BUS_ID_SIZE, "0");
+	snprintf(fmb->mii_bus->id, MII_BUS_ID_SIZE, "%d", CONFIG_FIXED_PHY_ID);
 	fmb->mii_bus->name = "Fixed MDIO Bus";
 	fmb->mii_bus->priv = fmb;
 	fmb->mii_bus->parent = &pdev->dev;
-- 
1.7.6.4

--
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