[PATCH] JFS: Remove unnecessary parentheses

Liao Yuanhong posted 1 patch 1 month, 1 week ago
fs/jfs/jfs_mount.c | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
[PATCH] JFS: Remove unnecessary parentheses
Posted by Liao Yuanhong 1 month, 1 week ago
When using &, it's unnecessary to have parentheses afterward. Remove
redundant parentheses to enhance readability.

Signed-off-by: Liao Yuanhong <liaoyuanhong@vivo.com>
---
 fs/jfs/jfs_mount.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/fs/jfs/jfs_mount.c b/fs/jfs/jfs_mount.c
index 98f9a432c336..52e6b58c5dbd 100644
--- a/fs/jfs/jfs_mount.c
+++ b/fs/jfs/jfs_mount.c
@@ -325,13 +325,13 @@ static int chkSuper(struct super_block *sb)
 	if ((j_sb->s_flag & cpu_to_le32(JFS_BAD_SAIT)) !=
 	    cpu_to_le32(JFS_BAD_SAIT)) {
 		expected_AIM_bytesize = 2 * PSIZE;
-		AIM_bytesize = lengthPXD(&(j_sb->s_aim2)) * bsize;
+		AIM_bytesize = lengthPXD(&j_sb->s_aim2) * bsize;
 		expected_AIT_bytesize = 4 * PSIZE;
-		AIT_bytesize = lengthPXD(&(j_sb->s_ait2)) * bsize;
-		AIM_byte_addr = addressPXD(&(j_sb->s_aim2)) * bsize;
-		AIT_byte_addr = addressPXD(&(j_sb->s_ait2)) * bsize;
+		AIT_bytesize = lengthPXD(&j_sb->s_ait2) * bsize;
+		AIM_byte_addr = addressPXD(&j_sb->s_aim2) * bsize;
+		AIT_byte_addr = addressPXD(&j_sb->s_ait2) * bsize;
 		byte_addr_diff0 = AIT_byte_addr - AIM_byte_addr;
-		fsckwsp_addr = addressPXD(&(j_sb->s_fsckpxd)) * bsize;
+		fsckwsp_addr = addressPXD(&j_sb->s_fsckpxd) * bsize;
 		byte_addr_diff1 = fsckwsp_addr - AIT_byte_addr;
 		if ((AIM_bytesize != expected_AIM_bytesize) ||
 		    (AIT_bytesize != expected_AIT_bytesize) ||
-- 
2.34.1
Re: [PATCH] JFS: Remove unnecessary parentheses
Posted by Dave Kleikamp 2 weeks, 2 days ago
On 8/25/25 8:36AM, Liao Yuanhong wrote:
> When using &, it's unnecessary to have parentheses afterward. Remove
> redundant parentheses to enhance readability.
> 
> Signed-off-by: Liao Yuanhong <liaoyuanhong@vivo.com>

Applying.

Thanks,
Shaggy

> ---
>   fs/jfs/jfs_mount.c | 10 +++++-----
>   1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/fs/jfs/jfs_mount.c b/fs/jfs/jfs_mount.c
> index 98f9a432c336..52e6b58c5dbd 100644
> --- a/fs/jfs/jfs_mount.c
> +++ b/fs/jfs/jfs_mount.c
> @@ -325,13 +325,13 @@ static int chkSuper(struct super_block *sb)
>   	if ((j_sb->s_flag & cpu_to_le32(JFS_BAD_SAIT)) !=
>   	    cpu_to_le32(JFS_BAD_SAIT)) {
>   		expected_AIM_bytesize = 2 * PSIZE;
> -		AIM_bytesize = lengthPXD(&(j_sb->s_aim2)) * bsize;
> +		AIM_bytesize = lengthPXD(&j_sb->s_aim2) * bsize;
>   		expected_AIT_bytesize = 4 * PSIZE;
> -		AIT_bytesize = lengthPXD(&(j_sb->s_ait2)) * bsize;
> -		AIM_byte_addr = addressPXD(&(j_sb->s_aim2)) * bsize;
> -		AIT_byte_addr = addressPXD(&(j_sb->s_ait2)) * bsize;
> +		AIT_bytesize = lengthPXD(&j_sb->s_ait2) * bsize;
> +		AIM_byte_addr = addressPXD(&j_sb->s_aim2) * bsize;
> +		AIT_byte_addr = addressPXD(&j_sb->s_ait2) * bsize;
>   		byte_addr_diff0 = AIT_byte_addr - AIM_byte_addr;
> -		fsckwsp_addr = addressPXD(&(j_sb->s_fsckpxd)) * bsize;
> +		fsckwsp_addr = addressPXD(&j_sb->s_fsckpxd) * bsize;
>   		byte_addr_diff1 = fsckwsp_addr - AIT_byte_addr;
>   		if ((AIM_bytesize != expected_AIM_bytesize) ||
>   		    (AIT_bytesize != expected_AIT_bytesize) ||