-/* $OpenBSD: db_machdep.c,v 1.39 2014/05/10 22:25:16 jasper Exp $ */
+/* $OpenBSD: db_machdep.c,v 1.40 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 1998-2003 Opsycon AB (www.opsycon.se)
int i;
for (i = 0; i < ncpus; i++) {
- db_printf("%c%4d: ", (i == cpu_number()) ? '*' : ' ',
+ db_printf("%c%4ld: ", (i == cpu_number()) ? '*' : ' ',
get_cpu_info(i)->ci_cpuid);
switch(get_cpu_info(i)->ci_ddb) {
case CI_DDB_RUNNING:
-# $OpenBSD: Makefile.sgi,v 1.62 2013/10/15 19:23:29 guenther Exp $
+# $OpenBSD: Makefile.sgi,v 1.63 2014/05/19 21:18:42 miod Exp $
# For instructions on building kernels consult the config(8) and options(4)
# manual pages.
INCLUDES= -nostdinc -I$S -I. -I$S/arch
CPPFLAGS= ${INCLUDES} ${IDENT} ${PARAM} -D_KERNEL -D__${_mach}__ -MD -MP
CWARNFLAGS= -Werror -Wall -Wstrict-prototypes -Wmissing-prototypes \
- -Wno-main -Wno-uninitialized -Wno-format \
+ -Wno-main -Wno-uninitialized \
-Wstack-larger-than-2047
CMACHFLAGS= -mno-abicalls ${ABI} -msoft-float -G 0
-/* $OpenBSD: if_iec.c,v 1.9 2013/08/17 15:44:08 bluhm Exp $ */
+/* $OpenBSD: if_iec.c,v 1.10 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 2009 Miodrag Vallat.
if (rxd->rxd_err & (IEC_RXERR_BADPACKET | IEC_RXERR_LONGEVENT |
IEC_RXERR_INVPREAMB | IEC_RXERR_CODE | IEC_RXERR_FRAME |
IEC_RXERR_CRC)) {
- printf("%s: iec_rxintr: stat = 0x%08x err = %08x\n",
+ printf("%s: iec_rxintr: stat = 0x%08llx err = %08x\n",
sc->sc_dev.dv_xname, rxstat, rxd->rxd_err);
goto dropit;
}
-/* $OpenBSD: mavb.c,v 1.16 2013/06/21 09:34:06 ratchov Exp $ */
+/* $OpenBSD: mavb.c,v 1.17 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 2005 Mark Kettenis
src = sc->play.sw_cur;
if (write_ptr % MAVB_CHAN_CHUNK_SIZE) {
- printf("%s: write_ptr=%d\n", sc->sc_dev.dv_xname, write_ptr);
+ printf("%s: write_ptr=%lld\n", sc->sc_dev.dv_xname, write_ptr);
return;
}
if ((src - sc->play.sw_start) % MAVB_CHAN_CHUNK_SIZE) {
- printf("%s: src=%d\n", sc->sc_dev.dv_xname,
+ printf("%s: src=%ld\n", sc->sc_dev.dv_xname,
src - sc->play.sw_start);
return;
}
dst = sc->rec.sw_cur;
if (read_ptr % MAVB_CHAN_CHUNK_SIZE) {
- printf("%s: read_ptr=%d\n", sc->sc_dev.dv_xname, read_ptr);
+ printf("%s: read_ptr=%lld\n", sc->sc_dev.dv_xname, read_ptr);
return;
}
if ((dst - sc->rec.sw_start) % MAVB_CHAN_CHUNK_SIZE) {
- printf("%s: dst=%d\n", sc->sc_dev.dv_xname,
+ printf("%s: dst=%ld\n", sc->sc_dev.dv_xname,
dst - sc->rec.sw_start);
return;
}
-/* $OpenBSD: gio.c,v 1.17 2014/03/27 21:24:22 miod Exp $ */
+/* $OpenBSD: gio.c,v 1.18 2014/05/19 21:18:42 miod Exp $ */
/* $NetBSD: gio.c,v 1.32 2011/07/01 18:53:46 dyoung Exp $ */
/*
if (ga->ga_slot != -1)
printf(" slot %d", ga->ga_slot);
- printf(" addr 0x%lx", ga->ga_addr);
+ printf(" addr 0x%llx", ga->ga_addr);
return UNCONF;
}
printf("%s at %s", fbname, pnp);
}
- printf(" addr 0x%lx", ga->ga_addr);
+ printf(" addr 0x%llx", ga->ga_addr);
return UNCONF;
}
-/* $OpenBSD: pci_gio.c,v 1.1 2012/05/18 20:31:40 miod Exp $ */
+/* $OpenBSD: pci_gio.c,v 1.2 2014/05/19 21:18:42 miod Exp $ */
/* $NetBSD: pci_gio.c,v 1.9 2011/07/01 18:53:46 dyoung Exp $ */
/*
void
giopci_intr_disestablish(void *v, void *ih)
{
- panic("%s");
+ panic("%s", __func__);
}
int
giopci_ppb_setup(void *cookie, pcitag_t tag, bus_addr_t *iostart,
bus_addr_t *ioend, bus_addr_t *memstart, bus_addr_t *memend)
{
- panic("%s");
+ panic("%s", __func__);
}
#if NCARDBUS > 0
-/* $OpenBSD: zs.c,v 1.11 2013/10/21 12:14:51 miod Exp $ */
+/* $OpenBSD: zs.c,v 1.12 2014/05/19 21:18:42 miod Exp $ */
/* $NetBSD: zs.c,v 1.37 2011/02/20 07:59:50 matt Exp $ */
/*-
zs_chan_offset[channel],
sizeof(struct zschan),
&ch->cs_regs) != 0) {
- printf(": cannot map regs\n", self->dv_xname);
+ printf(": cannot map regs\n");
return;
}
ch->cs_bustag = zsc->zsc_bustag;
-/* $OpenBSD: imc.c,v 1.15 2014/03/27 21:24:22 miod Exp $ */
+/* $OpenBSD: imc.c,v 1.16 2014/05/19 21:18:42 miod Exp $ */
/* $NetBSD: imc.c,v 1.32 2011/07/01 18:53:46 dyoung Exp $ */
/*
copyin((void *)pc, &insn, sizeof insn);
printf(" cpu_stat %08x addr %08x pc %p insn %08x",
- cpustat, imc_read(IMC_CPU_ERRADDR), pc, insn);
+ cpustat, imc_read(IMC_CPU_ERRADDR), (void *)pc,
+ insn);
}
if (giostat != 0)
printf(" gio_stat %08x addr %08x",
-/* $OpenBSD: int.c,v 1.9 2012/10/03 11:18:23 miod Exp $ */
+/* $OpenBSD: int.c,v 1.10 2014/05/19 21:18:42 miod Exp $ */
/* $NetBSD: int.c,v 1.24 2011/07/01 18:53:46 dyoung Exp $ */
/*
if (int2_base == 0)
int2_base = int2_get_base();
- printf(" addr 0x%x\n", XKPHYS_TO_PHYS(int2_base));
+ printf(" addr 0x%lx\n", XKPHYS_TO_PHYS(int2_base));
/* Clean out interrupt masks */
int2_write(INT2_LOCAL0_MASK, 0);
-/* $OpenBSD: macebus.c,v 1.61 2012/10/03 11:18:23 miod Exp $ */
+/* $OpenBSD: macebus.c,v 1.62 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 2000-2004 Opsycon AB (www.opsycon.se)
printf("%s at %s", maa->maa_name, macebus);
if (maa->maa_baseaddr != 0)
- printf(" base 0x%08x", maa->maa_baseaddr);
+ printf(" base 0x%08lx", maa->maa_baseaddr);
if (maa->maa_intr >= 0)
printf(" irq %d", maa->maa_intr);
(1 << (bit))) != 0) { \
if ((mace_isr & mace_imr) != 0) \
printf("spurious crime interrupt %d" \
- " mace isr %p imr %p\n", bit, mace_isr, mace_imr); \
+ " mace isr %p imr %p\n", \
+ bit, (void *)mace_isr, (void *)mace_imr); \
} else \
printf("spurious crime interrupt %d\n", bit); \
} while (0)
-/* $OpenBSD: tcc.c,v 1.4 2014/03/29 18:09:30 guenther Exp $ */
+/* $OpenBSD: tcc.c,v 1.5 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 2012 Miodrag Vallat.
error = tcc_read(TCC_ERROR);
addr = tcc_read(TCC_BERR_ADDR);
- printf("tcc bus error: intr %lx error %lx (%d) addr %08lx\n",
+ printf("tcc bus error: intr %llx error %llx (%llu) addr %08llx\n",
intr, error, (error & TCC_ERROR_TYPE_MASK) >> TCC_ERROR_TYPE_SHIFT,
addr);
/* get the proper physical address */
if (pmap_extract(pmap_kernel(), va, &pa) == 0) {
#ifdef DIAGNOSTIC
- panic("%s: invalid va %p", __func__, va);
+ panic("%s: invalid va %p", __func__, (void *)va);
#else
/* should not happen */
#endif
-/* $OpenBSD: ioc.c,v 1.38 2012/05/30 16:43:31 miod Exp $ */
+/* $OpenBSD: ioc.c,v 1.39 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 2008 Joel Sing.
/* no base for onewire, and don't display it for rtc */
if ((int)iaa->iaa_base > 0 && (int)iaa->iaa_base < IOC3_BYTEBUS_0)
- printf(" base 0x%x", iaa->iaa_base);
+ printf(" base 0x%lx", iaa->iaa_base);
return (UNCONF);
}
-/* $OpenBSD: iof.c,v 1.8 2011/10/10 19:49:16 miod Exp $ */
+/* $OpenBSD: iof.c,v 1.9 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 2009 Miodrag Vallat.
if (iofname != NULL)
printf("%s at %s", iaa->iaa_name, iofname);
- printf(" base 0x%x", iaa->iaa_base);
+ printf(" base 0x%lx", iaa->iaa_base);
return UNCONF;
}
-/* $OpenBSD: macepcibridge.c,v 1.46 2014/04/03 08:07:16 mpi Exp $ */
+/* $OpenBSD: macepcibridge.c,v 1.47 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 2009 Miodrag Vallat.
void mace_pcibr_device_fixup(struct mace_pcibr_softc *, int, int);
int mace_pcibr_errintr(void *);
-extern void pciaddr_remap(pci_chipset_tag_t);
-
struct cfattach macepcibr_ca = {
sizeof(struct mace_pcibr_softc), mace_pcibrmatch, mace_pcibrattach,
};
{ 0, 0, NULL }
};
-static int mace_pcibrprint(void *, const char *pnp);
+static int mace_pcibrprint(void *, const char *pnp);
int
mace_pcibrmatch(struct device *parent, void *match, void *aux)
{
static char str[16];
- snprintf(str, sizeof(str), "irq %d", ih);
+ snprintf(str, sizeof(str), "irq %ld", ih);
return(str);
}
-/* $OpenBSD: bus_dma.c,v 1.33 2014/04/03 08:07:16 mpi Exp $ */
+/* $OpenBSD: bus_dma.c,v 1.34 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 2003-2004 Opsycon AB (www.opsycon.se / www.opsycon.com)
* Get the physical address for this segment.
*/
if (pmap_extract(pmap, vaddr, &curaddr) == FALSE)
- panic("_dmapmap_load_buffer: pmap_extract(%x, %x) failed!",
- pmap, vaddr);
+ panic("_dmapmap_load_buffer: pmap_extract(%p, %p) failed!",
+ pmap, (void *)vaddr);
#ifdef DIAGNOSTIC
if (curaddr > dma_constraint.ucr_high ||
curaddr < dma_constraint.ucr_low)
- panic("Non DMA-reachable buffer at curaddr %p (raw)",
- curaddr);
+ panic("Non DMA-reachable buffer at addr %p (raw)",
+ (void *)curaddr);
#endif
/*
-/* $OpenBSD: ip22_machdep.c,v 1.17 2014/04/03 08:07:16 mpi Exp $ */
+/* $OpenBSD: ip22_machdep.c,v 1.18 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 2012 Miodrag Vallat.
/* get the proper physical address */
if (pmap_extract(pmap_kernel(), va, &pa) == 0) {
#ifdef DIAGNOSTIC
- panic("%s: invalid va %p", __func__, va);
+ panic("%s: invalid va %p",
+ __func__, (void *)va);
#else
/* should not happen */
#endif
-/* $OpenBSD: ip27_machdep.c,v 1.58 2014/04/03 08:07:16 mpi Exp $ */
+/* $OpenBSD: ip27_machdep.c,v 1.59 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 2008, 2009 Miodrag Vallat.
regs++; /* NMI COP_0_STATUS_REG */
setsr(getsr() & ~SR_BOOT_EXC_VEC);
- printf("NMI, PC = %p RA = %p SR = %08x EPC = %p\n",
- nmi_frame.pc, nmi_frame.ra, nmi_frame.sr, epc);
+ printf("NMI, PC = %p RA = %p SR = %08lx EPC = %p\n",
+ (void *)nmi_frame.pc, (void *)nmi_frame.ra, nmi_frame.sr,
+ (void *)epc);
#ifdef DDB
(void)kdb_trap(-1, &nmi_frame);
#endif
-/* $OpenBSD: machdep.c,v 1.137 2014/04/03 08:07:16 mpi Exp $ */
+/* $OpenBSD: machdep.c,v 1.138 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 2003-2004 Opsycon AB (www.opsycon.se / www.opsycon.com)
dumpconf();
if (dumplo < 0)
return;
- printf("\ndumping to dev %x, offset %d\n", dumpdev, dumplo);
+ printf("\ndumping to dev %x, offset %ld\n", dumpdev, dumplo);
printf("dump not yet implemented\n");
#if 0 /* XXX HAVE TO FIX XXX */
switch (error = (*bdevsw[major(dumpdev)].d_dump)(dumpdev, dumplo,)) {
-/* $OpenBSD: xbridge.c,v 1.88 2014/04/03 08:07:16 mpi Exp $ */
+/* $OpenBSD: xbridge.c,v 1.89 2014/05/19 21:18:42 miod Exp $ */
/*
* Copyright (c) 2008, 2009, 2011 Miodrag Vallat.
if (xb->xb_intrstr[intrbit][0] == '\0')
snprintf(xb->xb_intrstr[intrbit],
- sizeof xb->xb_intrstr[intrbit], "irq %d", ih);
+ sizeof xb->xb_intrstr[intrbit], "irq %ld", ih);
return xb->xb_intrstr[intrbit];
}
xbridge_read_reg(xb, BRIDGE_WIDGET_RESP_UPPER) << 32;
/* XXX give more detailed information */
- printf("%s: error interrupt, isr %p wid %p pci %p resp %p\n",
+ printf("%s: error interrupt, isr %llx wid %llx pci %llx resp %llx\n",
DEVNAME(xb), isr, wid_err, pci_err, resp_err);
xbridge_err_clear(xb, isr);