aboutsummaryrefslogtreecommitdiffstats
path: root/net/xfrm/xfrm_output.c
diff options
context:
space:
mode:
authorMasahide NAKAMURA <nakam@linux-ipv6.org>2007-12-20 23:43:36 -0500
committerDavid S. Miller <davem@davemloft.net>2008-01-28 17:59:39 -0500
commit0aa647746e5602e608220c10e51f49709a030f5d (patch)
tree514cde2ddf6308b0f1dfd83039cb8dd62b2c69d2 /net/xfrm/xfrm_output.c
parent558f82ef6e0d25e87f7468c07b6db1fbbf95a855 (diff)
[XFRM]: Support to increment packet dropping statistics.
Signed-off-by: Masahide NAKAMURA <nakam@linux-ipv6.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/xfrm/xfrm_output.c')
-rw-r--r--net/xfrm/xfrm_output.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/net/xfrm/xfrm_output.c b/net/xfrm/xfrm_output.c
index 26fa0cb78c94..867484a046af 100644
--- a/net/xfrm/xfrm_output.c
+++ b/net/xfrm/xfrm_output.c
@@ -69,10 +69,13 @@ static int xfrm_output_one(struct sk_buff *skb, int err)
69 err = x->type->output(x, skb); 69 err = x->type->output(x, skb);
70 70
71resume: 71resume:
72 if (err) 72 if (err) {
73 XFRM_INC_STATS(LINUX_MIB_XFRMOUTSTATEPROTOERROR);
73 goto error_nolock; 74 goto error_nolock;
75 }
74 76
75 if (!(skb->dst = dst_pop(dst))) { 77 if (!(skb->dst = dst_pop(dst))) {
78 XFRM_INC_STATS(LINUX_MIB_XFRMOUTERROR);
76 err = -EHOSTUNREACH; 79 err = -EHOSTUNREACH;
77 goto error_nolock; 80 goto error_nolock;
78 } 81 }
@@ -167,6 +170,7 @@ int xfrm_output(struct sk_buff *skb)
167 if (skb->ip_summed == CHECKSUM_PARTIAL) { 170 if (skb->ip_summed == CHECKSUM_PARTIAL) {
168 err = skb_checksum_help(skb); 171 err = skb_checksum_help(skb);
169 if (err) { 172 if (err) {
173 XFRM_INC_STATS(LINUX_MIB_XFRMOUTERROR);
170 kfree_skb(skb); 174 kfree_skb(skb);
171 return err; 175 return err;
172 } 176 }