net: mvpp2: fix typo in the tcam setup
This patch fixes a typo in the mvpp2_prs_tcam_data_cmp() function, as
the shift value is inverted with the data.
Fixes: 3f518509de
("ethernet: Add new driver for Marvell Armada 375 network unit")
Signed-off-by: Antoine Tenart <antoine.tenart@free-electrons.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
5c25f65fd1
commit
ef4816f0ee
@ -1539,7 +1539,7 @@ static bool mvpp2_prs_tcam_data_cmp(struct mvpp2_prs_entry *pe, int offs,
|
|||||||
int off = MVPP2_PRS_TCAM_DATA_BYTE(offs);
|
int off = MVPP2_PRS_TCAM_DATA_BYTE(offs);
|
||||||
u16 tcam_data;
|
u16 tcam_data;
|
||||||
|
|
||||||
tcam_data = (8 << pe->tcam.byte[off + 1]) | pe->tcam.byte[off];
|
tcam_data = (pe->tcam.byte[off + 1] << 8) | pe->tcam.byte[off];
|
||||||
if (tcam_data != data)
|
if (tcam_data != data)
|
||||||
return false;
|
return false;
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user