]> git.ipfire.org Git - thirdparty/xfsprogs-dev.git/commitdiff
xfs: fix symbolic enum printing in ftrace output
authorDarrick J. Wong <darrick.wong@oracle.com>
Wed, 27 Feb 2019 23:13:45 +0000 (17:13 -0600)
committerEric Sandeen <sandeen@redhat.com>
Wed, 27 Feb 2019 23:13:45 +0000 (17:13 -0600)
Source kernel commit: 85f8dff00a3193fe5659aa4c91adde31723c0d3d

ftrace's __print_symbolic() has a (very poorly documented) requirement
that any enum values used in the symbol to string translation table be
wrapped in a TRACE_DEFINE_ENUM so that the enum value can be encoded in
the ftrace ring buffer.  Fix this unsatisfied requirement.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: Eric Sandeen <sandeen@redhat.com>
Signed-off-by: Eric Sandeen <sandeen@sandeen.net>
libxfs/xfs_types.h

index b9e6c89284c392063ee6dc50ddd47a542b50275e..9a6541872ec10129b0ab25b0522c1e9fea09d04a 100644 (file)
@@ -100,6 +100,10 @@ typedef void *             xfs_failaddr_t;
  */
 #define MAXNAMELEN     256
 
+/*
+ * This enum is used in string mapping in xfs_trace.h; please keep the
+ * TRACE_DEFINE_ENUMs for it up to date.
+ */
 typedef enum {
        XFS_LOOKUP_EQi, XFS_LOOKUP_LEi, XFS_LOOKUP_GEi
 } xfs_lookup_t;