summaryrefslogtreecommitdiff
path: root/drivers/tty/moxa.c
diff options
context:
space:
mode:
authorManuel Zerpies <manuel.f.zerpies@ww.stud.uni-erlangen.de>2011-06-16 16:07:22 +0400
committerGreg Kroah-Hartman <gregkh@suse.de>2011-07-02 02:35:45 +0400
commit5a3c6b251d587715f8b87a50216e4c085c655777 (patch)
treefa1d3379b02b0bb243c367d30f84321dd1dc486d /drivers/tty/moxa.c
parent6ab8fba7fcb012a42d686abd33555b2215071415 (diff)
downloadlinux-5a3c6b251d587715f8b87a50216e4c085c655777.tar.xz
drivers/tty: use printk_ratelimited() instead of printk_ratelimit()
Since the printk_ratelimit() shouldn't be used anymore (see comment in include/linux/printk.h), replace it with printk_ratelimited(). Signed-off-by: Manuel Zerpies <manuel.f.zerpies@ww.stud.uni-erlangen.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/tty/moxa.c')
-rw-r--r--drivers/tty/moxa.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/tty/moxa.c b/drivers/tty/moxa.c
index ba679ce0a774..d15a071b1a54 100644
--- a/drivers/tty/moxa.c
+++ b/drivers/tty/moxa.c
@@ -44,6 +44,7 @@
#include <linux/init.h>
#include <linux/bitops.h>
#include <linux/slab.h>
+#include <linux/ratelimit.h>
#include <asm/system.h>
#include <asm/io.h>
@@ -242,8 +243,8 @@ static void moxa_wait_finish(void __iomem *ofsAddr)
while (readw(ofsAddr + FuncCode) != 0)
if (time_after(jiffies, end))
return;
- if (readw(ofsAddr + FuncCode) != 0 && printk_ratelimit())
- printk(KERN_WARNING "moxa function expired\n");
+ if (readw(ofsAddr + FuncCode) != 0)
+ printk_ratelimited(KERN_WARNING "moxa function expired\n");
}
static void moxafunc(void __iomem *ofsAddr, u16 cmd, u16 arg)