lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20110616141930.GA12872@eferding.osrc.amd.com>
Date:	Thu, 16 Jun 2011 16:19:30 +0200
From:	Borislav Petkov <bp@...en8.de>
To:	Manuel Zerpies <manuel.f.zerpies@...stud.uni-erlangen.de>
Cc:	"David S. Miller" <davem@...emloft.net>, linux-ide@...r.kernel.org,
	linux-kernel@...r.kernel.org,
	christian.dietrich@...ormatik.uni-erlangen.de
Subject: Re: [PATCH 01/11] drivers/ide: use printk_ratelimited() instead of
 printk_ratelimit()

On Thu, Jun 16, 2011 at 02:06:37PM +0200, Manuel Zerpies wrote:
> 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@...stud.uni-erlangen.de>
> ---
>  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);

Does the printk fit on one line if you do

	pr_warn_ratelimited(...)

instead?

Thanks.

-- 
Regards/Gruss,
Boris.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