* [PATCH] powerpc: Fix oops on some machines due to incorrect pr_debug()
@ 2009-02-01 22:53 Benjamin Herrenschmidt
0 siblings, 0 replies; only message in thread
From: Benjamin Herrenschmidt @ 2009-02-01 22:53 UTC (permalink / raw)
To: linuxppc-dev
Recently, a patch left DEBUG enabled in the powerpc common PCI code,
resulting in an old bug in a pr_debug() statement to show up and cause
a NULL dereference on some machines.
This fixes the pr_debug() statement and reverts to DEBUG not being
force-enabled in that file.
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
---
arch/powerpc/kernel/pci-common.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
--- linux-work.orig/arch/powerpc/kernel/pci-common.c 2009-01-30 14:32:34.000000000 +1100
+++ linux-work/arch/powerpc/kernel/pci-common.c 2009-02-02 09:51:48.000000000 +1100
@@ -16,7 +16,7 @@
* 2 of the License, or (at your option) any later version.
*/
-#define DEBUG
+#undef DEBUG
#include <linux/kernel.h>
#include <linux/pci.h>
@@ -258,7 +258,8 @@ int pci_read_irq_line(struct pci_dev *pc
} else {
pr_debug(" Got one, spec %d cells (0x%08x 0x%08x...) on %s\n",
oirq.size, oirq.specifier[0], oirq.specifier[1],
- oirq.controller->full_name);
+ oirq.controller ? oirq.controller->full_name :
+ "<default>");
virq = irq_create_of_mapping(oirq.controller, oirq.specifier,
oirq.size);
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2009-02-01 22:53 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-02-01 22:53 [PATCH] powerpc: Fix oops on some machines due to incorrect pr_debug() Benjamin Herrenschmidt
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).