Linux XFS filesystem development
 help / color / mirror / Atom feed
From: Christoph Hellwig <hch@lst.de>
To: Carlos Maiolino <cem@kernel.org>
Cc: "Darrick J. Wong" <djwong@kernel.org>, linux-xfs@vger.kernel.org
Subject: [PATCH 3/4] xfs: move xfs_*_item.h to libxfs
Date: Fri, 25 Sep 2026 17:18:28 +0200	[thread overview]
Message-ID: <20260925151841.3385994-4-hch@lst.de> (raw)
In-Reply-To: <20260925151841.3385994-1-hch@lst.de>

All these files can be used as-is in xfsprogs to replace various shades
of copy and paste.

Signed-off-by: Christoph Hellwig <hch@lst.de>
---
 fs/xfs/{ => libxfs}/xfs_attr_item.h     | 2 --
 fs/xfs/{ => libxfs}/xfs_bmap_item.h     | 2 --
 fs/xfs/{ => libxfs}/xfs_buf_item.h      | 2 --
 fs/xfs/{ => libxfs}/xfs_dquot_item.h    | 0
 fs/xfs/{ => libxfs}/xfs_exchmaps_item.h | 2 --
 fs/xfs/{ => libxfs}/xfs_extfree_item.h  | 2 --
 fs/xfs/{ => libxfs}/xfs_icreate_item.h  | 0
 fs/xfs/{ => libxfs}/xfs_inode_item.h    | 2 --
 fs/xfs/{ => libxfs}/xfs_iunlink_item.h  | 0
 fs/xfs/{ => libxfs}/xfs_refcount_item.h | 2 --
 fs/xfs/{ => libxfs}/xfs_rmap_item.h     | 2 --
 11 files changed, 16 deletions(-)
 rename fs/xfs/{ => libxfs}/xfs_attr_item.h (97%)
 rename fs/xfs/{ => libxfs}/xfs_bmap_item.h (98%)
 rename fs/xfs/{ => libxfs}/xfs_buf_item.h (98%)
 rename fs/xfs/{ => libxfs}/xfs_dquot_item.h (100%)
 rename fs/xfs/{ => libxfs}/xfs_exchmaps_item.h (98%)
 rename fs/xfs/{ => libxfs}/xfs_extfree_item.h (98%)
 rename fs/xfs/{ => libxfs}/xfs_icreate_item.h (100%)
 rename fs/xfs/{ => libxfs}/xfs_inode_item.h (98%)
 rename fs/xfs/{ => libxfs}/xfs_iunlink_item.h (100%)
 rename fs/xfs/{ => libxfs}/xfs_refcount_item.h (98%)
 rename fs/xfs/{ => libxfs}/xfs_rmap_item.h (98%)

diff --git a/fs/xfs/xfs_attr_item.h b/fs/xfs/libxfs/xfs_attr_item.h
similarity index 97%
rename from fs/xfs/xfs_attr_item.h
rename to fs/xfs/libxfs/xfs_attr_item.h
index d108a11b55ae..3bb3d7108a90 100644
--- a/fs/xfs/xfs_attr_item.h
+++ b/fs/xfs/libxfs/xfs_attr_item.h
@@ -6,8 +6,6 @@
 #ifndef	__XFS_ATTR_ITEM_H__
 #define	__XFS_ATTR_ITEM_H__
 
-/* kernel only ATTRI/ATTRD definitions */
-
 struct xfs_mount;
 struct kmem_zone;
 
diff --git a/fs/xfs/xfs_bmap_item.h b/fs/xfs/libxfs/xfs_bmap_item.h
similarity index 98%
rename from fs/xfs/xfs_bmap_item.h
rename to fs/xfs/libxfs/xfs_bmap_item.h
index b42fee06899d..381b8a62b47c 100644
--- a/fs/xfs/xfs_bmap_item.h
+++ b/fs/xfs/libxfs/xfs_bmap_item.h
@@ -22,8 +22,6 @@
  * bmbt metadata updates in the non-first transaction.
  */
 
-/* kernel only BUI/BUD definitions */
-
 struct xfs_mount;
 struct kmem_cache;
 
diff --git a/fs/xfs/xfs_buf_item.h b/fs/xfs/libxfs/xfs_buf_item.h
similarity index 98%
rename from fs/xfs/xfs_buf_item.h
rename to fs/xfs/libxfs/xfs_buf_item.h
index 28c79989d725..d0a1247d22c6 100644
--- a/fs/xfs/xfs_buf_item.h
+++ b/fs/xfs/libxfs/xfs_buf_item.h
@@ -6,8 +6,6 @@
 #ifndef	__XFS_BUF_ITEM_H__
 #define	__XFS_BUF_ITEM_H__
 
-/* kernel only definitions */
-
 struct xfs_buf;
 struct xfs_mount;
 
