[PATCH 1/2] UBUNTU: expose that this is an Ubuntu kernel in oops/panic messages
Andy Whitcroft
apw at canonical.com
Thu Nov 27 19:09:49 UTC 2008
In order to make it simpler for kerneloops to know it is dealing with
an Ubuntu modified kernel we have been requested to modify our version
strings to contain an Ubuntu marker. This changing out version string
will move our modules about and trigger all sorts of pain for our
packaging.
This patch proposes an alternative method of marking these oopses as
Ubuntu related. All oopses which contain the kernel release string also
contain the first word of the UTS_VERSION string, which is typically
the build number:
#define UTS_VERSION "#0 SMP Thu Nov 27 15:54:55 GMT 2008"
Note the #1 on the second line here:
WARNING: at /tmp/oops.c:5 modinit() (Not tainted)
Pid: 8190, comm: insmod Not tainted 2.6.24-0.77.rc4.git4.fc9 #1
[<c040649a>] show_trace_log_lvl+0x1a/0x2f
It would be possible to augment this build number to include some kind
of suffix to indicate that this was an Ubuntu build and have that
included in these panic strings:
#define UTS_VERSION "#0-UB SMP Thu Nov 27 15:54:55 GMT 2008"
Something like this (hand crafted):
WARNING: at /tmp/oops.c:5 modinit() (Not tainted)
Pid: 8190, comm: insmod Not tainted 2.6.24-0.77.rc4.git4.fc9 #1-UB
[<c040649a>] show_trace_log_lvl+0x1a/0x2f
As far as I can tell this value is not used anywhere else in our build
system so changing it in this way should be relativly benign.
Signed-off-by: Andy Whitcroft <apw at canonical.com>
---
scripts/mkcompile_h | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/scripts/mkcompile_h b/scripts/mkcompile_h
index a8740df..f52f8c5 100755
--- a/scripts/mkcompile_h
+++ b/scripts/mkcompile_h
@@ -39,7 +39,7 @@ else
TIMESTAMP=$KBUILD_BUILD_TIMESTAMP
fi
-UTS_VERSION="#$VERSION"
+UTS_VERSION="#$VERSION-UB"
CONFIG_FLAGS=""
if [ -n "$SMP" ] ; then CONFIG_FLAGS="SMP"; fi
if [ -n "$PREEMPT" ] ; then CONFIG_FLAGS="$CONFIG_FLAGS PREEMPT"; fi
--
1.6.0.4.911.gc990
More information about the kernel-team
mailing list