x86: Factor duplicated code out of __show_regs() into show_regs_common()
Unify x86_32 and x86_64 implementations of __show_regs() header, standardizing on the x86_64 format string in the process. Also, 32-bit will now call print_modules. Signed-off-by: Andy Isaacson <adi@hexapodia.org> Cc: Arjan van de Ven <arjan@linux.intel.com> Cc: Robert Hancock <hancockrwd@gmail.com> Cc: Richard Zidlicky <rz@linux-m68k.org> Cc: Andrew Morton <akpm@linux-foundation.org> LKML-Reference: <20091208082942.GA27174@hexapodia.org> [ v2: resolved conflict ] Signed-off-by: Ingo Molnar <mingo@elte.hu>
This commit is contained in:

committed by
Ingo Molnar

parent
f58e1f53de
commit
814e2c84a7
@@ -10,6 +10,8 @@
|
||||
#include <linux/clockchips.h>
|
||||
#include <linux/random.h>
|
||||
#include <linux/user-return-notifier.h>
|
||||
#include <linux/dmi.h>
|
||||
#include <linux/utsname.h>
|
||||
#include <trace/events/power.h>
|
||||
#include <linux/hw_breakpoint.h>
|
||||
#include <asm/system.h>
|
||||
@@ -90,6 +92,22 @@ void exit_thread(void)
|
||||
}
|
||||
}
|
||||
|
||||
void show_regs_common(void)
|
||||
{
|
||||
const char *board;
|
||||
|
||||
board = dmi_get_system_info(DMI_PRODUCT_NAME);
|
||||
if (!board)
|
||||
board = "";
|
||||
|
||||
printk("\n");
|
||||
printk(KERN_INFO "Pid: %d, comm: %.20s %s %s %.*s %s\n",
|
||||
current->pid, current->comm, print_tainted(),
|
||||
init_utsname()->release,
|
||||
(int)strcspn(init_utsname()->version, " "),
|
||||
init_utsname()->version, board);
|
||||
}
|
||||
|
||||
void flush_thread(void)
|
||||
{
|
||||
struct task_struct *tsk = current;
|
||||
|
Reference in New Issue
Block a user