net: Only do flow_dissector hash computation once per packet
authorTom Herbert <therbert@google.com>
Wed, 2 Jul 2014 04:33:17 +0000 (21:33 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 8 Jul 2014 04:14:21 +0000 (21:14 -0700)
commita3b18ddb9cc1056eea24e3edc1828cfb3fd0726f
tree5100dd399922df55b29a1acf2b5a4dcc332c10b4
parentcb1ce2ef387b01686469487edd45994872d52d73
net: Only do flow_dissector hash computation once per packet

Add sw_hash flag to skbuff to indicate that skb->hash was computed
from flow_dissector. This flag is checked in skb_get_hash to avoid
repeatedly trying to compute the hash (ie. in the case that no L4 hash
can be computed).

Signed-off-by: Tom Herbert <therbert@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/linux/skbuff.h
net/core/flow_dissector.c