summaryrefslogtreecommitdiff
path: root/sys/arch
diff options
context:
space:
mode:
authorBrad Smith <brad@cvs.openbsd.org>2004-12-18 03:05:25 +0000
committerBrad Smith <brad@cvs.openbsd.org>2004-12-18 03:05:25 +0000
commitfaf0b82756c37d8ba6e7918b45e93ed20b1d20cc (patch)
tree3e5b83a8eab2fb21099197d4f78c6f2b5348979b /sys/arch
parent2a260d4c1d82b7e7020a744e517df08fd6dfec0d (diff)
Print error codes in panic message.
From NetBSD ok miod@
Diffstat (limited to 'sys/arch')
-rw-r--r--sys/arch/sparc64/dev/psycho.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/arch/sparc64/dev/psycho.c b/sys/arch/sparc64/dev/psycho.c
index 651fdeed070..bde842df157 100644
--- a/sys/arch/sparc64/dev/psycho.c
+++ b/sys/arch/sparc64/dev/psycho.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: psycho.c,v 1.38 2003/12/20 20:08:17 miod Exp $ */
+/* $OpenBSD: psycho.c,v 1.39 2004/12/18 03:05:24 brad Exp $ */
/* $NetBSD: psycho.c,v 1.39 2001/10/07 20:30:41 eeh Exp $ */
/*
@@ -657,10 +657,11 @@ psycho_get_bus_range(node, brp)
int node;
int *brp;
{
- int n;
+ int n, error;
- if (getprop(node, "bus-range", sizeof(*brp), &n, (void **)&brp))
- panic("could not get psycho bus-range");
+ error = getprop(node, "bus-range", sizeof(*brp), &n, (void **)&brp);
+ if (error)
+ panic("could not get psycho bus-range, error %d", error);
if (n != 2)
panic("broken psycho bus-range");
DPRINTF(PDB_PROM,