diff options
author | Jan Hoffmann <jan@3e8.eu> | 2022-09-25 14:32:31 +0200 |
---|---|---|
committer | Sander Vanheule <sander@svanheule.net> | 2022-09-25 20:53:24 +0200 |
commit | d924a75be360dfddc69cd8dedd2fc88aa19598a1 (patch) | |
tree | 5290adb4cc592d767802ff5ef07bfd858d856d90 /target/linux/realtek | |
parent | 6e9613844ca1ddea7e36abc44a513c89ef0598ff (diff) | |
download | upstream-d924a75be360dfddc69cd8dedd2fc88aa19598a1.tar.gz upstream-d924a75be360dfddc69cd8dedd2fc88aa19598a1.tar.bz2 upstream-d924a75be360dfddc69cd8dedd2fc88aa19598a1.zip |
realtek: fix RTL839x egress tag for ports >= 32
Don't overwrite AS_DPM and L2LEARNING flags when dest_port is >= 32.
Fixes: 1773264a0c6d ("realtek: correct egress frame port verification")
Signed-off-by: Jan Hoffmann <jan@3e8.eu>
Diffstat (limited to 'target/linux/realtek')
-rw-r--r-- | target/linux/realtek/files-5.10/drivers/net/ethernet/rtl838x_eth.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/target/linux/realtek/files-5.10/drivers/net/ethernet/rtl838x_eth.c b/target/linux/realtek/files-5.10/drivers/net/ethernet/rtl838x_eth.c index e96c5a7216..d497b4cc8c 100644 --- a/target/linux/realtek/files-5.10/drivers/net/ethernet/rtl838x_eth.c +++ b/target/linux/realtek/files-5.10/drivers/net/ethernet/rtl838x_eth.c @@ -116,7 +116,7 @@ static void rtl839x_create_tx_header(struct p_hdr *h, unsigned int dest_port, in // h->cpu_tag[1] |= BIT(1) | BIT(0); // Bypass filter 1/2 if (dest_port >= 32) { dest_port -= 32; - h->cpu_tag[2] = BIT(dest_port) >> 16; + h->cpu_tag[2] |= (BIT(dest_port) >> 16) & 0xf; h->cpu_tag[3] = BIT(dest_port) & 0xffff; } else { h->cpu_tag[4] = BIT(dest_port) >> 16; |