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>
This commit is contained in:

committed by
David S. Miller

parent
e5276937ae
commit
bcc83839ff
@@ -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
|
||||
|
Reference in New Issue
Block a user