This patch adds a new object called 'struct xlate_cache' which can be
set in 'struct xlate_in', and passed to xlate_actions() to cache the
modules affected by this flow translation. Subsequently, the caller can
pass the xcache to xlate_push_stats() to credit stats and perform side
effects for a lower cost than full flow translation.
These changes are aimed currently at long-lived flows, decreasing the
average dump duration for such flows by 50-80%. This allows more flows
to be supported in the datapath at a given time. Applying these changes
to short-lived flows is left for a later commit.
Signed-off-by: Joe Stringer <joestringer@nicira.com> Acked-by: Ethan Jackson <ethan@nicira.com>
---
v2: Acked.
v1: Add caching for fin_timeout action.
Expire netflows on xlate_cache_clear().
Account to bonds using a copy of 'flow' rather than hash.
Always build XC_NORMAL entry (previously only if may_learn is true)
Rename xlate_from_cache()->xlate_push_stats()
Add may_learn parameter to xlate_push_stats()
Tidy up xlate_actions__() mirror/netflow code.
Fold in style fixups.
RFC: First post.