All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] f2fs: fix double count on issued discard commands
@ 2017-09-11  3:38 Jaegeuk Kim
  2017-09-12  1:53   ` Chao Yu
  0 siblings, 1 reply; 16+ messages in thread
From: Jaegeuk Kim @ 2017-09-11  3:38 UTC (permalink / raw)
  To: linux-kernel, linux-fsdevel, linux-f2fs-devel; +Cc: Jaegeuk Kim

If issue_cond is true, it does double count for # of issued commands.

Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
---
 fs/f2fs/segment.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/f2fs/segment.c b/fs/f2fs/segment.c
index 7fd742f747ce..25196ff5d587 100644
--- a/fs/f2fs/segment.c
+++ b/fs/f2fs/segment.c
@@ -1087,7 +1087,7 @@ static int __issue_discard_cmd(struct f2fs_sb_info *sbi, bool issue_cond)
 				issued++;
 				__submit_discard_cmd(sbi, dc);
 			}
-			if (issue_cond && iter++ > DISCARD_ISSUE_RATE)
+			if (issue_cond && iter > DISCARD_ISSUE_RATE)
 				goto out;
 		}
 		if (list_empty(pend_list) && dcc->pend_list_tag[i] & P_TRIM)
-- 
2.14.0.rc1.383.gd1ce394fe2-goog

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

end of thread, other threads:[~2017-09-13  8:48 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-09-11  3:38 [PATCH] f2fs: fix double count on issued discard commands Jaegeuk Kim
2017-09-12  1:53 ` [f2fs-dev] " Chao Yu
2017-09-12  1:53   ` Chao Yu
2017-09-12  3:53   ` Chao Yu
2017-09-12  3:53     ` Chao Yu
2017-09-12  4:29     ` Jaegeuk Kim
     [not found]     ` <CGME20170912042935epcas1p4630737028cc7b9536a0c688c92084e84@epcms1p7>
2017-09-12  4:34       ` Daeho Jeong
2017-09-12  4:34         ` Daeho Jeong
2017-09-12 17:11         ` Jaegeuk Kim
2017-09-12 17:11           ` Jaegeuk Kim
2017-09-12 17:11           ` [f2fs-dev] " Jaegeuk Kim
2017-09-13  7:13         ` Chao Yu
2017-09-13  7:13           ` Chao Yu
2017-09-13  7:13           ` [f2fs-dev] " Chao Yu
     [not found]         ` <CGME20170912042935epcas1p4630737028cc7b9536a0c688c92084e84@epcms1p8>
2017-09-13  8:48           ` Daeho Jeong
2017-09-13  8:48             ` Daeho Jeong

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.