projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d9c0775
)
xfs: create a macro for decoding ftypes in tracepoints
author
Darrick J. Wong
<djwong@kernel.org>
Thu, 22 Feb 2024 20:30:50 +0000
(12:30 -0800)
committer
Darrick J. Wong
<djwong@kernel.org>
Thu, 22 Feb 2024 20:30:50 +0000
(12:30 -0800)
Create the XFS_DIR3_FTYPE_STR macro so that we can report ftype as
strings instead of numbers in tracepoints.
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
fs/xfs/libxfs/xfs_da_format.h
patch
|
blob
|
history
diff --git
a/fs/xfs/libxfs/xfs_da_format.h
b/fs/xfs/libxfs/xfs_da_format.h
index 24f9d1461f9a6f72442da9acbed5ed7251d908c0..060e5c96b70f63f73a72e2d0942aed5d6b161175 100644
(file)
--- a/
fs/xfs/libxfs/xfs_da_format.h
+++ b/
fs/xfs/libxfs/xfs_da_format.h
@@
-159,6
+159,17
@@
struct xfs_da3_intnode {
#define XFS_DIR3_FT_MAX 9
+#define XFS_DIR3_FTYPE_STR \
+ { XFS_DIR3_FT_UNKNOWN, "unknown" }, \
+ { XFS_DIR3_FT_REG_FILE, "file" }, \
+ { XFS_DIR3_FT_DIR, "directory" }, \
+ { XFS_DIR3_FT_CHRDEV, "char" }, \
+ { XFS_DIR3_FT_BLKDEV, "block" }, \
+ { XFS_DIR3_FT_FIFO, "fifo" }, \
+ { XFS_DIR3_FT_SOCK, "sock" }, \
+ { XFS_DIR3_FT_SYMLINK, "symlink" }, \
+ { XFS_DIR3_FT_WHT, "whiteout" }
+
/*
* Byte offset in data block and shortform entry.
*/