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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <1464217241.16344.24.camel@perches.com>
Date:	Wed, 25 May 2016 16:00:41 -0700
From:	Joe Perches <joe@...ches.com>
To:	Salah Triki <salah.triki@....org>, akpm@...ux-foundation.org
Cc:	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] fs: befs: Check silent flag before logging errors

On Wed, 2016-05-25 at 22:58 +0100, Salah Triki wrote:
> Log errors only when silent flag is not set.
[]
> diff --git a/fs/befs/linuxvfs.c b/fs/befs/linuxvfs.c
[]
> @@ -765,14 +765,16 @@ befs_fill_super(struct super_block *sb, void *data, int silent)
>  
>  	sb->s_fs_info = kzalloc(sizeof(*befs_sb), GFP_KERNEL);
>  	if (sb->s_fs_info == NULL) {
> -		pr_err("(%s): Unable to allocate memory for private "
> -		       "portion of superblock. Bailing.\n", sb->s_id);
> +		if (!silent)
> +			pr_err("(%s): Unable to allocate memory for private "
> +				"portion of superblock. Bailing.\n", sb->s_id);

Might as well remove this pr_err instead as
there's already a generic OOM and stack dump.

> @@ -820,9 +823,10 @@ befs_fill_super(struct super_block *sb, void *data, int silent)
>  	brelse(bh);
>  
>  	if( befs_sb->num_blocks > ~((sector_t)0) ) {
> -		befs_error(sb, "blocks count: %llu "
> -			"is larger than the host can use",
> -			befs_sb->num_blocks);
> +		if (!silent)
> +			befs_error(sb, "blocks count: %llu "
> +					"is larger than the host can use",
> +					befs_sb->num_blocks);

Coalesce format too?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