/*1* lib/bust_spinlocks.c2*3* Provides a minimal bust_spinlocks for architectures which don't have one of their own.4*5* bust_spinlocks() clears any spinlocks which would prevent oops, die(), BUG()6* and panic() information from reaching the user.7*/89#include <linux/kernel.h>10#include <linux/spinlock.h>11#include <linux/tty.h>12#include <linux/wait.h>13#include <linux/vt_kern.h>14#include <linux/console.h>151617void __attribute__((weak)) bust_spinlocks(int yes)18{19if (yes) {20++oops_in_progress;21} else {22#ifdef CONFIG_VT23unblank_screen();24#endif25console_unblank();26if (--oops_in_progress == 0)27wake_up_klogd();28}29}3031323334