X-Git-Url: http://pilppa.org/gitweb/gitweb.cgi?a=blobdiff_plain;f=kernel%2Fpanic.c;h=525e365f72390bb3fb4601c0be4c4bd81214eceb;hb=31cb4bd31a48f62105d037ad53192b94d4c08f53;hp=9b8dcfd1ca931e6f728c79655e4edead123a0f11;hpb=f834c755423332a6ff4397fae754029a6a7a8249;p=linux-2.6-omap-h63xx.git diff --git a/kernel/panic.c b/kernel/panic.c index 9b8dcfd1ca9..525e365f723 100644 --- a/kernel/panic.c +++ b/kernel/panic.c @@ -173,7 +173,7 @@ const char *print_tainted(void) void add_taint(unsigned flag) { - debug_locks_off(); /* can't trust the integrity of the kernel anymore */ + debug_locks = 0; /* can't trust the integrity of the kernel anymore */ tainted |= flag; } EXPORT_SYMBOL(add_taint); @@ -270,3 +270,15 @@ void oops_exit(void) { do_oops_enter_exit(); } + +#ifdef CONFIG_CC_STACKPROTECTOR +/* + * Called when gcc's -fstack-protector feature is used, and + * gcc detects corruption of the on-stack canary value + */ +void __stack_chk_fail(void) +{ + panic("stack-protector: Kernel stack is corrupted"); +} +EXPORT_SYMBOL(__stack_chk_fail); +#endif