From: Jonas Bonn Date: Fri, 11 Jun 2010 02:47:39 +0000 (+0000) Subject: ethoc: Clear command buffer after write X-Git-Tag: v3.12-rc1~9497^2~609 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b46773db64c264a6600f58d9da1ae43708b47fda;p=kernel%2Fkernel-generic.git ethoc: Clear command buffer after write This matches what ethoc_mdio_read does and makes the functions symmetric. Signed-off-by: Jonas Bonn Signed-off-by: David S. Miller --- diff --git a/drivers/net/ethoc.c b/drivers/net/ethoc.c index e5c2f5b..1681f08 100644 --- a/drivers/net/ethoc.c +++ b/drivers/net/ethoc.c @@ -613,8 +613,11 @@ static int ethoc_mdio_write(struct mii_bus *bus, int phy, int reg, u16 val) while (time_before(jiffies, timeout)) { u32 stat = ethoc_read(priv, MIISTATUS); - if (!(stat & MIISTATUS_BUSY)) + if (!(stat & MIISTATUS_BUSY)) { + /* reset MII command register */ + ethoc_write(priv, MIICOMMAND, 0); return 0; + } schedule(); }