mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH V2] xfs: remove duplicated lines
@ 2026-11-26 13:59 Zizhi Wo
  2026-11-26 14:15 ` Carlos Maiolino
  0 siblings, 1 reply; 2+ messages in thread
From: Zizhi Wo @ 2026-11-26 13:59 UTC (permalink / raw)
  To: cem, dgc, djwong, hch, linux-xfs
  Cc: linux-kernel, yangerkun, chengzhihao1, wozizhi

From: Zizhi Wo <wozizhi@huawei.com>

Remove duplicated lines:
- xfs_ondisk.h checks the size of struct xfs_attrlist twice.
- xfs_rtgroup.h declares xfs_rtginode_irele() twice.

No functional changes.

Fixes: 650b774cf944 ("xfs: add static size checks for ioctl UABI")
Fixes: 6b08901a6e8f ("xfs: add realtime reverse map inode to metadata directory")
Signed-off-by: Zizhi Wo <wozizhi@huawei.com>
---
 fs/xfs/libxfs/xfs_ondisk.h  | 1 -
 fs/xfs/libxfs/xfs_rtgroup.h | 2 --
 2 files changed, 3 deletions(-)

diff --git a/fs/xfs/libxfs/xfs_ondisk.h b/fs/xfs/libxfs/xfs_ondisk.h
index 23cde1248f01..ae16b1bc2bbe 100644
--- a/fs/xfs/libxfs/xfs_ondisk.h
+++ b/fs/xfs/libxfs/xfs_ondisk.h
@@ -303,11 +303,10 @@ xfs_check_ondisk_structs(void)
 	XFS_CHECK_STRUCT_SIZE(struct dioattr,			12);
 	XFS_CHECK_STRUCT_SIZE(struct getbmap,			32);
 	XFS_CHECK_STRUCT_SIZE(struct getbmapx,			48);
 	XFS_CHECK_STRUCT_SIZE(struct xfs_attrlist_cursor,	16);
 	XFS_CHECK_STRUCT_SIZE(struct xfs_attrlist,		8);
-	XFS_CHECK_STRUCT_SIZE(struct xfs_attrlist,		8);
 	XFS_CHECK_STRUCT_SIZE(struct xfs_attrlist_ent,		4);
 	XFS_CHECK_STRUCT_SIZE(struct xfs_ag_geometry,		128);
 	XFS_CHECK_STRUCT_SIZE(struct xfs_rtgroup_geometry,	128);
 	XFS_CHECK_STRUCT_SIZE(struct xfs_error_injection,	8);
 	XFS_CHECK_STRUCT_SIZE(struct xfs_fsop_geom,		256);
diff --git a/fs/xfs/libxfs/xfs_rtgroup.h b/fs/xfs/libxfs/xfs_rtgroup.h
index fca2eb74908c..e505be68462b 100644
--- a/fs/xfs/libxfs/xfs_rtgroup.h
+++ b/fs/xfs/libxfs/xfs_rtgroup.h
@@ -326,12 +326,10 @@ int xfs_rtginode_load(struct xfs_rtgroup *rtg, enum xfs_rtg_inodes type,
 		struct xfs_trans *tp);
 int xfs_rtginode_create(struct xfs_rtgroup *rtg, enum xfs_rtg_inodes type,
 		bool init);
 void xfs_rtginode_irele(struct xfs_inode **ipp);
 
-void xfs_rtginode_irele(struct xfs_inode **ipp);
-
 static inline const char *xfs_rtginode_path(xfs_rgnumber_t rgno,
 		enum xfs_rtg_inodes type)
 {
 	return kasprintf(GFP_KERNEL, "%u.%s", rgno, xfs_rtginode_name(type));
 }
-- 
2.52.0


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH V2] xfs: remove duplicated lines
  2026-11-26 13:59 [PATCH V2] xfs: remove duplicated lines Zizhi Wo
@ 2026-11-26 14:15 ` Carlos Maiolino
  0 siblings, 0 replies; 2+ messages in thread
