]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commit
nfp: fix flower offload metadata flag usage
authorPieter Jansen van Vuuren <pieter.jansenvanvuuren@netronome.com>
Fri, 17 Nov 2017 01:06:39 +0000 (17:06 -0800)
committerDavid S. Miller <davem@davemloft.net>
Fri, 17 Nov 2017 05:09:35 +0000 (14:09 +0900)
commit6c3ab204f4ca00374a374bc0fc9a275b64d1bcbb
treea77e756333f850cb336930938deeaad3c894db82
parenta52b04bcd2acff95ffbec19d5fc32016bb365aa0
nfp: fix flower offload metadata flag usage

Hardware has no notion of new or last mask id, instead it makes use of the
message type (i.e. add flow or del flow) in combination with a single bit
in metadata flags to determine when to add or delete a mask id. Previously
we made use of the new or last flags to indicate that a new mask should be
allocated or deallocated, respectively. This incorrect behaviour is fixed
by making use single bit in metadata flags to indicate mask allocation or
deallocation.

Fixes: 43f84b72c50d ("nfp: add metadata to each flow offload")
Signed-off-by: Pieter Jansen van Vuuren <pieter.jansenvanvuuren@netronome.com>
Reviewed-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/netronome/nfp/flower/main.h
drivers/net/ethernet/netronome/nfp/flower/metadata.c