diff options
author | Patrick McHardy <kaber@trash.net> | 2007-04-09 14:47:18 -0400 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-04-26 01:28:38 -0400 |
commit | c5c2523893747f88a83376abad310c8ad13f7197 (patch) | |
tree | 58f1ab25ac9f7ca7460abbd24e9bab9c8683f6fd /include | |
parent | 557922584d9c5b6b990bcfb2fec3134f0e73a05d (diff) |
[XFRM]: Optimize MTU calculation
Replace the probing based MTU estimation, which usually takes 2-3 iterations
to find a fitting value and may underestimate the MTU, by an exact calculation.
Also fix underestimation of the XFRM trailer_len, which causes unnecessary
reallocations.
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include')
-rw-r--r-- | include/net/xfrm.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/net/xfrm.h b/include/net/xfrm.h index 5a00aa85b756..e144a25814bd 100644 --- a/include/net/xfrm.h +++ b/include/net/xfrm.h | |||
@@ -279,7 +279,7 @@ struct xfrm_type | |||
279 | xfrm_address_t *(*local_addr)(struct xfrm_state *, xfrm_address_t *); | 279 | xfrm_address_t *(*local_addr)(struct xfrm_state *, xfrm_address_t *); |
280 | xfrm_address_t *(*remote_addr)(struct xfrm_state *, xfrm_address_t *); | 280 | xfrm_address_t *(*remote_addr)(struct xfrm_state *, xfrm_address_t *); |
281 | /* Estimate maximal size of result of transformation of a dgram */ | 281 | /* Estimate maximal size of result of transformation of a dgram */ |
282 | u32 (*get_max_size)(struct xfrm_state *, int size); | 282 | u32 (*get_mtu)(struct xfrm_state *, int size); |
283 | }; | 283 | }; |
284 | 284 | ||
285 | extern int xfrm_register_type(struct xfrm_type *type, unsigned short family); | 285 | extern int xfrm_register_type(struct xfrm_type *type, unsigned short family); |