summaryrefslogtreecommitdiff
path: root/sys/arch/m88k
diff options
context:
space:
mode:
Diffstat (limited to 'sys/arch/m88k')
-rw-r--r--sys/arch/m88k/m88k/db_interface.c58
-rw-r--r--sys/arch/m88k/m88k/m88k_machdep.c42
-rw-r--r--sys/arch/m88k/m88k/pmap.c14
-rw-r--r--sys/arch/m88k/m88k/trap.c12
4 files changed, 63 insertions, 63 deletions
diff --git a/sys/arch/m88k/m88k/db_interface.c b/sys/arch/m88k/m88k/db_interface.c
index 81f5d1101b3..2ecd2250621 100644
--- a/sys/arch/m88k/m88k/db_interface.c
+++ b/sys/arch/m88k/m88k/db_interface.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_interface.c,v 1.18 2011/10/25 18:38:06 miod Exp $ */
+/* $OpenBSD: db_interface.c,v 1.19 2014/05/08 22:17:33 miod Exp $ */
/*
* Mach Operating System
* Copyright (c) 1993-1991 Carnegie Mellon University
@@ -221,19 +221,19 @@ m88k_db_print_frame(addr, have_addr, count, modif)
#define R(i) s->tf_r[i]
#define IPMASK(x) ((x) & ~(3))
- db_printf("R00-05: 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x\n",
+ db_printf("R00-05: 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n",
R(0), R(1), R(2), R(3), R(4), R(5));
- db_printf("R06-11: 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x\n",
+ db_printf("R06-11: 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n",
R(6), R(7), R(8), R(9), R(10), R(11));
- db_printf("R12-17: 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x\n",
+ db_printf("R12-17: 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n",
R(12), R(13), R(14), R(15), R(16), R(17));
- db_printf("R18-23: 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x\n",
+ db_printf("R18-23: 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n",
R(18), R(19), R(20), R(21), R(22), R(23));
- db_printf("R24-29: 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x\n",
+ db_printf("R24-29: 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n",
R(24), R(25), R(26), R(27), R(28), R(29));
- db_printf("R30-31: 0x%08x 0x%08x\n", R(30), R(31));
+ db_printf("R30-31: 0x%08lx 0x%08lx\n", R(30), R(31));
- db_printf("%cxip: 0x%08x ",
+ db_printf("%cxip: 0x%08lx ",
CPU_IS88110 ? 'e' : 's', s->tf_sxip & XIP_ADDR);
db_find_xtrn_sym_and_offset((db_addr_t)IPMASK(s->tf_sxip),
&name, &offset);
@@ -242,7 +242,7 @@ m88k_db_print_frame(addr, have_addr, count, modif)
db_printf("\n");
if (s->tf_snip != s->tf_sxip + 4) {
- db_printf("%cnip: 0x%08x ",
+ db_printf("%cnip: 0x%08lx ",
CPU_IS88110 ? 'e' : 's', s->tf_snip);
db_find_xtrn_sym_and_offset((db_addr_t)IPMASK(s->tf_snip),
&name, &offset);
@@ -254,7 +254,7 @@ m88k_db_print_frame(addr, have_addr, count, modif)
#ifdef M88100
if (CPU_IS88100) {
if (s->tf_sfip != s->tf_snip + 4) {
- db_printf("sfip: 0x%08x ", s->tf_sfip);
+ db_printf("sfip: 0x%08lx ", s->tf_sfip);
db_find_xtrn_sym_and_offset((db_addr_t)IPMASK(s->tf_sfip),
&name, &offset);
if (name != NULL && (u_int)offset <= db_maxoff)
@@ -265,18 +265,18 @@ m88k_db_print_frame(addr, have_addr, count, modif)
#endif
#ifdef M88110
if (CPU_IS88110) {
- db_printf("fpsr: 0x%08x fpcr: 0x%08x fpecr: 0x%08x\n",
+ db_printf("fpsr: 0x%08lx fpcr: 0x%08lx fpecr: 0x%08lx\n",
s->tf_fpsr, s->tf_fpcr, s->tf_fpecr);
- db_printf("dsap 0x%08x duap 0x%08x dsr 0x%08x dlar 0x%08x dpar 0x%08x\n",
+ db_printf("dsap 0x%08lx duap 0x%08lx dsr 0x%08lx dlar 0x%08lx dpar 0x%08lx\n",
s->tf_dsap, s->tf_duap, s->tf_dsr, s->tf_dlar, s->tf_dpar);
- db_printf("isap 0x%08x iuap 0x%08x isr 0x%08x ilar 0x%08x ipar 0x%08x\n",
+ db_printf("isap 0x%08lx iuap 0x%08lx isr 0x%08lx ilar 0x%08lx ipar 0x%08lx\n",
s->tf_isap, s->tf_iuap, s->tf_isr, s->tf_ilar, s->tf_ipar);
}
#endif
- db_printf("epsr: 0x%08x current process: %p\n",
+ db_printf("epsr: 0x%08lx current process: %p\n",
s->tf_epsr, curproc);
- db_printf("vector: 0x%02x interrupt mask: 0x%08x\n",
+ db_printf("vector: 0x%02lx interrupt mask: 0x%08lx\n",
s->tf_vector, s->tf_mask);
/*
@@ -294,7 +294,7 @@ m88k_db_print_frame(addr, have_addr, count, modif)
#ifdef M88100
if (CPU_IS88100) {
if (s->tf_vector == /*data*/3 || s->tf_dmt0 & DMT_VALID) {
- db_printf("dmt,d,a0: 0x%08x 0x%08x 0x%08x ",
+ db_printf("dmt,d,a0: 0x%08lx 0x%08lx 0x%08lx ",
s->tf_dmt0, s->tf_dmd0, s->tf_dma0);
db_find_xtrn_sym_and_offset((db_addr_t)s->tf_dma0,
&name, &offset);
@@ -307,7 +307,7 @@ m88k_db_print_frame(addr, have_addr, count, modif)
db_printf("\n");
if ((s->tf_dmt1 & DMT_VALID) && (!suppress1)) {
- db_printf("dmt,d,a1: 0x%08x 0x%08x 0x%08x ",
+ db_printf("dmt,d,a1: 0x%08lx 0x%08lx 0x%08lx ",
s->tf_dmt1, s->tf_dmd1, s->tf_dma1);
db_find_xtrn_sym_and_offset((db_addr_t)s->tf_dma1,
&name, &offset);
@@ -320,7 +320,7 @@ m88k_db_print_frame(addr, have_addr, count, modif)
db_printf("\n");
if ((s->tf_dmt2 & DMT_VALID) && (!suppress2)) {
- db_printf("dmt,d,a2: 0x%08x 0x%08x 0x%08x ",
+ db_printf("dmt,d,a2: 0x%08lx 0x%08lx 0x%08lx ",
s->tf_dmt2, s->tf_dmd2, s->tf_dma2);
db_find_xtrn_sym_and_offset((db_addr_t)s->tf_dma2,
&name, &offset);
@@ -335,20 +335,20 @@ m88k_db_print_frame(addr, have_addr, count, modif)
}
}
- db_printf("fault code %d\n",
+ db_printf("fault code %ld\n",
CMMU_PFSR_FAULT(s->tf_dpfsr));
}
}
#endif /* M88100 */
if (s->tf_fpecr & 255) { /* floating point error occurred */
- db_printf("fpecr: 0x%08x fpsr: 0x%08x fpcr: 0x%08x\n",
+ db_printf("fpecr: 0x%08lx fpsr: 0x%08lx fpcr: 0x%08lx\n",
s->tf_fpecr, s->tf_fpsr, s->tf_fpcr);
#ifdef M88100
if (CPU_IS88100) {
- db_printf("fcr1-4: 0x%08x 0x%08x 0x%08x 0x%08x\n",
+ db_printf("fcr1-4: 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n",
s->tf_fphs1, s->tf_fpls1, s->tf_fphs2, s->tf_fpls2);
- db_printf("fcr5-8: 0x%08x 0x%08x 0x%08x 0x%08x\n",
+ db_printf("fcr5-8: 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n",
s->tf_fppt, s->tf_fprh, s->tf_fprl, s->tf_fpit);
}
#endif
@@ -563,7 +563,7 @@ m88k_db_where(addr, have_addr, count, modif)
db_find_xtrn_sym_and_offset(l, &name, &offset);
if (name && (u_int)offset <= db_maxoff)
- db_printf("stopped at 0x%lx (%s+0x%x)\n", l, name, offset);
+ db_printf("stopped at 0x%lx (%s+0x%lx)\n", l, name, offset);
else
db_printf("stopped at 0x%lx\n", l);
}
@@ -592,11 +592,11 @@ m88k_db_frame_search(addr, have_addr, count, modif)
/* walk back up stack until 8k boundry, looking for 0 */
while (addr & ((8 * 1024) - 1)) {
if (frame_is_sane((db_regs_t *)addr, 1) != 0)
- db_printf("frame found at 0x%x\n", addr);
+ db_printf("frame found at 0x%lx\n", addr);
addr += 4;
}
- db_printf("(Walked back until 0x%x)\n",addr);
+ db_printf("(Walked back until 0x%lx)\n",addr);
}
#ifdef MULTIPROCESSOR
@@ -616,7 +616,7 @@ m88k_db_cpu_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
ddb_mp_nextcpu = cpu;
db_cmd_loop_done = 1;
} else {
- db_printf("cpu%d is not active\n", cpu);
+ db_printf("cpu%ld is not active\n", cpu);
}
return;
}
@@ -641,10 +641,10 @@ m88k_db_cpu_cmd(db_expr_t addr, int have_addr, db_expr_t count, char *modif)
ci->ci_ddb_state);
break;
}
- db_printf("%ccpu%1d %02x %-14s %08x %08x %3d %08x\n",
+ db_printf("%ccpu%d %02x %-14s %08lx %08lx %3u %08x\n",
(cpu == cpu_number()) ? '*' : ' ', CPU_INFO_UNIT(ci),
- ci->ci_flags, state, ci->ci_curproc, ci->ci_curpcb,
- ci->ci_intrdepth, ci->ci_ipi);
+ ci->ci_flags, state, (register_t)ci->ci_curproc,
+ (register_t)ci->ci_curpcb, ci->ci_intrdepth, ci->ci_ipi);
}
}
diff --git a/sys/arch/m88k/m88k/m88k_machdep.c b/sys/arch/m88k/m88k/m88k_machdep.c
index baa69f81ec7..d1a52908ee1 100644
--- a/sys/arch/m88k/m88k/m88k_machdep.c
+++ b/sys/arch/m88k/m88k/m88k_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: m88k_machdep.c,v 1.59 2014/03/29 18:09:29 guenther Exp $ */
+/* $OpenBSD: m88k_machdep.c,v 1.60 2014/05/08 22:17:33 miod Exp $ */
/*
* Copyright (c) 1998, 1999, 2000, 2001 Steve Murphree, Jr.
* Copyright (c) 1996 Nivas Madhur
@@ -242,60 +242,60 @@ void
regdump(struct trapframe *f)
{
#define R(i) f->tf_r[i]
- printf("R00-05: 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x\n",
+ printf("R00-05: 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n",
R(0),R(1),R(2),R(3),R(4),R(5));
- printf("R06-11: 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x\n",
+ printf("R06-11: 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n",
R(6),R(7),R(8),R(9),R(10),R(11));
- printf("R12-17: 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x\n",
+ printf("R12-17: 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n",
R(12),R(13),R(14),R(15),R(16),R(17));
- printf("R18-23: 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x\n",
+ printf("R18-23: 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n",
R(18),R(19),R(20),R(21),R(22),R(23));
- printf("R24-29: 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x 0x%08x\n",
+ printf("R24-29: 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx 0x%08lx\n",
R(24),R(25),R(26),R(27),R(28),R(29));
- printf("R30-31: 0x%08x 0x%08x\n",R(30),R(31));
+ printf("R30-31: 0x%08lx 0x%08lx\n",R(30),R(31));
#ifdef M88110
if (CPU_IS88110) {
- printf("exip %x enip %x\n", f->tf_exip, f->tf_enip);
+ printf("exip %lx enip %lx\n", f->tf_exip, f->tf_enip);
}
#endif
#ifdef M88100
if (CPU_IS88100) {
- printf("sxip %x snip %x sfip %x\n",
+ printf("sxip %lx snip %lx sfip %lx\n",
f->tf_sxip, f->tf_snip, f->tf_sfip);
}
if (CPU_IS88100 && f->tf_vector == 0x3) {
/* print dmt stuff for data access fault */
- printf("dmt0 %x dmd0 %x dma0 %x\n",
+ printf("dmt0 %lx dmd0 %lx dma0 %lx\n",
f->tf_dmt0, f->tf_dmd0, f->tf_dma0);
- printf("dmt1 %x dmd1 %x dma1 %x\n",
+ printf("dmt1 %lx dmd1 %lx dma1 %lx\n",
f->tf_dmt1, f->tf_dmd1, f->tf_dma1);
- printf("dmt2 %x dmd2 %x dma2 %x\n",
+ printf("dmt2 %lx dmd2 %lx dma2 %lx\n",
f->tf_dmt2, f->tf_dmd2, f->tf_dma2);
- printf("fault type %d\n", (f->tf_dpfsr >> 16) & 0x7);
+ printf("fault type %ld\n", (f->tf_dpfsr >> 16) & 0x7);
dae_print((u_int *)f);
}
if (CPU_IS88100 && longformat != 0) {
- printf("fpsr %x fpcr %x epsr %x ssbr %x\n",
+ printf("fpsr %lx fpcr %lx epsr %lx ssbr %lx\n",
f->tf_fpsr, f->tf_fpcr, f->tf_epsr, f->tf_ssbr);
- printf("fpecr %x fphs1 %x fpls1 %x fphs2 %x fpls2 %x\n",
+ printf("fpecr %lx fphs1 %lx fpls1 %lx fphs2 %lx fpls2 %lx\n",
f->tf_fpecr, f->tf_fphs1, f->tf_fpls1,
f->tf_fphs2, f->tf_fpls2);
- printf("fppt %x fprh %x fprl %x fpit %x\n",
+ printf("fppt %lx fprh %lx fprl %lx fpit %lx\n",
f->tf_fppt, f->tf_fprh, f->tf_fprl, f->tf_fpit);
- printf("vector %d mask %x flags %x scratch1 %x cpu %p\n",
+ printf("vector %ld mask %lx flags %lx scratch1 %lx cpu %p\n",
f->tf_vector, f->tf_mask, f->tf_flags,
f->tf_scratch1, f->tf_cpu);
}
#endif
#ifdef M88110
if (CPU_IS88110 && longformat != 0) {
- printf("fpsr %x fpcr %x fpecr %x epsr %x\n",
+ printf("fpsr %lx fpcr %lx fpecr %lx epsr %lx\n",
f->tf_fpsr, f->tf_fpcr, f->tf_fpecr, f->tf_epsr);
- printf("dsap %x duap %x dsr %x dlar %x dpar %x\n",
+ printf("dsap %lx duap %lx dsr %lx dlar %lx dpar %lx\n",
f->tf_dsap, f->tf_duap, f->tf_dsr, f->tf_dlar, f->tf_dpar);
- printf("isap %x iuap %x isr %x ilar %x ipar %x\n",
+ printf("isap %lx iuap %lx isr %lx ilar %lx ipar %lx\n",
f->tf_isap, f->tf_iuap, f->tf_isr, f->tf_ilar, f->tf_ipar);
- printf("vector %d mask %x flags %x scratch1 %x cpu %p\n",
+ printf("vector %ld mask %lx flags %lx scratch1 %lx cpu %p\n",
f->tf_vector, f->tf_mask, f->tf_flags,
f->tf_scratch1, f->tf_cpu);
}
diff --git a/sys/arch/m88k/m88k/pmap.c b/sys/arch/m88k/m88k/pmap.c
index dde3272a098..71c5411a1b9 100644
--- a/sys/arch/m88k/m88k/pmap.c
+++ b/sys/arch/m88k/m88k/pmap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pmap.c,v 1.75 2013/11/16 18:45:20 miod Exp $ */
+/* $OpenBSD: pmap.c,v 1.76 2014/05/08 22:17:33 miod Exp $ */
/*
* Copyright (c) 2001-2004, 2010, Miodrag Vallat.
@@ -474,14 +474,14 @@ pmap_expand_kmap(vaddr_t va, int canfail)
if (canfail)
return NULL;
panic("pmap_expand_kmap(%p): uvm_pagealloc() failed",
- va);
+ (void *)va);
}
pa = VM_PAGE_TO_PHYS(pg);
} else {
pa = (paddr_t)uvm_pageboot_alloc(PAGE_SIZE);
if (pa == 0)
panic("pmap_expand_kmap(%p): uvm_pageboot_alloc() failed",
- va);
+ (void *)va);
bzero((void *)pa, PAGE_SIZE);
}
@@ -549,7 +549,7 @@ pmap_steal_memory(vsize_t size, vaddr_t *vstartp, vaddr_t *vendp)
/* m88k systems only have one segment. */
#ifdef DIAGNOSTIC
if (vm_physmem[0].avail_end - vm_physmem[0].avail_start < npg)
- panic("pmap_steal_memory(%x): out of memory", size);
+ panic("pmap_steal_memory(%lx): out of memory", size);
#endif
va = ptoa(vm_physmem[0].avail_start);
@@ -588,7 +588,7 @@ pmap_map(paddr_t pa, psize_t sz, vm_prot_t prot, u_int cmode,
#ifdef DIAGNOSTIC
if (pa != 0 && pa < VM_MAX_KERNEL_ADDRESS)
panic("pmap_map: virtual range %p-%p overlaps KVM",
- pa, pa + sz);
+ (void *)pa, (void *)(pa + sz));
#endif
sz = round_page(pa + sz) - trunc_page(pa);
@@ -1237,7 +1237,7 @@ pmap_remove_pte(pmap_t pmap, vaddr_t va, pt_entry_t *pte, struct vm_page *pg,
#ifdef DIAGNOSTIC
if (pvl->pv_pmap == NULL)
panic("pmap_remove_pte(%p, %p, %p, %p/%p, %d): null pv_list",
- pmap, va, pte, pa, pg, flush);
+ pmap, (void *)va, pte, (void *)pa, pg, flush);
#endif
prev = NULL;
@@ -1249,7 +1249,7 @@ pmap_remove_pte(pmap_t pmap, vaddr_t va, pt_entry_t *pte, struct vm_page *pg,
if (cur == NULL) {
panic("pmap_remove_pte(%p, %p, %p, %p, %d): mapping for va "
"(pa %p) not in pv list at %p",
- pmap, va, pte, pg, flush, pa, pvl);
+ pmap, (void *)va, pte, pg, flush, (void *)pa, pvl);
}
if (prev == NULL) {
diff --git a/sys/arch/m88k/m88k/trap.c b/sys/arch/m88k/m88k/trap.c
index b60fcff358e..f73b801db0d 100644
--- a/sys/arch/m88k/m88k/trap.c
+++ b/sys/arch/m88k/m88k/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.90 2014/04/18 11:51:17 guenther Exp $ */
+/* $OpenBSD: trap.c,v 1.91 2014/05/08 22:17:33 miod Exp $ */
/*
* Copyright (c) 2004, Miodrag Vallat.
* Copyright (c) 1998 Steve Murphree, Jr.
@@ -123,18 +123,18 @@ printtrap(int type, struct trapframe *frame)
if (CPU_IS88100) {
if (type == 2) {
/* instruction exception */
- printf("\nInstr access fault (%s) v = %x, frame %p\n",
+ printf("\nInstr access fault (%s) v = %lx, frame %p\n",
pbus_exception_type[
CMMU_PFSR_FAULT(frame->tf_ipfsr)],
frame->tf_sxip & XIP_ADDR, frame);
} else if (type == 3) {
/* data access exception */
- printf("\nData access fault (%s) v = %x, frame %p\n",
+ printf("\nData access fault (%s) v = %lx, frame %p\n",
pbus_exception_type[
CMMU_PFSR_FAULT(frame->tf_dpfsr)],
frame->tf_sxip & XIP_ADDR, frame);
} else
- printf("\nTrap type %d, v = %x, frame %p\n",
+ printf("\nTrap type %d, v = %lx, frame %p\n",
type, frame->tf_sxip & XIP_ADDR, frame);
}
#endif
@@ -276,7 +276,7 @@ lose:
return;
#endif /* DDB */
case T_MISALGNFLT:
- printf("kernel misaligned access exception @%p\n",
+ printf("kernel misaligned access exception @0x%08lx\n",
frame->tf_sxip);
goto lose;
case T_INSTFLT:
@@ -1168,7 +1168,7 @@ error_fatal(struct trapframe *frame)
#ifdef DDB
regdump((struct trapframe*)frame);
#endif
- panic("unrecoverable exception %d", frame->tf_vector);
+ panic("unrecoverable exception %ld", frame->tf_vector);
}
#ifdef M88100