Skip to content
Commit 8e1b3ac4 authored by Xin Long's avatar Xin Long Committed by David S. Miller
Browse files

net: sched: initialize with 0 before setting erspan md->u



In fl_set_erspan_opt(), all bits of erspan md was set 1, as this
function is also used to set opt MASK. However, when setting for
md->u.index for opt VALUE, the rest bits of the union md->u will
be left 1. It would cause to fail the match of the whole md when
version is 1 and only index is set.

This patch is to fix by initializing with 0 before setting erspan
md->u.

Reported-by: default avatarShuang Li <shuali@redhat.com>
Fixes: 79b1011c

 ("net: sched: allow flower to match erspan options")
Signed-off-by: default avatarXin Long <lucien.xin@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent ad7b27c9
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment