All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] hfsplus: remove pr_err message on ENOSPC file extend error
@ 2020-11-06 21:55 ` Colin King
  0 siblings, 0 replies; 4+ messages in thread
From: Colin King @ 2020-11-06 21:55 UTC (permalink / raw)
  To: linux-fsdevel; +Cc: kernel-janitors, linux-kernel

From: Colin Ian King <colin.king@canonical.com>

Currently ENOSPC errors that are triggered from extending a file
are spamming the kernel log with messages.  Since ENOSPC is being
returned there is enough information to userspace to inform why
the extend is failing and the error message is unnecessary and
just more logging noise.  This is particularly noticeable when
exercising a full hfs filesystem with stress-ng file stress tests.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 fs/hfsplus/extents.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/fs/hfsplus/extents.c b/fs/hfsplus/extents.c
index a930ddd15681..6cc30482c82c 100644
--- a/fs/hfsplus/extents.c
+++ b/fs/hfsplus/extents.c
@@ -446,13 +446,9 @@ int hfsplus_file_extend(struct inode *inode, bool zeroout)
 	int res;
 
 	if (sbi->alloc_file->i_size * 8 <
-	    sbi->total_blocks - sbi->free_blocks + 8) {
+	    sbi->total_blocks - sbi->free_blocks + 8)
 		/* extend alloc file */
-		pr_err("extend alloc file! (%llu,%u,%u)\n",
-		       sbi->alloc_file->i_size * 8,
-		       sbi->total_blocks, sbi->free_blocks);
 		return -ENOSPC;
-	}
 
 	mutex_lock(&hip->extents_lock);
 	if (hip->alloc_blocks == hip->first_blocks)
-- 
2.28.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH] hfsplus: remove pr_err message on ENOSPC file extend error
@ 2020-11-06 21:55 ` Colin King
  0 siblings, 0 replies; 4+ messages in thread
From: Colin King @ 2020-11-06 21:55 UTC (permalink / raw)
  To: linux-fsdevel; +Cc: kernel-janitors, linux-kernel

From: Colin Ian King <colin.king@canonical.com>

Currently ENOSPC errors that are triggered from extending a file
are spamming the kernel log with messages.  Since ENOSPC is being
returned there is enough information to userspace to inform why
the extend is failing and the error message is unnecessary and
just more logging noise.  This is particularly noticeable when
exercising a full hfs filesystem with stress-ng file stress tests.

Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 fs/hfsplus/extents.c | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/fs/hfsplus/extents.c b/fs/hfsplus/extents.c
index a930ddd15681..6cc30482c82c 100644
--- a/fs/hfsplus/extents.c
+++ b/fs/hfsplus/extents.c
@@ -446,13 +446,9 @@ int hfsplus_file_extend(struct inode *inode, bool zeroout)
 	int res;
 
 	if (sbi->alloc_file->i_size * 8 <
-	    sbi->total_blocks - sbi->free_blocks + 8) {
+	    sbi->total_blocks - sbi->free_blocks + 8)
 		/* extend alloc file */
-		pr_err("extend alloc file! (%llu,%u,%u)\n",
-		       sbi->alloc_file->i_size * 8,
-		       sbi->total_blocks, sbi->free_blocks);
 		return -ENOSPC;
-	}
 
 	mutex_lock(&hip->extents_lock);
 	if (hip->alloc_blocks = hip->first_blocks)
-- 
2.28.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] hfsplus: remove pr_err message on ENOSPC file extend error
  2020-11-06 21:55 ` Colin King
@ 2020-11-09 19:40   ` Viacheslav Dubeyko
  -1 siblings, 0 replies; 4+ messages in thread
From: Viacheslav Dubeyko @ 2020-11-09 19:40 UTC (permalink / raw)
  To: Colin King; +Cc: Linux FS devel list, kernel-janitors, LKML



