aboutsummaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_dir2_readdir.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/xfs/xfs_dir2_readdir.c')
-rw-r--r--fs/xfs/xfs_dir2_readdir.c21
1 files changed, 1 insertions, 20 deletions
diff --git a/fs/xfs/xfs_dir2_readdir.c b/fs/xfs/xfs_dir2_readdir.c
index f1b69edcdf31..098cd78fe708 100644
--- a/fs/xfs/xfs_dir2_readdir.c
+++ b/fs/xfs/xfs_dir2_readdir.c
@@ -22,8 +22,6 @@
22#include "xfs_log_format.h" 22#include "xfs_log_format.h"
23#include "xfs_trans_resv.h" 23#include "xfs_trans_resv.h"
24#include "xfs_bit.h" 24#include "xfs_bit.h"
25#include "xfs_sb.h"
26#include "xfs_ag.h"
27#include "xfs_mount.h" 25#include "xfs_mount.h"
28#include "xfs_da_format.h" 26#include "xfs_da_format.h"
29#include "xfs_da_btree.h" 27#include "xfs_da_btree.h"
@@ -34,7 +32,6 @@
34#include "xfs_trace.h" 32#include "xfs_trace.h"
35#include "xfs_bmap.h" 33#include "xfs_bmap.h"
36#include "xfs_trans.h" 34#include "xfs_trans.h"
37#include "xfs_dinode.h"
38 35
39/* 36/*
40 * Directory file type support functions 37 * Directory file type support functions
@@ -44,7 +41,7 @@ static unsigned char xfs_dir3_filetype_table[] = {
44 DT_FIFO, DT_SOCK, DT_LNK, DT_WHT, 41 DT_FIFO, DT_SOCK, DT_LNK, DT_WHT,
45}; 42};
46 43
47unsigned char 44static unsigned char
48xfs_dir3_get_dtype( 45xfs_dir3_get_dtype(
49 struct xfs_mount *mp, 46 struct xfs_mount *mp,
50 __uint8_t filetype) 47 __uint8_t filetype)
@@ -57,22 +54,6 @@ xfs_dir3_get_dtype(
57 54
58 return xfs_dir3_filetype_table[filetype]; 55 return xfs_dir3_filetype_table[filetype];
59} 56}
60/*
61 * @mode, if set, indicates that the type field needs to be set up.
62 * This uses the transformation from file mode to DT_* as defined in linux/fs.h
63 * for file type specification. This will be propagated into the directory
64 * structure if appropriate for the given operation and filesystem config.
65 */
66const unsigned char xfs_mode_to_ftype[S_IFMT >> S_SHIFT] = {
67 [0] = XFS_DIR3_FT_UNKNOWN,
68 [S_IFREG >> S_SHIFT] = XFS_DIR3_FT_REG_FILE,
69 [S_IFDIR >> S_SHIFT] = XFS_DIR3_FT_DIR,
70 [S_IFCHR >> S_SHIFT] = XFS_DIR3_FT_CHRDEV,
71 [S_IFBLK >> S_SHIFT] = XFS_DIR3_FT_BLKDEV,
72 [S_IFIFO >> S_SHIFT] = XFS_DIR3_FT_FIFO,
73 [S_IFSOCK >> S_SHIFT] = XFS_DIR3_FT_SOCK,
74 [S_IFLNK >> S_SHIFT] = XFS_DIR3_FT_SYMLINK,
75};
76 57
77STATIC int 58STATIC int
78xfs_dir2_sf_getdents( 59xfs_dir2_sf_getdents(