aboutsummaryrefslogtreecommitdiffstats
path: root/arch/ppc64
diff options
context:
space:
mode:
Diffstat (limited to 'arch/ppc64')
-rw-r--r--arch/ppc64/Kconfig.debug4
-rw-r--r--arch/ppc64/kernel/prom.c1
-rw-r--r--arch/ppc64/kernel/prom_init.c1
-rw-r--r--arch/ppc64/kernel/udbg.c55
4 files changed, 0 insertions, 61 deletions
diff --git a/arch/ppc64/Kconfig.debug b/arch/ppc64/Kconfig.debug
index f16a5030527b..b258c9314a1b 100644
--- a/arch/ppc64/Kconfig.debug
+++ b/arch/ppc64/Kconfig.debug
@@ -55,10 +55,6 @@ config XMON_DEFAULT
55 xmon is normally disabled unless booted with 'xmon=on'. 55 xmon is normally disabled unless booted with 'xmon=on'.
56 Use 'xmon=off' to disable xmon init during runtime. 56 Use 'xmon=off' to disable xmon init during runtime.
57 57
58config PPCDBG
59 bool "Include PPCDBG realtime debugging"
60 depends on DEBUG_KERNEL
61
62config IRQSTACKS 58config IRQSTACKS
63 bool "Use separate kernel stacks when processing interrupts" 59 bool "Use separate kernel stacks when processing interrupts"
64 help 60 help
diff --git a/arch/ppc64/kernel/prom.c b/arch/ppc64/kernel/prom.c
index 97bfceb5353b..a4cb97a25819 100644
--- a/arch/ppc64/kernel/prom.c
+++ b/arch/ppc64/kernel/prom.c
@@ -46,7 +46,6 @@
46#include <asm/pgtable.h> 46#include <asm/pgtable.h>
47#include <asm/pci.h> 47#include <asm/pci.h>
48#include <asm/iommu.h> 48#include <asm/iommu.h>
49#include <asm/ppcdebug.h>
50#include <asm/btext.h> 49#include <asm/btext.h>
51#include <asm/sections.h> 50#include <asm/sections.h>
52#include <asm/machdep.h> 51#include <asm/machdep.h>
diff --git a/arch/ppc64/kernel/prom_init.c b/arch/ppc64/kernel/prom_init.c
index a4bbca6dbb8b..e72b3f9061f0 100644
--- a/arch/ppc64/kernel/prom_init.c
+++ b/arch/ppc64/kernel/prom_init.c
@@ -44,7 +44,6 @@
44#include <asm/pgtable.h> 44#include <asm/pgtable.h>
45#include <asm/pci.h> 45#include <asm/pci.h>
46#include <asm/iommu.h> 46#include <asm/iommu.h>
47#include <asm/ppcdebug.h>
48#include <asm/btext.h> 47#include <asm/btext.h>
49#include <asm/sections.h> 48#include <asm/sections.h>
50#include <asm/machdep.h> 49#include <asm/machdep.h>
diff --git a/arch/ppc64/kernel/udbg.c b/arch/ppc64/kernel/udbg.c
index d49c3613c8ec..0d878e72fc44 100644
--- a/arch/ppc64/kernel/udbg.c
+++ b/arch/ppc64/kernel/udbg.c
@@ -10,12 +10,10 @@
10 */ 10 */
11 11
12#include <stdarg.h> 12#include <stdarg.h>
13#define WANT_PPCDBG_TAB /* Only defined here */
14#include <linux/config.h> 13#include <linux/config.h>
15#include <linux/types.h> 14#include <linux/types.h>
16#include <linux/sched.h> 15#include <linux/sched.h>
17#include <linux/console.h> 16#include <linux/console.h>
18#include <asm/ppcdebug.h>
19#include <asm/processor.h> 17#include <asm/processor.h>
20 18
21void (*udbg_putc)(unsigned char c); 19void (*udbg_putc)(unsigned char c);
@@ -89,59 +87,6 @@ void udbg_printf(const char *fmt, ...)
89 va_end(args); 87 va_end(args);
90} 88}
91 89
92/* PPCDBG stuff */
93
94u64 ppc64_debug_switch;
95
96/* Special print used by PPCDBG() macro */
97void udbg_ppcdbg(unsigned long debug_flags, const char *fmt, ...)
98{
99 unsigned long active_debugs = debug_flags & ppc64_debug_switch;
100
101 if (active_debugs) {
102 va_list ap;
103 unsigned char buf[UDBG_BUFSIZE];
104 unsigned long i, len = 0;
105
106 for (i=0; i < PPCDBG_NUM_FLAGS; i++) {
107 if (((1U << i) & active_debugs) &&
108 trace_names[i]) {
109 len += strlen(trace_names[i]);
110 udbg_puts(trace_names[i]);
111 break;
112 }
113 }
114
115 snprintf(buf, UDBG_BUFSIZE, " [%s]: ", current->comm);
116 len += strlen(buf);
117 udbg_puts(buf);
118
119 while (len < 18) {
120 udbg_puts(" ");
121 len++;
122 }
123
124 va_start(ap, fmt);
125 vsnprintf(buf, UDBG_BUFSIZE, fmt, ap);
126 udbg_puts(buf);
127 va_end(ap);
128 }
129}
130
131unsigned long udbg_ifdebug(unsigned long flags)
132{
133 return (flags & ppc64_debug_switch);
134}
135
136/*
137 * Initialize the PPCDBG state. Called before relocation has been enabled.
138 */
139void __init ppcdbg_initialize(void)
140{
141 ppc64_debug_switch = PPC_DEBUG_DEFAULT; /* | PPCDBG_BUSWALK | */
142 /* PPCDBG_PHBINIT | PPCDBG_MM | PPCDBG_MMINIT | PPCDBG_TCEINIT | PPCDBG_TCE */;
143}
144
145/* 90/*
146 * Early boot console based on udbg 91 * Early boot console based on udbg
147 */ 92 */