[PATCH 01/11] drivers/ide: use printk_ratelimited() instead of printk_ratelimit()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Since 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@xxxxxxxxxxxxxxxxxxxxxxx>
---
 drivers/ide/ide-atapi.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/ide/ide-atapi.c b/drivers/ide/ide-atapi.c
index 6f218e01..1b04f45 100644
--- a/drivers/ide/ide-atapi.c
+++ b/drivers/ide/ide-atapi.c
@@ -8,6 +8,7 @@
 #include <linux/ide.h>
 #include <linux/scatterlist.h>
 #include <linux/gfp.h>
+#include <linux/ratelimit.h>
 
 #include <scsi/scsi.h>
 
@@ -200,8 +201,7 @@ void ide_prep_sense(ide_drive_t *drive, struct request *rq)
 	err = blk_rq_map_kern(drive->queue, sense_rq, sense, sense_len,
 			      GFP_NOIO);
 	if (unlikely(err)) {
-		if (printk_ratelimit())
-			printk(KERN_WARNING PFX "%s: failed to map sense "
+		printk_ratelimited(KERN_WARNING PFX "%s: failed to map sense "
 					    "buffer\n", drive->name);
 		return;
 	}
-- 
1.7.4.1

--
To unsubscribe from this list: send the line "unsubscribe linux-ide" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Filesystems]     [Linux SCSI]     [Linux RAID]     [Git]     [Kernel Newbies]     [Linux Newbie]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Samba]     [Device Mapper]

  Powered by Linux