mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Carlos Maiolino <cem@kernel.org>
To: Zizhi Wo <wozizhi@huaweicloud.com>
Cc: dgc@kernel.org, djwong@kernel.org, hch@lst.de,
	 linux-xfs@vger.kernel.org, linux-kernel@vger.kernel.org,
	yangerkun@huawei.com,  chengzhihao1@huawei.com,
	wozizhi@huawei.com
Subject: Re: [PATCH V2] xfs: remove several unused and never-implemented declarations
Date: Mon, 7 Sep 2026 08:20:00 +0200	[thread overview]
Message-ID: <ap5XiYSFR93gZOGl@andromeda.toxiclabs.cc> (raw)
In-Reply-To: <20260905010354.142327-1-wozizhi@huaweicloud.com>

On Sat, Sep 05, 2026 at 09:03:54AM +0800, Zizhi Wo wrote:
> From: Zizhi Wo <wozizhi@huawei.com>
> 
> Over time a number of function declarations in various headers have become
> stale: either their implementations were removed when their last callers
> went away, or they were never implemented in the first place. None of them
> refer to anything anymore.
> 
> Remove the following dead declarations and the unused stub:
> 
> - xlog_assign_tail_lsn() and xlog_assign_tail_lsn_locked()
> - xfs_iext_realloc()
> - xfs_buf_iodone()
> - xfs_scrub_tester() and xfs_scrub_setup_inode_bmap_data() (never
>   implemented placeholders)
> - the !CONFIG_XFS_ONLINE_REPAIR stub of xrep_tempfile_iolock_both()
> 
> Signed-off-by: Zizhi Wo <wozizhi@huawei.com>

