linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/16] btrfs: split out larger chunks of ctree.h
@ 2022-09-14 17:18 Josef Bacik
  2022-09-14 17:18 ` [PATCH 01/16] btrfs: move fs wide helpers out " Josef Bacik
                   ` (17 more replies)
  0 siblings, 18 replies; 45+ messages in thread
From: Josef Bacik @ 2022-09-14 17:18 UTC (permalink / raw)
  To: linux-btrfs, kernel-team

Hello,

This series is based on the series

  btrfs: initial ctree.h cleanups, simple stuff

which needs to be in place before applying these patches.

This is likely going to have the largest patch of the series, which bulk moves
all of the struct funcs defines out of ctree.h into their own file.  This isn't
really possible to do piecemeal like other changes because we're using macros
instead of functions.  However the code is well organized so it allows for a
bulk copy and paste, so is straightforward.

I've done my best with naming, but I'm open to suggestions.  My general plan is
to have all fs wide definitions in fs.h, and then separate out individual things
to their own headers.

The biggest things I've done in this series are

1. Move the printk helpers into their own files.
2. Move the main state flags and core fs helpers into their own files.
3. Moved the struct func definitions to their own files.

This is by no means complete, this is just the first big pass, but as you can
see is already 17 patches long.  Subsequent patches will move more code and do
more cleanups.  Thanks,

Josef

Josef Bacik (16):
  btrfs: move fs wide helpers out of ctree.h
  btrfs: move larger compat flag helpers to their own c file
  btrfs: move the printk helpers out of ctree.h
  btrfs: push extra checks into __btrfs_abort_transaction
  btrfs: move assert and error helpers out of btrfs-printk.h
  btrfs: push printk index code into their respective helpers
  btrfs: move BTRFS_FS_STATE* defs and helpers to fs.h
  btrfs: move incompat and compat flag helpers to fs.c
  btrfs: move mount option definitions to fs.h
  btrfs: move fs_info->flags enum to fs.h
  btrfs: add a BTRFS_FS_NEED_TRANS_COMMIT flag
  btrfs: remove fs_info::pending_changes and related code
  btrfs: move the compat/incompat flag masks to fs.h
  btrfs: rename struct-funcs.c -> item-accessors.c
  btrfs: move btrfs_map_token to item-accessors
  btrfs: move accessor helpers into item-accessors.h

 fs/btrfs/Makefile                             |    4 +-
 fs/btrfs/backref.c                            |    2 +
 fs/btrfs/backref.h                            |    1 +
 fs/btrfs/block-group.c                        |    2 +
 fs/btrfs/block-rsv.c                          |    2 +
 fs/btrfs/btrfs-printk.h                       |  206 ++
 fs/btrfs/check-integrity.c                    |    2 +
 fs/btrfs/compression.c                        |    1 +
 fs/btrfs/ctree.c                              |    3 +
 fs/btrfs/ctree.h                              | 1784 +----------------
 fs/btrfs/delalloc-space.c                     |    2 +
 fs/btrfs/delayed-inode.c                      |    3 +
 fs/btrfs/delayed-ref.c                        |    2 +
 fs/btrfs/dev-replace.c                        |    2 +
 fs/btrfs/dir-item.c                           |    2 +
 fs/btrfs/discard.c                            |    1 +
 fs/btrfs/disk-io.c                            |    8 +-
 fs/btrfs/export.c                             |    1 +
 fs/btrfs/extent-io-tree.c                     |    1 +
 fs/btrfs/extent-tree.c                        |    2 +
 fs/btrfs/extent_io.c                          |    2 +
 fs/btrfs/extent_map.c                         |    1 +
 fs/btrfs/file-item.c                          |    3 +
 fs/btrfs/file.c                               |    2 +
 fs/btrfs/free-space-cache.c                   |    3 +
 fs/btrfs/free-space-tree.c                    |    3 +
 fs/btrfs/fs.c                                 |  108 +
 fs/btrfs/fs.h                                 |  320 +++
 fs/btrfs/inode-item.c                         |    2 +
 fs/btrfs/inode.c                              |    2 +
 fs/btrfs/ioctl.c                              |    2 +
 fs/btrfs/{struct-funcs.c => item-accessors.c} |   10 +
 fs/btrfs/item-accessors.h                     | 1104 ++++++++++
 fs/btrfs/lzo.c                                |    1 +
 fs/btrfs/ordered-data.c                       |    1 +
 fs/btrfs/print-tree.c                         |    2 +
 fs/btrfs/props.c                              |    3 +
 fs/btrfs/qgroup.c                             |    2 +
 fs/btrfs/raid56.c                             |    1 +
 fs/btrfs/ref-verify.c                         |    3 +
 fs/btrfs/reflink.c                            |    2 +
 fs/btrfs/relocation.c                         |    2 +
 fs/btrfs/root-tree.c                          |    3 +
 fs/btrfs/scrub.c                              |    2 +
 fs/btrfs/send.c                               |    1 +
 fs/btrfs/space-info.c                         |    2 +
 fs/btrfs/subpage.c                            |    1 +
 fs/btrfs/super.c                              |   51 +-
 fs/btrfs/sysfs.c                              |    7 +-
 fs/btrfs/tests/btrfs-tests.c                  |    1 +
 fs/btrfs/tests/extent-buffer-tests.c          |    1 +
 fs/btrfs/tests/free-space-tree-tests.c        |    1 +
 fs/btrfs/tests/inode-tests.c                  |    1 +
 fs/btrfs/tests/qgroup-tests.c                 |    2 +
 fs/btrfs/transaction.c                        |   29 +-
 fs/btrfs/transaction.h                        |    1 -
 fs/btrfs/tree-checker.c                       |    3 +
 fs/btrfs/tree-defrag.c                        |    1 +
 fs/btrfs/tree-log.c                           |    2 +
 fs/btrfs/tree-log.h                           |    1 +
 fs/btrfs/tree-mod-log.c                       |    3 +
 fs/btrfs/ulist.c                              |    1 +
 fs/btrfs/uuid-tree.c                          |    4 +-
 fs/btrfs/verity.c                             |    3 +
 fs/btrfs/volumes.c                            |    2 +
 fs/btrfs/xattr.c                              |    2 +
 fs/btrfs/zoned.c                              |    2 +
 fs/btrfs/zoned.h                              |    1 +
 68 files changed, 1915 insertions(+), 1823 deletions(-)
 create mode 100644 fs/btrfs/btrfs-printk.h
 create mode 100644 fs/btrfs/fs.c
 create mode 100644 fs/btrfs/fs.h
 rename fs/btrfs/{struct-funcs.c => item-accessors.c} (96%)
 create mode 100644 fs/btrfs/item-accessors.h

-- 
2.26.3


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

end of thread, other threads:[~2022-10-11 12:02 UTC | newest]

Thread overview: 45+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-09-14 17:18 [PATCH 00/16] btrfs: split out larger chunks of ctree.h Josef Bacik
2022-09-14 17:18 ` [PATCH 01/16] btrfs: move fs wide helpers out " Josef Bacik
2022-09-16 10:34   ` Anand Jain
2022-09-14 17:18 ` [PATCH 02/16] btrfs: move larger compat flag helpers to their own c file Josef Bacik
2022-09-16 11:11   ` Anand Jain
2022-09-16 11:30     ` Anand Jain
2022-10-11  9:46     ` David Sterba
2022-09-14 17:18 ` [PATCH 03/16] btrfs: move the printk helpers out of ctree.h Josef Bacik
2022-09-16 12:13   ` Anand Jain
2022-09-14 17:18 ` [PATCH 04/16] btrfs: push extra checks into __btrfs_abort_transaction Josef Bacik
2022-09-16 12:28   ` Anand Jain
2022-10-11  9:55   ` David Sterba
2022-09-14 17:18 ` [PATCH 05/16] btrfs: move assert and error helpers out of btrfs-printk.h Josef Bacik
2022-09-16 13:21   ` Anand Jain
2022-09-14 17:18 ` [PATCH 06/16] btrfs: push printk index code into their respective helpers Josef Bacik
2022-09-19 12:24   ` Anand Jain
2022-09-14 17:18 ` [PATCH 07/16] btrfs: move BTRFS_FS_STATE* defs and helpers to fs.h Josef Bacik
2022-09-19 12:25   ` Anand Jain
2022-09-14 17:18 ` [PATCH 08/16] btrfs: move incompat and compat flag helpers to fs.c Josef Bacik
2022-09-19 12:26   ` Anand Jain
2022-10-11 10:33   ` David Sterba
2022-10-11 12:01     ` David Sterba
2022-09-14 17:18 ` [PATCH 09/16] btrfs: move mount option definitions to fs.h Josef Bacik
2022-09-19 12:26   ` Anand Jain
2022-09-14 17:18 ` [PATCH 10/16] btrfs: move fs_info->flags enum " Josef Bacik
2022-09-19 12:27   ` Anand Jain
2022-09-14 17:18 ` [PATCH 11/16] btrfs: add a BTRFS_FS_NEED_TRANS_COMMIT flag Josef Bacik
2022-09-19 12:30   ` Anand Jain
2022-09-19 12:33     ` Anand Jain
2022-09-14 17:18 ` [PATCH 12/16] btrfs: remove fs_info::pending_changes and related code Josef Bacik
2022-09-19 12:41   ` Anand Jain
2022-10-11 10:20   ` David Sterba
2022-09-14 17:18 ` [PATCH 13/16] btrfs: move the compat/incompat flag masks to fs.h Josef Bacik
2022-09-19 12:44   ` Anand Jain
2022-09-14 17:18 ` [PATCH 14/16] btrfs: rename struct-funcs.c -> item-accessors.c Josef Bacik
2022-09-19 12:46   ` Anand Jain
2022-09-14 17:18 ` [PATCH 15/16] btrfs: move btrfs_map_token to item-accessors Josef Bacik
2022-09-19 12:53   ` Anand Jain
2022-10-11 10:39   ` David Sterba
2022-10-11 11:37     ` David Sterba
2022-09-14 17:18 ` [PATCH 16/16] btrfs: move accessor helpers into item-accessors.h Josef Bacik
2022-09-15  8:27   ` Anand Jain
2022-09-15  9:51 ` [PATCH 00/16] btrfs: split out larger chunks of ctree.h Qu Wenruo
2022-10-11 10:48   ` David Sterba
2022-10-10 20:28 ` David Sterba

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).