diff options
author | Christoph Hellwig <hch@lst.de> | 2019-11-08 14:57:49 -0800 |
---|---|---|
committer | Darrick J. Wong <darrick.wong@oracle.com> | 2019-11-10 16:54:19 -0800 |
commit | 3b34441309f364bba59a6ee5d1aa32206456142f (patch) | |
tree | e6ffc12afd7dab6c2b2c847797f56c4becf20329 /fs/xfs/libxfs/xfs_da_format.c | |
parent | 51908ca75feb5b2dd4f0d0146f9c92775520812c (diff) |
xfs: move the node header size to struct xfs_da_geometry
Move the node header size field to struct xfs_da_geometry, and remove
the now unused non-directory dir ops infrastructure.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Darrick J. Wong <darrick.wong@oracle.com>
Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Diffstat (limited to 'fs/xfs/libxfs/xfs_da_format.c')
-rw-r--r-- | fs/xfs/libxfs/xfs_da_format.c | 28 |
1 files changed, 0 insertions, 28 deletions
diff --git a/fs/xfs/libxfs/xfs_da_format.c b/fs/xfs/libxfs/xfs_da_format.c index f896d37c845f..68dff1de61e9 100644 --- a/fs/xfs/libxfs/xfs_da_format.c +++ b/fs/xfs/libxfs/xfs_da_format.c @@ -652,8 +652,6 @@ static const struct xfs_dir_ops xfs_dir2_ops = { .leaf_max_ents = xfs_dir2_max_leaf_ents, .leaf_ents_p = xfs_dir2_leaf_ents_p, - .node_hdr_size = sizeof(struct xfs_da_node_hdr), - .free_hdr_size = sizeof(struct xfs_dir2_free_hdr), .free_hdr_to_disk = xfs_dir2_free_hdr_to_disk, .free_hdr_from_disk = xfs_dir2_free_hdr_from_disk, @@ -699,8 +697,6 @@ static const struct xfs_dir_ops xfs_dir2_ftype_ops = { .leaf_max_ents = xfs_dir2_max_leaf_ents, .leaf_ents_p = xfs_dir2_leaf_ents_p, - .node_hdr_size = sizeof(struct xfs_da_node_hdr), - .free_hdr_size = sizeof(struct xfs_dir2_free_hdr), .free_hdr_to_disk = xfs_dir2_free_hdr_to_disk, .free_hdr_from_disk = xfs_dir2_free_hdr_from_disk, @@ -746,8 +742,6 @@ static const struct xfs_dir_ops xfs_dir3_ops = { .leaf_max_ents = xfs_dir3_max_leaf_ents, .leaf_ents_p = xfs_dir3_leaf_ents_p, - .node_hdr_size = sizeof(struct xfs_da3_node_hdr), - .free_hdr_size = sizeof(struct xfs_dir3_free_hdr), .free_hdr_to_disk = xfs_dir3_free_hdr_to_disk, .free_hdr_from_disk = xfs_dir3_free_hdr_from_disk, @@ -757,14 +751,6 @@ static const struct xfs_dir_ops xfs_dir3_ops = { .db_to_fdindex = xfs_dir3_db_to_fdindex, }; -static const struct xfs_dir_ops xfs_dir2_nondir_ops = { - .node_hdr_size = sizeof(struct xfs_da_node_hdr), -}; - -static const struct xfs_dir_ops xfs_dir3_nondir_ops = { - .node_hdr_size = sizeof(struct xfs_da3_node_hdr), -}; - /* * Return the ops structure according to the current config. If we are passed * an inode, then that overrides the default config we use which is based on @@ -785,17 +771,3 @@ xfs_dir_get_ops( return &xfs_dir2_ftype_ops; return &xfs_dir2_ops; } - -const struct xfs_dir_ops * -xfs_nondir_get_ops( - struct xfs_mount *mp, - struct xfs_inode *dp) -{ - if (dp) - return dp->d_ops; - if (mp->m_nondir_inode_ops) - return mp->m_nondir_inode_ops; - if (xfs_sb_version_hascrc(&mp->m_sb)) - return &xfs_dir3_nondir_ops; - return &xfs_dir2_nondir_ops; -} |