Skip to content

Commit

Permalink
net: dsa: mv88e6xxx: fix shift of FID bits in mv88e6185_g1_vtu_loadpu…
Browse files Browse the repository at this point in the history
…rge()

The comment is correct, but the code ends up moving the bits four
places too far, into the VTUOp field.

Fixes: 11ea809 (net: dsa: mv88e6xxx: support 256 databases)
Signed-off-by: Rasmus Villemoes <rasmus.villemoes@prevas.dk>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Rasmus Villemoes authored and David S. Miller committed Jun 19, 2019
1 parent d470e72 commit 48620e3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/dsa/mv88e6xxx/global1_vtu.c
Original file line number Diff line number Diff line change
Expand Up @@ -415,7 +415,7 @@ int mv88e6185_g1_vtu_loadpurge(struct mv88e6xxx_chip *chip,
* VTU DBNum[7:4] are located in VTU Operation 11:8
*/
op |= entry->fid & 0x000f;
op |= (entry->fid & 0x00f0) << 8;
op |= (entry->fid & 0x00f0) << 4;
}

return mv88e6xxx_g1_vtu_op(chip, op);
Expand Down

0 comments on commit 48620e3

Please sign in to comment.