Skip to content
Snippets Groups Projects
Commit 4e298e46 authored by Stefan Weil's avatar Stefan Weil Committed by Edgar E. Iglesias
Browse files

xilinx_axienet: Fix bit mask code


Obviously the code wanted to mask the lower bits but failed to do so
because of a missing "<".

cppcheck detected a conditional expression which was always true (1 < 7).

Signed-off-by: default avatarStefan Weil <sw@weilnetz.de>
Signed-off-by: default avatarEdgar E. Iglesias <edgar.iglesias@gmail.com>
parent 7387de16
No related branches found
No related tags found
No related merge requests found
......@@ -575,7 +575,7 @@ static void enet_write(void *opaque, hwaddr addr,
break;
case R_MC:
value &= ((1 < 7) - 1);
value &= ((1 << 7) - 1);
/* Enable the MII. */
if (value & MC_EN) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment