[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1260955739-30348-1-git-send-email-nageswari@ti.com>
Date: Wed, 16 Dec 2009 14:58:59 +0530
From: Nageswari Srinivasan <nageswari@...com>
To: netdev@...r.kernel.org
Cc: anantgole@...com, davinci-linux-open-source@...ux.davincidsp.com,
davem@...emloft.net, Nageswari Srinivasan <nageswari@...com>
Subject: [PATCH] TI DaVinci EMAC: Fix MDIO bus frequency configuration
There was a typo in "if condition" checking for validity of MDIO
bus frequency passed as part of platform data. Bitwise AND was
being used instead of a Logical AND.
Tested on: DM6467 EVM
Signed-off-by: Nageswari Srinivasan <nageswari@...com>
Acked-by: Anant Gole <anantgole@...com>
---
drivers/net/davinci_emac.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/net/davinci_emac.c b/drivers/net/davinci_emac.c
index 65a2d0b..8f8c696 100644
--- a/drivers/net/davinci_emac.c
+++ b/drivers/net/davinci_emac.c
@@ -2276,7 +2276,7 @@ static int emac_mii_reset(struct mii_bus *bus)
unsigned int clk_div;
int mdio_bus_freq = emac_bus_frequency;
- if (mdio_max_freq & mdio_bus_freq)
+ if (mdio_max_freq && mdio_bus_freq)
clk_div = ((mdio_bus_freq / mdio_max_freq) - 1);
else
clk_div = 0xFF;
--
1.6.2.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