[WIP] [PATCH v3 07/12] erofs-utils: fuse: kill erofs_get_root_nid()

Gao Xiang hsiangkao at aol.com
Tue Nov 3 02:55:53 AEDT 2020


(will fold into the original patch.)

Signed-off-by: Gao Xiang <hsiangkao at aol.com>
---
 fuse/init.c | 7 +------
 fuse/init.h | 1 -
 2 files changed, 1 insertion(+), 7 deletions(-)

diff --git a/fuse/init.c b/fuse/init.c
index b4089a204409..d67c7f0dd298 100644
--- a/fuse/init.c
+++ b/fuse/init.c
@@ -83,16 +83,11 @@ int erofs_read_superblock(void)
 	return 0;
 }
 
-erofs_nid_t erofs_get_root_nid(void)
-{
-	return sbi.root_nid;
-}
-
 void *erofs_init(struct fuse_conn_info *info)
 {
 	erofs_info("Using FUSE protocol %d.%d", info->proto_major, info->proto_minor);
 
-	if (inode_init(erofs_get_root_nid()) != 0) {
+	if (inode_init(sbi.root_nid) != 0) {
 		erofs_err("inode initialization failed");
 		abort();
 	}
diff --git a/fuse/init.h b/fuse/init.h
index 4bd48d18b003..f0211707b5ff 100644
--- a/fuse/init.h
+++ b/fuse/init.h
@@ -14,7 +14,6 @@
 #define BOOT_SECTOR_SIZE	0x400
 
 int erofs_read_superblock(void);
-erofs_nid_t erofs_get_root_nid(void);
 void *erofs_init(struct fuse_conn_info *info);
 
 #endif
-- 
2.24.0



More information about the Linux-erofs mailing list