Skip to content

Commit

Permalink
net/sched: fix incorrect vlan_push_eth dest field
Browse files Browse the repository at this point in the history
Seems like a potential copy-paste bug slipped in here,
the second memcpy should of course be populating src
and not dest.

Fixes: ab95465 ("net/sched: add vlan push_eth and pop_eth action to the hardware IR")
Signed-off-by: Louis Peens <louis.peens@corigine.com>
Link: https://lore.kernel.org/r/20220323092506.21639-1-louis.peens@corigine.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
  • Loading branch information
Louis Peens authored and Jakub Kicinski committed Mar 23, 2022
1 parent a911ad1 commit 054d557
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/net/tc_act/tc_vlan.h
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ static inline void tcf_vlan_push_eth(unsigned char *src, unsigned char *dest,
{
rcu_read_lock();
memcpy(dest, rcu_dereference(to_vlan(a)->vlan_p)->tcfv_push_dst, ETH_ALEN);
memcpy(dest, rcu_dereference(to_vlan(a)->vlan_p)->tcfv_push_src, ETH_ALEN);
memcpy(src, rcu_dereference(to_vlan(a)->vlan_p)->tcfv_push_src, ETH_ALEN);
rcu_read_unlock();
}

Expand Down

0 comments on commit 054d557

Please sign in to comment.