[PATCH] initialize a spin lock in gianfar driver
Kumar Gala
galak at freescale.com
Sat Mar 5 16:12:59 EST 2005
Initialize the mdio_lock spin lock in mii_info struct, which is otherwise
accessed prior to initialization.
Signed-off-by: Jaka Mocnik <jaka at activetools.si>
Signed-off-by: Kumar Gala <kumar.gala at freescale.com>
---
diff -Nru a/drivers/net/gianfar.c b/drivers/net/gianfar.c
--- a/drivers/net/gianfar.c 2005-03-04 23:03:27 -06:00
+++ b/drivers/net/gianfar.c 2005-03-04 23:03:27 -06:00
@@ -377,6 +377,8 @@
ADVERTISED_1000baseT_Full);
mii_info->autoneg = 1;
+ spin_lock_init(&mii_info->mdio_lock);
+
mii_info->mii_id = priv->einfo->phyid;
mii_info->dev = dev;
More information about the Linuxppc-embedded
mailing list