Skip to content
Commit 2a36ed7c authored by Tom Rix's avatar Tom Rix Committed by David S. Miller
Browse files

dpaa2-switch: fix default return of dpaa2_switch_flower_parse_mirror_key

Clang static analysis reports this representative problem
dpaa2-switch-flower.c:616:24: warning: The right operand of '=='
  is a garbage value
  tmp->cfg.vlan_id == vlan) {
                   ^  ~~~~
vlan is set in dpaa2_switch_flower_parse_mirror_key(). However
this function can return success without setting vlan.  So
change the default return to -EOPNOTSUPP.

Fixes: 0f3faece

 ("dpaa2-switch: add VLAN based mirroring")
Signed-off-by: default avatarTom Rix <trix@redhat.com>
Reviewed-by: default avatarIoana Ciornei <ioana.ciornei@nxp.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 9d2d38c3
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