]> git.baikalelectronics.ru Git - kernel.git/commit
flow_dissector: Cleanup control flow
authorTom Herbert <tom@quantonium.net>
Fri, 1 Sep 2017 21:04:11 +0000 (14:04 -0700)
committerDavid S. Miller <davem@davemloft.net>
Tue, 5 Sep 2017 18:40:08 +0000 (11:40 -0700)
commit96b206bf7ce240385bdc47afac390dab8029126e
treeeb04848adab6ac341a0b9dcbcd5e646ccf28e769
parentb04504b1ec65bbf8f3c079b038e2e180bb335e5a
flow_dissector: Cleanup control flow

__skb_flow_dissect is riddled with gotos that make discerning the flow,
debugging, and extending the capability difficult. This patch
reorganizes things so that we only perform goto's after the two main
switch statements (no gotos within the cases now). It also eliminates
several goto labels so that there are only two labels that can be target
for goto.

Reported-by: Alexander Popov <alex.popov@linux.com>
Signed-off-by: Tom Herbert <tom@quantonium.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
include/net/flow_dissector.h
net/core/flow_dissector.c