diff --git a/fs/xfs/xfs_dquot_item.h b/fs/xfs/libxfs/xfs_dquot_item.h
similarity index 100%
rename from fs/xfs/xfs_dquot_item.h
rename to fs/xfs/libxfs/xfs_dquot_item.h
diff --git a/fs/xfs/xfs_exchmaps_item.h b/fs/xfs/libxfs/xfs_exchmaps_item.h
similarity index 98%
rename from fs/xfs/xfs_exchmaps_item.h
rename to fs/xfs/libxfs/xfs_exchmaps_item.h
index efa368d25d09..4a42f70237fb 100644
--- a/fs/xfs/xfs_exchmaps_item.h
+++ b/fs/xfs/libxfs/xfs_exchmaps_item.h
@@ -22,8 +22,6 @@
  * rest of the mapping exchanges.
  */
 
-/* kernel only XMI/XMD definitions */
-
 struct xfs_mount;
 struct kmem_cache;
 
diff --git a/fs/xfs/xfs_extfree_item.h b/fs/xfs/libxfs/xfs_extfree_item.h
similarity index 98%
rename from fs/xfs/xfs_extfree_item.h
rename to fs/xfs/libxfs/xfs_extfree_item.h
index af1b0331f7af..4d8ae7438b84 100644
--- a/fs/xfs/xfs_extfree_item.h
+++ b/fs/xfs/libxfs/xfs_extfree_item.h
@@ -6,8 +6,6 @@
 #ifndef	__XFS_EXTFREE_ITEM_H__
 #define	__XFS_EXTFREE_ITEM_H__
 
-/* kernel only EFI/EFD definitions */
-
 struct xfs_mount;
 struct kmem_cache;
 
diff --git a/fs/xfs/xfs_icreate_item.h b/fs/xfs/libxfs/xfs_icreate_item.h
similarity index 100%
rename from fs/xfs/xfs_icreate_item.h
rename to fs/xfs/libxfs/xfs_icreate_item.h
diff --git a/fs/xfs/xfs_inode_item.h b/fs/xfs/libxfs/xfs_inode_item.h
similarity index 98%
rename from fs/xfs/xfs_inode_item.h
rename to fs/xfs/libxfs/xfs_inode_item.h
index 2ddcca41714f..226c9ec01434 100644
--- a/fs/xfs/xfs_inode_item.h
+++ b/fs/xfs/libxfs/xfs_inode_item.h
@@ -6,8 +6,6 @@
 #ifndef	__XFS_INODE_ITEM_H__
 #define	__XFS_INODE_ITEM_H__
 
-/* kernel only definitions */
-
 struct xfs_buf;
 struct xfs_bmbt_rec;
 struct xfs_inode;
diff --git a/fs/xfs/xfs_iunlink_item.h b/fs/xfs/libxfs/xfs_iunlink_item.h
similarity index 100%
rename from fs/xfs/xfs_iunlink_item.h
rename to fs/xfs/libxfs/xfs_iunlink_item.h
diff --git a/fs/xfs/xfs_refcount_item.h b/fs/xfs/libxfs/xfs_refcount_item.h
similarity index 98%
rename from fs/xfs/xfs_refcount_item.h
rename to fs/xfs/libxfs/xfs_refcount_item.h
index 0fc3f493342b..c94b119624b3 100644
--- a/fs/xfs/xfs_refcount_item.h
+++ b/fs/xfs/libxfs/xfs_refcount_item.h
@@ -22,8 +22,6 @@
  * to replay the refcountbt metadata updates.
  */
 
-/* kernel only CUI/CUD definitions */
-
 struct xfs_mount;
 struct kmem_cache;
 
diff --git a/fs/xfs/xfs_rmap_item.h b/fs/xfs/libxfs/xfs_rmap_item.h
similarity index 98%
rename from fs/xfs/xfs_rmap_item.h
rename to fs/xfs/libxfs/xfs_rmap_item.h
index 3a99f0117f2d..8e9a23e89fd1 100644
--- a/fs/xfs/xfs_rmap_item.h
+++ b/fs/xfs/libxfs/xfs_rmap_item.h
@@ -25,8 +25,6 @@
  * (rmapbt/bnobt/cntbt) metadata updates in the non-first transaction.
  */
 
-/* kernel only RUI/RUD definitions */
-
 struct xfs_mount;
 struct kmem_cache;
 
-- 
2.53.0


  parent reply	other threads:[~2026-09-25 15:19 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-09-25 15:18 small cleanups to help code sharing with xfsprogs Christoph Hellwig
2026-09-25 15:18 ` [PATCH 1/4] xfs: remove various unused includes in libxfs/ Christoph Hellwig
2026-09-25 15:18 ` [PATCH 2/4] xfs: include <linux/iversion.h> in xfs_platform.h Christoph Hellwig
2026-09-25 15:18 ` Christoph Hellwig [this message]
2026-09-25 15:18 ` [PATCH 4/4] xfs: move xfs_trans.h to libxfs Christoph Hellwig
2026-09-25 22:52 ` small cleanups to help code sharing with xfsprogs Darrick J. Wong
2026-09-26  6:06   ` Christoph Hellwig
2026-10-05 10:02     ` Carlos Maiolino
2026-10-08 13:32 ` 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=20260925151841.3385994-4-hch@lst.de \
    --to=hch@lst.de \
    --cc=cem@kernel.org \
    --cc=djwong@kernel.org \
    --cc=linux-xfs@vger.kernel.org \
    /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