summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
Diffstat (limited to 'kernel')
-rw-r--r--kernel/panic.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/kernel/panic.c b/kernel/panic.c
index 1eccb0e0c749..84adabf00cf5 100644
--- a/kernel/panic.c
+++ b/kernel/panic.c
@@ -103,6 +103,10 @@ NORET_TYPE void panic(const char * fmt, ...)
/**
* print_tainted - return a string to represent the kernel taint state.
*
+ * 'P' - Proprietory module has been loaded.
+ * 'F' - Module has been forcibly loaded.
+ * 'S' - SMP with CPUs not designed for SMP.
+ *
* The string is overwritten by the next call to print_taint().
*/
@@ -110,9 +114,10 @@ const char *print_tainted()
{
static char buf[20];
if (tainted) {
- snprintf(buf, sizeof(buf), "Tainted: %c%c",
- tainted & 1 ? 'P' : 'G',
- tainted & 2 ? 'F' : ' ');
+ snprintf(buf, sizeof(buf), "Tainted: %c%c%c",
+ tainted & TAINT_PROPRIETORY_MODULE ? 'P' : 'G',
+ tainted & TAINT_FORCED_MODULE ? 'F' : ' ',
+ tainted & TAINT_UNSAFE_SMP ? 'S' : ' ');
}
else
snprintf(buf, sizeof(buf), "Not tainted");