Skip to content

Commit

Permalink
[IRDA]: Ratelimit messages.
Browse files Browse the repository at this point in the history
From: Joe Perches <joe@perches.com>

Based upon a patch by Dave Jones.

Signed-off-by: Dave Jones <davej@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Joe Perches authored and David S. Miller committed Feb 13, 2006
1 parent 75c0141 commit 7a11c4d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions include/net/irda/irda.h
Original file line number Diff line number Diff line change
Expand Up @@ -82,9 +82,9 @@ do { if(!(expr)) { \
#define IRDA_ASSERT_LABEL(label)
#endif /* CONFIG_IRDA_DEBUG */

#define IRDA_WARNING(args...) printk(KERN_WARNING args)
#define IRDA_MESSAGE(args...) printk(KERN_INFO args)
#define IRDA_ERROR(args...) printk(KERN_ERR args)
#define IRDA_WARNING(args...) do { if (net_ratelimit()) printk(KERN_WARNING args); } while (0)
#define IRDA_MESSAGE(args...) do { if (net_ratelimit()) printk(KERN_INFO args); } while (0)
#define IRDA_ERROR(args...) do { if (net_ratelimit()) printk(KERN_ERR args); } while (0)

/*
* Magic numbers used by Linux-IrDA. Random numbers which must be unique to
Expand Down

0 comments on commit 7a11c4d

Please sign in to comment.