From: Carlos Maiolino @ 2026-11-26 14:15 UTC (permalink / raw)
  To: Zizhi Wo
  Cc: dgc, djwong, hch, linux-xfs, linux-kernel, yangerkun,
	chengzhihao1, wozizhi

On Thu, Nov 26, 2026 at 09:59:47PM +0800, Zizhi Wo wrote:
> From: Zizhi Wo <wozizhi@huawei.com>
> 
> Remove duplicated lines:
> - xfs_ondisk.h checks the size of struct xfs_attrlist twice.
> - xfs_rtgroup.h declares xfs_rtginode_irele() twice.
> 
> No functional changes.
> 
> Fixes: 650b774cf944 ("xfs: add static size checks for ioctl UABI")
> Fixes: 6b08901a6e8f ("xfs: add realtime reverse map inode to metadata directory")
> Signed-off-by: Zizhi Wo <wozizhi@huawei.com>

Looks good.

Reviewed-by: Carlos Maiolino <cmaiolino@redhat.com>

> ---
>  fs/xfs/libxfs/xfs_ondisk.h  | 1 -
>  fs/xfs/libxfs/xfs_rtgroup.h | 2 --
>  2 files changed, 3 deletions(-)
> 
> diff --git a/fs/xfs/libxfs/xfs_ondisk.h b/fs/xfs/libxfs/xfs_ondisk.h
> index 23cde1248f01..ae16b1bc2bbe 100644
> --- a/fs/xfs/libxfs/xfs_ondisk.h
> +++ b/fs/xfs/libxfs/xfs_ondisk.h
> @@ -303,11 +303,10 @@ xfs_check_ondisk_structs(void)
>  	XFS_CHECK_STRUCT_SIZE(struct dioattr,			12);
>  	XFS_CHECK_STRUCT_SIZE(struct getbmap,			32);
>  	XFS_CHECK_STRUCT_SIZE(struct getbmapx,			48);
>  	XFS_CHECK_STRUCT_SIZE(struct xfs_attrlist_cursor,	16);
>  	XFS_CHECK_STRUCT_SIZE(struct xfs_attrlist,		8);
> -	XFS_CHECK_STRUCT_SIZE(struct xfs_attrlist,		8);
>  	XFS_CHECK_STRUCT_SIZE(struct xfs_attrlist_ent,		4);
>  	XFS_CHECK_STRUCT_SIZE(struct xfs_ag_geometry,		128);
>  	XFS_CHECK_STRUCT_SIZE(struct xfs_rtgroup_geometry,	128);
>  	XFS_CHECK_STRUCT_SIZE(struct xfs_error_injection,	8);
>  	XFS_CHECK_STRUCT_SIZE(struct xfs_fsop_geom,		256);
> diff --git a/fs/xfs/libxfs/xfs_rtgroup.h b/fs/xfs/libxfs/xfs_rtgroup.h
> index fca2eb74908c..e505be68462b 100644
> --- a/fs/xfs/libxfs/xfs_rtgroup.h
> +++ b/fs/xfs/libxfs/xfs_rtgroup.h
> @@ -326,12 +326,10 @@ int xfs_rtginode_load(struct xfs_rtgroup *rtg, enum xfs_rtg_inodes type,
>  		struct xfs_trans *tp);
>  int xfs_rtginode_create(struct xfs_rtgroup *rtg, enum xfs_rtg_inodes type,
>  		bool init);
>  void xfs_rtginode_irele(struct xfs_inode **ipp);
>  
> -void xfs_rtginode_irele(struct xfs_inode **ipp);
> -
>  static inline const char *xfs_rtginode_path(xfs_rgnumber_t rgno,
>  		enum xfs_rtg_inodes type)
>  {
>  	return kasprintf(GFP_KERNEL, "%u.%s", rgno, xfs_rtginode_name(type));
>  }
> -- 
> 2.52.0
> 
> 

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2026-11-26 14:15 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-26 13:59 [PATCH V2] xfs: remove duplicated lines Zizhi Wo
2026-11-26 14:15 ` Carlos Maiolino

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®