Commit 4e92f0ac authored by Vignesh Raghavendra's avatar Vignesh Raghavendra
Browse files

net: ti: prueth_core: Fix packet reception on second port in switch mode



prueth->emac[0] represents port 1 and prueth->emac[1] represents port 2.
Therefore fix indexing of prueth->emac array by subtracting one from
port_id.

Without this driver would be doing out of bound access and therefore
packets received on port 2 (for host) is not forwarded correctly to the
Linux networking stack.

Fixes: f3142191 ("net: ti: prueth_core: Add support for RSTP switch")
Reported-by: default avatarMurali Karicheri <m-karicheri2@ti.com>
Signed-off-by: default avatarVignesh Raghavendra <vigneshr@ti.com>
parent b29af2db
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment