linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Christian Dietrich <christian.dietrich@informatik.uni-erlangen.de>
To: "David S. Miller" <davem@davemloft.net>,
	Grant Likely <grant.likely@secretlab.ca>,
	linux-kernel@vger.kernel.org, trivial@kernel.org
Subject: [PATCH 5/8] drivers/char/rtc: use printk_ratelimited instead of printk_ratelimit
Date: Sat, 4 Jun 2011 17:36:33 +0200	[thread overview]
Message-ID: <24591311b0f8cad2cc12013274ff8c0c70014beb.1307199715.git.christian.dietrich@informatik.uni-erlangen.de> (raw)
In-Reply-To: <cover.1307199715.git.christian.dietrich@informatik.uni-erlangen.de>

Since printk_ratelimit() shouldn't be used anymore (see comment in
include/linux/printk.h), replace it with printk_ratelimited.

Signed-off-by: Christian Dietrich <christian.dietrich@informatik.uni-erlangen.de>
---
 drivers/char/rtc.c |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/drivers/char/rtc.c b/drivers/char/rtc.c
index dfa8b30..ccd124a 100644
--- a/drivers/char/rtc.c
+++ b/drivers/char/rtc.c
@@ -80,6 +80,7 @@
 #include <linux/bcd.h>
 #include <linux/delay.h>
 #include <linux/uaccess.h>
+#include <linux/ratelimit.h>
 
 #include <asm/current.h>
 #include <asm/system.h>
@@ -1195,10 +1196,8 @@ static void rtc_dropped_irq(unsigned long data)
 
 	spin_unlock_irq(&rtc_lock);
 
-	if (printk_ratelimit()) {
-		printk(KERN_WARNING "rtc: lost some interrupts at %ldHz.\n",
-			freq);
-	}
+	printk_ratelimited(KERN_WARNING "rtc: lost some interrupts at %ldHz.\n",
+			   freq);
 
 	/* Now we have new data */
 	wake_up_interruptible(&rtc_wait);
-- 
1.7.1


  parent reply	other threads:[~2011-06-04 15:46 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <cover.1307199715.git.christian.dietrich@informatik.uni-erlangen.de>
2011-06-04 15:35 ` [PATCH 1/8] powerpc/rtas-rtc: remove sideeffects of printk_ratelimit Christian Dietrich
2011-06-04 15:35 ` [PATCH 2/8] drivers/octeon: use printk_ratelimited instead " Christian Dietrich
2011-06-04 15:36 ` [PATCH 3/8] scsi/sg: " Christian Dietrich
2011-06-04 15:36 ` [PATCH 4/8] md/raid: " Christian Dietrich
2011-06-28  6:45   ` NeilBrown
2011-06-04 15:36 ` Christian Dietrich [this message]
2011-06-04 15:36 ` [PATCH 6/8] drivers/gpu/drm: " Christian Dietrich
2011-06-04 15:36 ` [PATCH 7/8] arch/powerpc: " Christian Dietrich
2011-06-04 15:37 ` [PATCH 8/8] arch/x86: " Christian Dietrich
2011-06-06  6:35   ` Rusty Russell
2011-06-06  8:11     ` richard -rw- weinberger
2011-06-07  3:11       ` Rusty Russell
2011-06-07  3:37         ` Joe Perches

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=24591311b0f8cad2cc12013274ff8c0c70014beb.1307199715.git.christian.dietrich@informatik.uni-erlangen.de \
    --to=christian.dietrich@informatik.uni-erlangen.de \
    --cc=davem@davemloft.net \
    --cc=grant.likely@secretlab.ca \
    --cc=linux-kernel@vger.kernel.org \
    --cc=trivial@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).