diff options
author | dingtianhong <dingtianhong@huawei.com> | 2014-03-25 05:00:10 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-03-26 16:40:24 -0400 |
commit | 9152e26df20b9e5ffdbe0d5b96d0e9ff8b33ff31 (patch) | |
tree | 47e16b3d7a6b6b63790aa032c26adab9b04271f9 /drivers/net | |
parent | 054bb8801038c93c42cb6cde75141aa396afd065 (diff) |
bonding: ratelimit pr_err() for bond xmit broadcast
It may spam if the system is out of the memory, add ratelimit for it.
Signed-off-by: Ding Tianhong <dingtianhong@huawei.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/bonding/bond_main.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c index ee17c246326e..cbadd6dccb2b 100644 --- a/drivers/net/bonding/bond_main.c +++ b/drivers/net/bonding/bond_main.c | |||
@@ -3656,8 +3656,8 @@ static int bond_xmit_broadcast(struct sk_buff *skb, struct net_device *bond_dev) | |||
3656 | struct sk_buff *skb2 = skb_clone(skb, GFP_ATOMIC); | 3656 | struct sk_buff *skb2 = skb_clone(skb, GFP_ATOMIC); |
3657 | 3657 | ||
3658 | if (!skb2) { | 3658 | if (!skb2) { |
3659 | pr_err("%s: Error: bond_xmit_broadcast(): skb_clone() failed\n", | 3659 | net_err_ratelimited("%s: Error: %s: skb_clone() failed\n", |
3660 | bond_dev->name); | 3660 | bond_dev->name, __func__); |
3661 | continue; | 3661 | continue; |
3662 | } | 3662 | } |
3663 | /* bond_dev_queue_xmit always returns 0 */ | 3663 | /* bond_dev_queue_xmit always returns 0 */ |