Reviewed-by: Carlos Maiolino <cmaiolino@redhat.com>
> ---
> v2:
>  - Squash the individual cleanup patches into a single patch, as suggested
>    by Carlos.
>  - Drop the former patch 4, since an equivalent change has already been
>    merged upstream.
>  - Remove the "Assisted-by:" tag.
> 
> v1: https://lore.kernel.org/all/20260904060648.1966130-1-wozizhi@huaweicloud.com/
> 
>  fs/xfs/scrub/common.h   | 1 -
>  fs/xfs/scrub/scrub.h    | 1 -
>  fs/xfs/scrub/tempfile.h | 4 ----
>  fs/xfs/xfs_buf_item.h   | 1 -
>  fs/xfs/xfs_inode.h      | 1 -
>  fs/xfs/xfs_log.h        | 2 --
>  6 files changed, 10 deletions(-)
> 
> diff --git a/fs/xfs/scrub/common.h b/fs/xfs/scrub/common.h
> index 9d627fd50687..f0f073a93413 100644
> --- a/fs/xfs/scrub/common.h
> +++ b/fs/xfs/scrub/common.h
> @@ -74,7 +74,6 @@ int xchk_setup_ag_rmapbt(struct xfs_scrub *sc);
>  int xchk_setup_ag_refcountbt(struct xfs_scrub *sc);
>  int xchk_setup_inode(struct xfs_scrub *sc);
>  int xchk_setup_inode_bmap(struct xfs_scrub *sc);
> -int xchk_setup_inode_bmap_data(struct xfs_scrub *sc);
>  int xchk_setup_directory(struct xfs_scrub *sc);
>  int xchk_setup_xattr(struct xfs_scrub *sc);
>  int xchk_setup_symlink(struct xfs_scrub *sc);
> diff --git a/fs/xfs/scrub/scrub.h b/fs/xfs/scrub/scrub.h
> index 6d7d3523b71f..737a5d6db15f 100644
> --- a/fs/xfs/scrub/scrub.h
> +++ b/fs/xfs/scrub/scrub.h
> @@ -261,7 +261,6 @@ static inline int xchk_nothing(struct xfs_scrub *sc)
>  }
>  
>  /* Metadata scrubbers */
> -int xchk_tester(struct xfs_scrub *sc);
>  int xchk_superblock(struct xfs_scrub *sc);
>  int xchk_agf(struct xfs_scrub *sc);
>  int xchk_agfl(struct xfs_scrub *sc);
> diff --git a/fs/xfs/scrub/tempfile.h b/fs/xfs/scrub/tempfile.h
> index 71c1b54599c3..d44ed43bafe0 100644
> --- a/fs/xfs/scrub/tempfile.h
> +++ b/fs/xfs/scrub/tempfile.h
> @@ -39,10 +39,6 @@ int xrep_tempfile_roll_trans(struct xfs_scrub *sc);
>  void xrep_tempfile_copyout_local(struct xfs_scrub *sc, int whichfork);
>  bool xrep_is_tempfile(const struct xfs_inode *ip);
>  #else
> -static inline void xrep_tempfile_iolock_both(struct xfs_scrub *sc)
> -{
> -	xchk_ilock(sc, XFS_IOLOCK_EXCL);
> -}
>  # define xrep_is_tempfile(ip)		(false)
>  # define xrep_tempfile_adjust_directory_tree(sc)	(0)
>  # define xrep_tempfile_rele(sc)
> diff --git a/fs/xfs/xfs_buf_item.h b/fs/xfs/xfs_buf_item.h
> index 3159325dd17b..28c79989d725 100644
> --- a/fs/xfs/xfs_buf_item.h
> +++ b/fs/xfs/xfs_buf_item.h
> @@ -60,7 +60,6 @@ static inline void xfs_buf_dquot_iodone(struct xfs_buf *bp)
>  {
>  }
>  #endif /* CONFIG_XFS_QUOTA */
> -void	xfs_buf_iodone(struct xfs_buf *);
>  bool	xfs_buf_log_check_iovec(struct kvec *iovec);
>  
>  unsigned int xfs_buf_inval_log_space(unsigned int map_count,
> diff --git a/fs/xfs/xfs_inode.h b/fs/xfs/xfs_inode.h
> index 34c1038ebfcd..1602027cd0aa 100644
> --- a/fs/xfs/xfs_inode.h
> +++ b/fs/xfs/xfs_inode.h
> @@ -585,7 +585,6 @@ uint		xfs_ilock_attr_map_shared(struct xfs_inode *);
>  int		xfs_ifree(struct xfs_trans *, struct xfs_inode *);
>  int		xfs_itruncate_extents_flags(struct xfs_trans **,
>  				struct xfs_inode *, int, xfs_fsize_t, int);
> -void		xfs_iext_realloc(xfs_inode_t *, int, int);
>  
>  int		xfs_log_force_inode(struct xfs_inode *ip);
>  void		xfs_iunpin_wait(xfs_inode_t *);
> diff --git a/fs/xfs/xfs_log.h b/fs/xfs/xfs_log.h
> index ca66429bf6c9..f715695e8fcb 100644
> --- a/fs/xfs/xfs_log.h
> +++ b/fs/xfs/xfs_log.h
> @@ -105,8 +105,6 @@ int	  xfs_log_mount(struct xfs_mount	*mp,
>  			int		 	num_bblocks);
>  int	  xfs_log_mount_finish(struct xfs_mount *mp);
>  void	xfs_log_mount_cancel(struct xfs_mount *);
> -xfs_lsn_t xlog_assign_tail_lsn(struct xfs_mount *mp);
> -xfs_lsn_t xlog_assign_tail_lsn_locked(struct xfs_mount *mp);
>  void	xfs_log_space_wake(struct xfs_mount *mp);
>  int	xfs_log_reserve(struct xfs_mount *mp, int length, int count,
>  			struct xlog_ticket **ticket, bool permanent);
> -- 
> 2.52.0
> 

  parent reply	other threads:[~2026-09-07  6:20 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-05  1:03 Zizhi Wo
2026-09-07  5:53 ` Christoph Hellwig
2026-09-07  6:20 ` Carlos Maiolino [this message]
2026-09-10  9:11 ` Carlos Maiolino

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ap5XiYSFR93gZOGl@andromeda.toxiclabs.cc \
    --to=cem@kernel.org \
    --cc=chengzhihao1@huawei.com \
    --cc=dgc@kernel.org \
    --cc=djwong@kernel.org \
    --cc=hch@lst.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-xfs@vger.kernel.org \
    --cc=wozizhi@huawei.com \
    --cc=wozizhi@huaweicloud.com \
    --cc=yangerkun@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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®