summaryrefslogtreecommitdiffstats
path: root/fs/xfs/xfs_message.c
diff options
context:
space:
mode:
authorDave Chinner <david@fromorbit.com>2015-10-12 09:38:25 +0200
committerDave Chinner <david@fromorbit.com>2015-10-12 09:38:25 +0200
commit1e2103cbf4adfd5490ee5f3ee59750bd70d2047e (patch)
treefb8256698fc1098784ef0bedba22768a793679f4 /fs/xfs/xfs_message.c
parentMerge branch 'xfs-io-fixes' into for-next (diff)
parentxfs: more info from kmem deadlocks and high-level error msgs (diff)
downloadlinux-1e2103cbf4adfd5490ee5f3ee59750bd70d2047e.tar.xz
linux-1e2103cbf4adfd5490ee5f3ee59750bd70d2047e.zip
Merge branch 'xfs-misc-fixes-for-4.4-1' into for-next
Diffstat (limited to 'fs/xfs/xfs_message.c')
-rw-r--r--fs/xfs/xfs_message.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/fs/xfs/xfs_message.c b/fs/xfs/xfs_message.c
index d8b67547ab34..11792d888e4e 100644
--- a/fs/xfs/xfs_message.c
+++ b/fs/xfs/xfs_message.c
@@ -17,6 +17,7 @@
#include "xfs.h"
#include "xfs_fs.h"
+#include "xfs_error.h"
#include "xfs_format.h"
#include "xfs_log_format.h"
#include "xfs_trans_resv.h"
@@ -43,6 +44,7 @@ void func(const struct xfs_mount *mp, const char *fmt, ...) \
{ \
struct va_format vaf; \
va_list args; \
+ int level; \
\
va_start(args, fmt); \
\
@@ -51,6 +53,11 @@ void func(const struct xfs_mount *mp, const char *fmt, ...) \
\
__xfs_printk(kern_level, mp, &vaf); \
va_end(args); \
+ \
+ if (!kstrtoint(kern_level, 0, &level) && \
+ level <= LOGLEVEL_ERR && \
+ xfs_error_level >= XFS_ERRLEVEL_HIGH) \
+ xfs_stack_trace(); \
} \
define_xfs_printk_level(xfs_emerg, KERN_EMERG);