> On Nov 6, 2020, at 1:55 PM, Colin King <colin.king@canonical.com> wrote:
> 
> From: Colin Ian King <colin.king@canonical.com>
> 
> Currently ENOSPC errors that are triggered from extending a file
> are spamming the kernel log with messages.  Since ENOSPC is being
> returned there is enough information to userspace to inform why
> the extend is failing and the error message is unnecessary and
> just more logging noise.  This is particularly noticeable when
> exercising a full hfs filesystem with stress-ng file stress tests.
> 
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
> fs/hfsplus/extents.c | 6 +-----
> 1 file changed, 1 insertion(+), 5 deletions(-)
> 
> diff --git a/fs/hfsplus/extents.c b/fs/hfsplus/extents.c
> index a930ddd15681..6cc30482c82c 100644
> --- a/fs/hfsplus/extents.c
> +++ b/fs/hfsplus/extents.c
> @@ -446,13 +446,9 @@ int hfsplus_file_extend(struct inode *inode, bool zeroout)
> 	int res;
> 
> 	if (sbi->alloc_file->i_size * 8 <
> -	    sbi->total_blocks - sbi->free_blocks + 8) {
> +	    sbi->total_blocks - sbi->free_blocks + 8)
> 		/* extend alloc file */
> -		pr_err("extend alloc file! (%llu,%u,%u)\n",
> -		       sbi->alloc_file->i_size * 8,
> -		       sbi->total_blocks, sbi->free_blocks);
> 		return -ENOSPC;
> -	}

Looks good and sounds reasonable.

Reviewed-by: Viacheslav Dubeyko <slava@dubeyko.com>

Thanks,
Viacheslav Dubeyko.

> 
> 	mutex_lock(&hip->extents_lock);
> 	if (hip->alloc_blocks == hip->first_blocks)
> -- 
> 2.28.0
> 


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] hfsplus: remove pr_err message on ENOSPC file extend error
@ 2020-11-09 19:40   ` Viacheslav Dubeyko
  0 siblings, 0 replies; 4+ messages in thread
From: Viacheslav Dubeyko @ 2020-11-09 19:40 UTC (permalink / raw)
  To: Colin King; +Cc: Linux FS devel list, kernel-janitors, LKML



> On Nov 6, 2020, at 1:55 PM, Colin King <colin.king@canonical.com> wrote:
> 
> From: Colin Ian King <colin.king@canonical.com>
> 
> Currently ENOSPC errors that are triggered from extending a file
> are spamming the kernel log with messages.  Since ENOSPC is being
> returned there is enough information to userspace to inform why
> the extend is failing and the error message is unnecessary and
> just more logging noise.  This is particularly noticeable when
> exercising a full hfs filesystem with stress-ng file stress tests.
> 
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
> fs/hfsplus/extents.c | 6 +-----
> 1 file changed, 1 insertion(+), 5 deletions(-)
> 
> diff --git a/fs/hfsplus/extents.c b/fs/hfsplus/extents.c
> index a930ddd15681..6cc30482c82c 100644
> --- a/fs/hfsplus/extents.c
> +++ b/fs/hfsplus/extents.c
> @@ -446,13 +446,9 @@ int hfsplus_file_extend(struct inode *inode, bool zeroout)
> 	int res;
> 
> 	if (sbi->alloc_file->i_size * 8 <
> -	    sbi->total_blocks - sbi->free_blocks + 8) {
> +	    sbi->total_blocks - sbi->free_blocks + 8)
> 		/* extend alloc file */
> -		pr_err("extend alloc file! (%llu,%u,%u)\n",
> -		       sbi->alloc_file->i_size * 8,
> -		       sbi->total_blocks, sbi->free_blocks);
> 		return -ENOSPC;
> -	}

Looks good and sounds reasonable.

Reviewed-by: Viacheslav Dubeyko <slava@dubeyko.com>

Thanks,
Viacheslav Dubeyko.

> 
> 	mutex_lock(&hip->extents_lock);
> 	if (hip->alloc_blocks == hip->first_blocks)
> -- 
> 2.28.0
> 

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-11-09 19:41 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-11-06 21:55 [PATCH] hfsplus: remove pr_err message on ENOSPC file extend error Colin King
2020-11-06 21:55 ` Colin King
2020-11-09 19:40 ` Viacheslav Dubeyko
2020-11-09 19:40   ` Viacheslav Dubeyko

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.