Commit f9c4171e01f6befdf5d15346070b819d341c9c73
Committed by
David S. Miller
1 parent
70abc8cb90
Exists in
master
and in
7 other branches
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@ti.com> Acked-by: Anant Gole <anantgole@ti.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Showing 1 changed file with 1 additions and 1 deletions Side-by-side Diff
drivers/net/davinci_emac.c
... | ... | @@ -2272,7 +2272,7 @@ |
2272 | 2272 | unsigned int clk_div; |
2273 | 2273 | int mdio_bus_freq = emac_bus_frequency; |
2274 | 2274 | |
2275 | - if (mdio_max_freq & mdio_bus_freq) | |
2275 | + if (mdio_max_freq && mdio_bus_freq) | |
2276 | 2276 | clk_div = ((mdio_bus_freq / mdio_max_freq) - 1); |
2277 | 2277 | else |
2278 | 2278 | clk_div = 0xFF; |