linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] quota: avoid increasing DQST_LOOKUPS when iterating over dirty/inuse list
@ 2019-09-26  8:34 Chengguang Xu
  2019-10-04  8:11 ` Jan Kara
  0 siblings, 1 reply; 2+ messages in thread
From: Chengguang Xu @ 2019-09-26  8:34 UTC (permalink / raw)
  To: jack; +Cc: linux-kernel, Chengguang Xu

It is meaningless to increase DQST_LOOKUPS number while iterating
over dirty/inuse list, so just avoid it.

Signed-off-by: Chengguang Xu <cgxu519@zoho.com.cn>
---
 fs/quota/dquot.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/fs/quota/dquot.c b/fs/quota/dquot.c
index 6e826b454082..00a3c6df2ea3 100644
--- a/fs/quota/dquot.c
+++ b/fs/quota/dquot.c
@@ -595,7 +595,6 @@ int dquot_scan_active(struct super_block *sb,
 		/* Now we have active dquot so we can just increase use count */
 		atomic_inc(&dquot->dq_count);
 		spin_unlock(&dq_list_lock);
-		dqstats_inc(DQST_LOOKUPS);
 		dqput(old_dquot);
 		old_dquot = dquot;
 		/*
@@ -649,7 +648,6 @@ int dquot_writeback_dquots(struct super_block *sb, int type)
 			 * use count */
 			dqgrab(dquot);
 			spin_unlock(&dq_list_lock);
-			dqstats_inc(DQST_LOOKUPS);
 			err = sb->dq_op->write_dquot(dquot);
 			if (err) {
 				/*
-- 
2.20.1




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

* Re: [PATCH] quota: avoid increasing DQST_LOOKUPS when iterating over dirty/inuse list
  2019-09-26  8:34 [PATCH] quota: avoid increasing DQST_LOOKUPS when iterating over dirty/inuse list Chengguang Xu
@ 2019-10-04  8:11 ` Jan Kara
  0 siblings, 0 replies; 2+ messages in thread
From: Jan Kara @ 2019-10-04  8:11 UTC (permalink / raw)
  To: Chengguang Xu; +Cc: Jan Kara, linux-kernel

On Thu 26-09-19 16:34:08, Chengguang Xu wrote:
> It is meaningless to increase DQST_LOOKUPS number while iterating
> over dirty/inuse list, so just avoid it.
> 
> Signed-off-by: Chengguang Xu <cgxu519@zoho.com.cn>

Yeah, makes sense. I've queued up your patch. Thanks!

								Honza

> ---
>  fs/quota/dquot.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/fs/quota/dquot.c b/fs/quota/dquot.c
> index 6e826b454082..00a3c6df2ea3 100644
> --- a/fs/quota/dquot.c
> +++ b/fs/quota/dquot.c
> @@ -595,7 +595,6 @@ int dquot_scan_active(struct super_block *sb,
>  		/* Now we have active dquot so we can just increase use count */
>  		atomic_inc(&dquot->dq_count);
>  		spin_unlock(&dq_list_lock);
> -		dqstats_inc(DQST_LOOKUPS);
>  		dqput(old_dquot);
>  		old_dquot = dquot;
>  		/*
> @@ -649,7 +648,6 @@ int dquot_writeback_dquots(struct super_block *sb, int type)
>  			 * use count */
>  			dqgrab(dquot);
>  			spin_unlock(&dq_list_lock);
> -			dqstats_inc(DQST_LOOKUPS);
>  			err = sb->dq_op->write_dquot(dquot);
>  			if (err) {
>  				/*
> -- 
> 2.20.1
> 
> 
> 
> 
-- 
Jan Kara <jack@suse.com>
SUSE Labs, CR

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

end of thread, other threads:[~2019-10-07 10:16 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-26  8:34 [PATCH] quota: avoid increasing DQST_LOOKUPS when iterating over dirty/inuse list Chengguang Xu
2019-10-04  8:11 ` Jan Kara

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).