Skip to contentSkip to conversation

f2fs: remove unnessary comment in __may_age_extent_tree

PATCH Applied Qi Han 4 participants 6 messages Apr 18, 2023 – Apr 24, 2023 F2FS file system

lore
Share & tools
lore

Qi Han

author
#0 lore raw

PATCH 1/1 f2fs: remove unnessary comment in __may_age_extent_tree

This comment make no sense and is in the wrong place, so let's remove it.

---
 fs/f2fs/extent_cache.c | 1 -
 1 file changed, 1 deletion(-)
fs/f2fs/extent_cache.c +0 -1
index 28b12553f2b3..1f6d7de35794 100644
@@ -86,7 +86,6 @@ static bool __may_age_extent_tree(struct inode *inode)
 
 	if (!test_opt(sbi, AGE_EXTENT_CACHE))
 		return false;
-	/* don't cache block age info for cold file */
 	if (is_inode_flag_set(inode, FI_COMPRESSED_FILE))
 		return false;
 	if (file_is_cold(inode))
Signature · 1 line
2.39.0
maintainer
#1 lore raw
Quoted 13 lines · Qi Han

This comment make no sense and is in the wrong place, so let's remove it.

---
  fs/f2fs/extent_cache.c | 1 -
  1 file changed, 1 deletion(-)
fs/f2fs/extent_cache.c +0 -0
index 28b12553f2b3..1f6d7de35794 100644

fs/f2fs/extent_cache.c static bool __may_age_extent_tree(struct inode *inode) · line 90

Quoted 6 lines
fs/f2fs/extent_cache.c +0 -1
@@ -86,7 +86,6 @@ static bool __may_age_extent_tree(struct inode *inode)
 
  	if (!test_opt(sbi, AGE_EXTENT_CACHE))
  		return false;
-	/* don't cache block age info for cold file */
  	if (is_inode_flag_set(inode, FI_COMPRESSED_FILE))
  		return false;

Should move it here instead of removal?

/* don't cache block age info for cold file */

Quoted 1 line
fs/f2fs/extent_cache.c +0 -0
  	if (file_is_cold(inode))
maintainer
#2 lore raw
Quoted 22 lines · Chao Yu
Quoted 13 lines · Qi Han

This comment make no sense and is in the wrong place, so let's remove it.

---
  fs/f2fs/extent_cache.c | 1 -
  1 file changed, 1 deletion(-)
fs/f2fs/extent_cache.c +0 -0
index 28b12553f2b3..1f6d7de35794 100644

fs/f2fs/extent_cache.c static bool __may_age_extent_tree(struct inode *inode) · line 89

Quoted 5 lines
fs/f2fs/extent_cache.c +0 -1
@@ -86,7 +86,6 @@ static bool __may_age_extent_tree(struct inode *inode)
  	if (!test_opt(sbi, AGE_EXTENT_CACHE))
  		return false;
-	/* don't cache block age info for cold file */
  	if (is_inode_flag_set(inode, FI_COMPRESSED_FILE))
  		return false;

Should move it here instead of removal?

Quoted 1 line

/* don't cache block age info for cold file */

Not worth to comment this, as the code is exactly saying that.

Quoted 2 lines
Quoted 2 lines
fs/f2fs/extent_cache.c +0 -0
  	if (file_is_cold(inode))
maintainer Reviewed-by
#3 lore raw
Quoted 23 lines · Jaegeuk Kim
Quoted 22 lines · Chao Yu
Quoted 13 lines · Qi Han

This comment make no sense and is in the wrong place, so let's remove it.

---
   fs/f2fs/extent_cache.c | 1 -
   1 file changed, 1 deletion(-)
fs/f2fs/extent_cache.c +0 -0
index 28b12553f2b3..1f6d7de35794 100644

fs/f2fs/extent_cache.c static bool __may_age_extent_tree(struct inode *inode) · line 89

Quoted 5 lines
fs/f2fs/extent_cache.c +0 -1
@@ -86,7 +86,6 @@ static bool __may_age_extent_tree(struct inode *inode)
   	if (!test_opt(sbi, AGE_EXTENT_CACHE))
   		return false;
-	/* don't cache block age info for cold file */
   	if (is_inode_flag_set(inode, FI_COMPRESSED_FILE))
   		return false;

Should move it here instead of removal?

Quoted 3 lines
Quoted 1 line

/* don't cache block age info for cold file */

Not worth to comment this, as the code is exactly saying that.

Correct.

Thanks,

Quoted 3 lines
Quoted 3 lines
Quoted 3 lines
fs/f2fs/extent_cache.c +0 -0
   	if (file_is_cold(inode))
author
#4 lore raw

PATCH 1/1 f2fs: move wrong comment to right place in __may_age_extent_tree

In reply to Qi Han

This code is commented in the wrong place, let's move it to the right place.

---
 fs/f2fs/extent_cache.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/f2fs/extent_cache.c +1 -1
index 28b12553f2b3..0ad769a822ac 100644
@@ -86,9 +86,9 @@ static bool __may_age_extent_tree(struct inode *inode)
 
 	if (!test_opt(sbi, AGE_EXTENT_CACHE))
 		return false;
-	/* don't cache block age info for cold file */
 	if (is_inode_flag_set(inode, FI_COMPRESSED_FILE))
 		return false;
+	/* don't cache block age info for cold file */
 	if (file_is_cold(inode))
 		return false;
 
Signature · 1 line
2.39.0
#5 lore raw
In reply to Qi Han
This patch was applied to jaegeuk/f2fs.git (dev) by Jaegeuk Kim <[email protected]>:

Hello:

This patch was applied to jaegeuk/f2fs.git (dev)
by Jaegeuk Kim <[email protected]>:

Quoted 7 lines · On Tue, 18 Apr 2023 14:09:54 +0800 you wrote:

This comment make no sense and is in the wrong place, so let's remove it.

---
 fs/f2fs/extent_cache.c | 1 -
 1 file changed, 1 deletion(-)

Here is the summary with links:
- [f2fs-dev] f2fs: remove unnessary comment in __may_age_extent_tree

    https://git.kernel.org/jaegeuk/f2fs/c/8375be2b6414

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html