net/sched: act_sample: fix action bind logic
[linux-block.git] / net / ipv4 / icmp.c
index 46aa2d65e40ab63dc2d343997d13c85fd6a51b7a..8cebb476b3ab1833b4efe073efc57dbdfeffd21d 100644 (file)
@@ -296,6 +296,7 @@ static bool icmpv4_global_allow(struct net *net, int type, int code)
        if (icmp_global_allow())
                return true;
 
+       __ICMP_INC_STATS(net, ICMP_MIB_RATELIMITGLOBAL);
        return false;
 }
 
@@ -325,6 +326,8 @@ static bool icmpv4_xrlim_allow(struct net *net, struct rtable *rt,
        if (peer)
                inet_putpeer(peer);
 out:
+       if (!rc)
+               __ICMP_INC_STATS(net, ICMP_MIB_RATELIMITHOST);
        return rc;
 }