nfp: fix unchecked flow dissector use
authorPieter Jansen van Vuuren <pieter.jansenvanvuuren@netronome.com>
Fri, 25 Aug 2017 17:31:01 +0000 (19:31 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 28 Aug 2017 22:20:24 +0000 (15:20 -0700)
commita7cd39e0c7805a93eaa4256370bcd48c506d46c1
tree832c1173afd0c623ba540da5f58945dc472bed94
parent77146b5d79cfa51aebb8c0e8c19af32b579890f7
nfp: fix unchecked flow dissector use

Previously flow dissectors were referenced without first checking that
they are in use and correctly populated by TC. This patch fixes this by
checking each flow dissector key before referencing them.

Fixes: 5571e8c9f241 ("nfp: extend flower matching capabilities")
Signed-off-by: Pieter Jansen van Vuuren <pieter.jansenvanvuuren@netronome.com>
Reviewed-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Reviewed-by: Simon Horman <simon.horman@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/netronome/nfp/flower/match.c
drivers/net/ethernet/netronome/nfp/flower/offload.c