[PATCH] PMFS: Remove unneeded return statements

Ross Zwisler ross.zwisler at linux.intel.com
Tue Aug 20 18:08:02 EDT 2013


Signed-off-by: Ross Zwisler <ross.zwisler at linux.intel.com>
---
 fs/pmfs/balloc.c   | 2 --
 fs/pmfs/bbuild.c   | 2 --
 fs/pmfs/inode.c    | 6 ------
 fs/pmfs/journal.c  | 1 -
 fs/pmfs/super.c    | 1 -
 fs/pmfs/wprotect.c | 2 --
 6 files changed, 14 deletions(-)

diff --git a/fs/pmfs/balloc.c b/fs/pmfs/balloc.c
index ba08166..e2b9d9b 100644
--- a/fs/pmfs/balloc.c
+++ b/fs/pmfs/balloc.c
@@ -137,8 +137,6 @@ block_found:
 
 	if (free_blocknode)
 		__pmfs_free_blocknode(free_blocknode);
-		
-	return;
 }
 
 void pmfs_free_block(struct super_block *sb, unsigned long blocknr,
diff --git a/fs/pmfs/bbuild.c b/fs/pmfs/bbuild.c
index 71fee7f..57746b0 100644
--- a/fs/pmfs/bbuild.c
+++ b/fs/pmfs/bbuild.c
@@ -73,8 +73,6 @@ static void pmfs_init_blockmap_from_inode(struct super_block *sb)
 		blknode->block_high = le64_to_cpu(p[index].block_high);
 		list_add_tail(&blknode->link, &sbi->block_inuse_head);
 	}
-
-	return;
 }
 
 static bool pmfs_can_skip_full_scan(struct super_block *sb)
diff --git a/fs/pmfs/inode.c b/fs/pmfs/inode.c
index ce4f84e..154ba37 100644
--- a/fs/pmfs/inode.c
+++ b/fs/pmfs/inode.c
@@ -389,7 +389,6 @@ update_root_and_height:
 	 * 16 bytes atomically. Confirm if it is really true. */
 	cmpxchg_double_local((u64 *)pi, &pi->root, *(u64 *)pi, pi->root,
 		*(u64 *)b, newroot);
-	return;
 }
 
 static unsigned long pmfs_inode_count_iblocks_recursive(struct super_block *sb,
@@ -515,7 +514,6 @@ end_truncate_blocks:
 	pi->i_ctime = cpu_to_le32(inode->i_ctime.tv_sec);
 	pmfs_memlock_inode(sb, pi);
 	pmfs_flush_buffer(pi, 1, false);
-	return;
 }
 
 
@@ -907,8 +905,6 @@ static void pmfs_update_inode(struct inode *inode, struct pmfs_inode *pi)
 		pi->dev.rdev = cpu_to_le32(inode->i_rdev);
 
 	pmfs_memlock_inode(inode->i_sb, pi);
-
-	return;
 }
 
 /*
@@ -1308,7 +1304,6 @@ static void pmfs_block_truncate_page(struct inode *inode, loff_t newsize)
 	memset(bp + offset, 0, length);
 	pmfs_memlock_block(sb, bp);
 	pmfs_flush_buffer(bp + offset, length, false);
-	return;
 }
 
 void pmfs_truncate_del(struct inode *inode)
@@ -1442,7 +1437,6 @@ void pmfs_setsize(struct inode *inode, loff_t newsize)
 		PERSISTENT_MARK();
 		PERSISTENT_BARRIER();
 	}
-	return;
 }
 
 int pmfs_getattr(struct vfsmount *mnt, struct dentry *dentry,
diff --git a/fs/pmfs/journal.c b/fs/pmfs/journal.c
index bb710a2..7282000 100644
--- a/fs/pmfs/journal.c
+++ b/fs/pmfs/journal.c
@@ -615,7 +615,6 @@ static inline void pmfs_commit_logentry(struct super_block *sb,
 		le->gen_id = cpu_to_le16(trans->gen_id);
 		pmfs_flush_buffer(le, LOGENTRY_SIZE, true);
 	}
-	return;
 }
 
 int pmfs_add_logentry(struct super_block *sb,
diff --git a/fs/pmfs/super.c b/fs/pmfs/super.c
index 6f788c9..19f3b8e0 100644
--- a/fs/pmfs/super.c
+++ b/fs/pmfs/super.c
@@ -1205,7 +1205,6 @@ static void __exit exit_pmfs_fs(void)
 	destroy_inodecache();
 	destroy_blocknode_cache();
 	destroy_transaction_cache();
-	return;
 }
 
 MODULE_AUTHOR("Intel Corporation <linux-pmfs at intel.com>");
diff --git a/fs/pmfs/wprotect.c b/fs/pmfs/wprotect.c
index d80b4fe..544e6cf 100644
--- a/fs/pmfs/wprotect.c
+++ b/fs/pmfs/wprotect.c
@@ -28,7 +28,6 @@ static inline void wprotect_disable(void)
 	cr0_val = read_cr0();
 	cr0_val &= (~X86_CR0_WP);
 	write_cr0(cr0_val);
-	return;
 }
 
 static inline void wprotect_enable(void)
@@ -38,7 +37,6 @@ static inline void wprotect_enable(void)
 	cr0_val = read_cr0();
 	cr0_val |= X86_CR0_WP;
 	write_cr0(cr0_val);
-	return;
 }
 
 /* FIXME: Use PAGE RW Bit */
-- 
1.8.2.GIT




More information about the Linux-pmfs mailing list