diff options
author | Tom Herbert <tom@herbertland.com> | 2015-09-01 09:24:24 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-09-01 15:06:22 -0700 |
commit | bcc83839ffdb063dd2b0370cd85c4f825761fc59 (patch) | |
tree | 060ce8e2ec5d30607e3bad22a680b225e264143c /include/net/flow_dissector.h | |
parent | e5276937ae6e654a811345f0716266f12e77bede (diff) | |
download | op-kernel-dev-bcc83839ffdb063dd2b0370cd85c4f825761fc59.zip op-kernel-dev-bcc83839ffdb063dd2b0370cd85c4f825761fc59.tar.gz |
skbuff: Make __skb_set_sw_hash a general function
Move __skb_set_sw_hash to skbuff.h and add __skb_set_hash which is
a common method (between __skb_set_sw_hash and skb_set_hash) to set
the hash in an skbuff.
Also, move skb_clear_hash to be closer to __skb_set_hash.
Signed-off-by: Tom Herbert <tom@herbertland.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/flow_dissector.h')
-rw-r--r-- | include/net/flow_dissector.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/net/flow_dissector.h b/include/net/flow_dissector.h index 6777a84..af76c49 100644 --- a/include/net/flow_dissector.h +++ b/include/net/flow_dissector.h @@ -167,4 +167,9 @@ struct flow_keys_digest { void make_flow_keys_digest(struct flow_keys_digest *digest, const struct flow_keys *flow); +static inline bool flow_keys_have_l4(struct flow_keys *keys) +{ + return (keys->ports.ports || keys->tags.flow_label); +} + #endif |