diff options
Diffstat (limited to 'fs/xfs/xfs_error.c')
-rw-r--r-- | fs/xfs/xfs_error.c | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/fs/xfs/xfs_error.c b/fs/xfs/xfs_error.c index 03028906f00e..39f06336b99d 100644 --- a/fs/xfs/xfs_error.c +++ b/fs/xfs/xfs_error.c | |||
@@ -48,7 +48,7 @@ xfs_error_trap(int e) | |||
48 | break; | 48 | break; |
49 | if (e != xfs_etrap[i]) | 49 | if (e != xfs_etrap[i]) |
50 | continue; | 50 | continue; |
51 | cmn_err(CE_NOTE, "xfs_error_trap: error %d", e); | 51 | xfs_notice(NULL, "%s: error %d", __func__, e); |
52 | BUG(); | 52 | BUG(); |
53 | break; | 53 | break; |
54 | } | 54 | } |
@@ -74,7 +74,7 @@ xfs_error_test(int error_tag, int *fsidp, char *expression, | |||
74 | 74 | ||
75 | for (i = 0; i < XFS_NUM_INJECT_ERROR; i++) { | 75 | for (i = 0; i < XFS_NUM_INJECT_ERROR; i++) { |
76 | if (xfs_etest[i] == error_tag && xfs_etest_fsid[i] == fsid) { | 76 | if (xfs_etest[i] == error_tag && xfs_etest_fsid[i] == fsid) { |
77 | cmn_err(CE_WARN, | 77 | xfs_warn(NULL, |
78 | "Injecting error (%s) at file %s, line %d, on filesystem \"%s\"", | 78 | "Injecting error (%s) at file %s, line %d, on filesystem \"%s\"", |
79 | expression, file, line, xfs_etest_fsname[i]); | 79 | expression, file, line, xfs_etest_fsname[i]); |
80 | return 1; | 80 | return 1; |
@@ -95,14 +95,14 @@ xfs_errortag_add(int error_tag, xfs_mount_t *mp) | |||
95 | 95 | ||
96 | for (i = 0; i < XFS_NUM_INJECT_ERROR; i++) { | 96 | for (i = 0; i < XFS_NUM_INJECT_ERROR; i++) { |
97 | if (xfs_etest_fsid[i] == fsid && xfs_etest[i] == error_tag) { | 97 | if (xfs_etest_fsid[i] == fsid && xfs_etest[i] == error_tag) { |
98 | cmn_err(CE_WARN, "XFS error tag #%d on", error_tag); | 98 | xfs_warn(mp, "error tag #%d on", error_tag); |
99 | return 0; | 99 | return 0; |
100 | } | 100 | } |
101 | } | 101 | } |
102 | 102 | ||
103 | for (i = 0; i < XFS_NUM_INJECT_ERROR; i++) { | 103 | for (i = 0; i < XFS_NUM_INJECT_ERROR; i++) { |
104 | if (xfs_etest[i] == 0) { | 104 | if (xfs_etest[i] == 0) { |
105 | cmn_err(CE_WARN, "Turned on XFS error tag #%d", | 105 | xfs_warn(mp, "Turned on XFS error tag #%d", |
106 | error_tag); | 106 | error_tag); |
107 | xfs_etest[i] = error_tag; | 107 | xfs_etest[i] = error_tag; |
108 | xfs_etest_fsid[i] = fsid; | 108 | xfs_etest_fsid[i] = fsid; |
@@ -114,7 +114,7 @@ xfs_errortag_add(int error_tag, xfs_mount_t *mp) | |||
114 | } | 114 | } |
115 | } | 115 | } |
116 | 116 | ||
117 | cmn_err(CE_WARN, "error tag overflow, too many turned on"); | 117 | xfs_warn(mp, "error tag overflow, too many turned on"); |
118 | 118 | ||
119 | return 1; | 119 | return 1; |
120 | } | 120 | } |
@@ -133,7 +133,7 @@ xfs_errortag_clearall(xfs_mount_t *mp, int loud) | |||
133 | if ((fsid == 0LL || xfs_etest_fsid[i] == fsid) && | 133 | if ((fsid == 0LL || xfs_etest_fsid[i] == fsid) && |
134 | xfs_etest[i] != 0) { | 134 | xfs_etest[i] != 0) { |
135 | cleared = 1; | 135 | cleared = 1; |
136 | cmn_err(CE_WARN, "Clearing XFS error tag #%d", | 136 | xfs_warn(mp, "Clearing XFS error tag #%d", |
137 | xfs_etest[i]); | 137 | xfs_etest[i]); |
138 | xfs_etest[i] = 0; | 138 | xfs_etest[i] = 0; |
139 | xfs_etest_fsid[i] = 0LL; | 139 | xfs_etest_fsid[i] = 0LL; |
@@ -144,9 +144,7 @@ xfs_errortag_clearall(xfs_mount_t *mp, int loud) | |||
144 | } | 144 | } |
145 | 145 | ||
146 | if (loud || cleared) | 146 | if (loud || cleared) |
147 | cmn_err(CE_WARN, | 147 | xfs_warn(mp, "Cleared all XFS error tags for filesystem"); |
148 | "Cleared all XFS error tags for filesystem \"%s\"", | ||
149 | mp->m_fsname); | ||
150 | 148 | ||
151 | return 0; | 149 | return 0; |
152 | } | 150 | } |