Skip to contentSkip to conversation

f2fs: Add missing inline to f2fs_sanity_check_cluster() stub

PATCH In review Nathan Chancellor 2 participants 4 messages Aug 16, 2021 – Aug 17, 2021 F2FS file system

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 f2fs: Add missing inline to f2fs_sanity_check_cluster() stub

Without this, there is a warning in nearly every fs/f2fs/ file when F2FS_FS_COMPRESSION is not set:

In file included from fs/f2fs/super.c:31:
fs/f2fs/f2fs.h:4251:13: warning: unused function 'f2fs_sanity_check_cluster' [-Wunused-function] static bool f2fs_sanity_check_cluster(struct dnode_of_data *dn) { return false; }

            ^

1 warning generated.

Fixes 1495870233e7 ("f2fs: compress: do sanity check on cluster")
---
 fs/f2fs/f2fs.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/f2fs/f2fs.h +1 -1
index 0c978f934dcc..fe1097e678da 100644
@@ -4248,7 +4248,7 @@ static inline void f2fs_put_page_dic(struct page *page)
 	WARN_ON_ONCE(1);
 }
 static inline unsigned int f2fs_cluster_blocks_are_contiguous(struct dnode_of_data *dn) { return 0; }
-static bool f2fs_sanity_check_cluster(struct dnode_of_data *dn) { return false; }
+static inline bool f2fs_sanity_check_cluster(struct dnode_of_data *dn) { return false; }
 static inline int f2fs_init_compress_inode(struct f2fs_sb_info *sbi) { return 0; }
 static inline void f2fs_destroy_compress_inode(struct f2fs_sb_info *sbi) { }
 static inline int f2fs_init_page_array_cache(struct f2fs_sb_info *sbi) { return 0; }

base-commit: f4b05791dda93edb03ebb6b48f1be104b2e64274

Signature · 1 line
2.33.0.rc2
maintainer
#1 lore raw

Hi Nathan,

Quoted 10 lines · Nathan Chancellor

Without this, there is a warning in nearly every fs/f2fs/ file when F2FS_FS_COMPRESSION is not set:

In file included from fs/f2fs/super.c:31:
fs/f2fs/f2fs.h:4251:13: warning: unused function 'f2fs_sanity_check_cluster' [-Wunused-function] static bool f2fs_sanity_check_cluster(struct dnode_of_data *dn) { return false; }

            ^

1 warning generated.

Fixes 1495870233e7 ("f2fs: compress: do sanity check on cluster")

This has not been merged yet, so if you don't mind, can I integrate your fix in the original patch?

Thanks,

Quoted 22 lines
---
 fs/f2fs/f2fs.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
fs/f2fs/f2fs.h +1 -1
index 0c978f934dcc..fe1097e678da 100644
@@ -4248,7 +4248,7 @@ static inline void f2fs_put_page_dic(struct page *page)
 	WARN_ON_ONCE(1);
 }
 static inline unsigned int f2fs_cluster_blocks_are_contiguous(struct dnode_of_data *dn) { return 0; }
-static bool f2fs_sanity_check_cluster(struct dnode_of_data *dn) { return false; }
+static inline bool f2fs_sanity_check_cluster(struct dnode_of_data *dn) { return false; }
 static inline int f2fs_init_compress_inode(struct f2fs_sb_info *sbi) { return 0; }
 static inline void f2fs_destroy_compress_inode(struct f2fs_sb_info *sbi) { }
 static inline int f2fs_init_page_array_cache(struct f2fs_sb_info *sbi) { return 0; }

base-commit: f4b05791dda93edb03ebb6b48f1be104b2e64274

Signature · 1 line
2.33.0.rc2
#2 lore raw
Quoted 12 lines · Jaegeuk Kim

Hi Nathan,

Quoted 9 lines · Nathan Chancellor

Without this, there is a warning in nearly every fs/f2fs/ file when F2FS_FS_COMPRESSION is not set:

In file included from fs/f2fs/super.c:31:
fs/f2fs/f2fs.h:4251:13: warning: unused function 'f2fs_sanity_check_cluster' [-Wunused-function] static bool f2fs_sanity_check_cluster(struct dnode_of_data *dn) { return false; }

             ^

1 warning generated.

Quoted 4 lines
Quoted 1 line
Fixes 1495870233e7 ("f2fs: compress: do sanity check on cluster")

This has not been merged yet, so if you don't mind, can I integrate your fix in the original patch?

Sure thing!

Cheers,
Nathan

maintainer
#3 lore raw
Quoted 13 lines · Nathan Chancellor
Quoted 12 lines · Jaegeuk Kim

Hi Nathan,

Quoted 9 lines · Nathan Chancellor

Without this, there is a warning in nearly every fs/f2fs/ file when F2FS_FS_COMPRESSION is not set:

In file included from fs/f2fs/super.c:31:
fs/f2fs/f2fs.h:4251:13: warning: unused function 'f2fs_sanity_check_cluster' [-Wunused-function] static bool f2fs_sanity_check_cluster(struct dnode_of_data *dn) { return false; }

             ^

1 warning generated.

Quoted 6 lines
Quoted 4 lines
Quoted 1 line
Fixes 1495870233e7 ("f2fs: compress: do sanity check on cluster")

This has not been merged yet, so if you don't mind, can I integrate your fix in the original patch?

Sure thing!

Thanks~ :)

Quoted 3 lines

Cheers,
Nathan