Skip to contentSkip to conversation

jbd2: clean up misleading comments for jbd2_fc_release_bufs

PATCH Applied yangerkun 3 participants 3 messages Jun 8, 2021 – Jun 24, 2021 Journalling layer for block devices (JBD2)

lore
Share & tools
lore

yangerkun

author
#0 lore raw

PATCH 1/1 jbd2: clean up misleading comments for jbd2_fc_release_bufs

This comments was for jbd2_fc_wait_bufs, not for jbd2_fc_release_bufs. Remove this misleading comments.

---
 fs/jbd2/journal.c | 8 --------
 1 file changed, 8 deletions(-)
fs/jbd2/journal.c +0 -8
index 2dc944442802..ea46e5ad6b59 100644
@@ -934,10 +934,6 @@ int jbd2_fc_wait_bufs(journal_t *journal, int num_blks)
 }
 EXPORT_SYMBOL(jbd2_fc_wait_bufs);
 
-/*
- * Wait on fast commit buffers that were allocated by jbd2_fc_get_buf
- * for completion.
- */
 int jbd2_fc_release_bufs(journal_t *journal)
 {
 	struct buffer_head *bh;
@@ -945,10 +941,6 @@ int jbd2_fc_release_bufs(journal_t *journal)
 
 	j_fc_off = journal->j_fc_off;
 
-	/*
-	 * Wait in reverse order to minimize chances of us being woken up before
-	 * all IOs have completed
-	 */
 	for (i = j_fc_off - 1; i >= 0; i--) {
 		bh = journal->j_fc_wbuf[i];
 		if (!bh)
Signature · 1 line
2.31.1
Reviewed-by on v1 1/1
#1 lore raw
Quoted 4 lines · yangerkun

This comments was for jbd2_fc_wait_bufs, not for jbd2_fc_release_bufs. Remove this misleading comments.

Good point! Feel free to add:

Honza

Quoted 33 lines
---
 fs/jbd2/journal.c | 8 --------
 1 file changed, 8 deletions(-)
fs/jbd2/journal.c +0 -8
index 2dc944442802..ea46e5ad6b59 100644
@@ -934,10 +934,6 @@ int jbd2_fc_wait_bufs(journal_t *journal, int num_blks)
 }
 EXPORT_SYMBOL(jbd2_fc_wait_bufs);
 
-/*
- * Wait on fast commit buffers that were allocated by jbd2_fc_get_buf
- * for completion.
- */
 int jbd2_fc_release_bufs(journal_t *journal)
 {
 	struct buffer_head *bh;
@@ -945,10 +941,6 @@ int jbd2_fc_release_bufs(journal_t *journal)
 
 	j_fc_off = journal->j_fc_off;
 
-	/*
-	 * Wait in reverse order to minimize chances of us being woken up before
-	 * all IOs have completed
-	 */
 	for (i = j_fc_off - 1; i >= 0; i--) {
 		bh = journal->j_fc_wbuf[i];
 		if (!bh)
Signature · 1 line
2.31.1
Signature · 2 lines
Jan Kara <[email protected]>
SUSE Labs, CR