summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2006-04-20 20:31:14 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2006-04-20 20:31:14 +0000
commitde5376f6ab54105d367ef84762d22711310371e7 (patch)
treebf44ed50c2db9351ff55368d75f45c807cc72475
parente1d297c29cadf0be3ed3775c0cfbcd97d01d7b9a (diff)
Fix various printf() issues: too many arguments, not enough arguments, argument
order reversed, wrong modifiers. ok deraadt@ marco@ mickey@
-rw-r--r--sys/dev/ic/aac.c4
-rw-r--r--sys/dev/ic/am7990.c4
-rw-r--r--sys/dev/ic/if_wi_hostap.c8
-rw-r--r--sys/dev/ic/isp.c4
-rw-r--r--sys/dev/ic/mfi.c6
-rw-r--r--sys/dev/ic/rt2560.c5
-rw-r--r--sys/dev/ic/rt2661.c5
-rw-r--r--sys/dev/ic/rtl81x9.c5
-rw-r--r--sys/dev/ipmi.c4
-rw-r--r--sys/dev/pci/auich.c5
-rw-r--r--sys/dev/pci/if_epic_pci.c12
-rw-r--r--sys/dev/pci/if_ixgb.c4
-rw-r--r--sys/dev/pci/if_pcn.c4
-rw-r--r--sys/dev/pci/if_san_xilinx.c6
-rw-r--r--sys/dev/pci/if_sandrv.c4
-rw-r--r--sys/dev/pci/if_sk.c4
-rw-r--r--sys/dev/pci/ises.c4
-rw-r--r--sys/dev/pci/siop_pci_common.c5
-rw-r--r--sys/dev/pcmcia/aic_pcmcia.c5
-rw-r--r--sys/dev/pcmcia/com_pcmcia.c5
-rw-r--r--sys/dev/pcmcia/if_sm_pcmcia.c5
-rw-r--r--sys/dev/pcmcia/if_wi_pcmcia.c5
-rw-r--r--sys/dev/pcmcia/wdc_pcmcia.c10
-rw-r--r--sys/scsi/scsi_ioctl.c4
-rw-r--r--sys/scsi/ses.c4
25 files changed, 69 insertions, 62 deletions
diff --git a/sys/dev/ic/aac.c b/sys/dev/ic/aac.c
index 7e000a60ec2..3994250c7a6 100644
--- a/sys/dev/ic/aac.c
+++ b/sys/dev/ic/aac.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: aac.c,v 1.28 2006/02/06 22:11:32 jmc Exp $ */
+/* $OpenBSD: aac.c,v 1.29 2006/04/20 20:31:12 miod Exp $ */
/*-
* Copyright (c) 2000 Michael Smith
@@ -1806,7 +1806,7 @@ aac_sync_fib(struct aac_softc *sc, u_int32_t command, u_int32_t xferstate,
{
if (datasize > AAC_FIB_DATASIZE) {
- printf("aac_sync_fib 1: datasize=%d AAC_FIB_DATASIZE\n",
+ printf("aac_sync_fib 1: datasize=%d AAC_FIB_DATASIZE %lu\n",
datasize, AAC_FIB_DATASIZE);
return(EINVAL);
}
diff --git a/sys/dev/ic/am7990.c b/sys/dev/ic/am7990.c
index 5afa5991fc4..0aec5414156 100644
--- a/sys/dev/ic/am7990.c
+++ b/sys/dev/ic/am7990.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: am7990.c,v 1.40 2006/03/25 22:41:42 djm Exp $ */
+/* $OpenBSD: am7990.c,v 1.41 2006/04/20 20:31:12 miod Exp $ */
/* $NetBSD: am7990.c,v 1.22 1996/10/13 01:37:19 christos Exp $ */
/*-
@@ -181,7 +181,7 @@ am7990_config(sc)
sc->sc_ntbuf = 32;
break;
default:
- panic("am7990_config: weird memory size %d", sc->sc_memsize);
+ panic("am7990_config: weird memory size %lu", sc->sc_memsize);
}
printf(": address %s\n", ether_sprintf(sc->sc_arpcom.ac_enaddr));
diff --git a/sys/dev/ic/if_wi_hostap.c b/sys/dev/ic/if_wi_hostap.c
index cc0b387b75b..2b0b1765c59 100644
--- a/sys/dev/ic/if_wi_hostap.c
+++ b/sys/dev/ic/if_wi_hostap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_wi_hostap.c,v 1.33 2005/12/03 21:11:48 brad Exp $ */
+/* $OpenBSD: if_wi_hostap.c,v 1.34 2006/04/20 20:31:12 miod Exp $ */
/*
* Copyright (c) 2002
@@ -192,7 +192,7 @@ wihap_init(struct wi_softc *sc)
struct wihap_info *whi = &sc->wi_hostap_info;
if (sc->sc_ic.ic_if.if_flags & IFF_DEBUG)
- printf("wihap_init: sc=0x%x whi=0x%x\n", sc, whi);
+ printf("wihap_init: sc=%p whi=%p\n", sc, whi);
bzero(whi, sizeof(struct wihap_info));
@@ -279,7 +279,7 @@ wihap_shutdown(struct wi_softc *sc)
int i, s;
if (sc->sc_ic.ic_if.if_flags & IFF_DEBUG)
- printf("wihap_shutdown: sc=0x%x whi=0x%x\n", sc, whi);
+ printf("wihap_shutdown: sc=%p whi=%p\n", sc, whi);
if (!(whi->apflags & WIHAPFL_ACTIVE))
return;
@@ -295,7 +295,7 @@ wihap_shutdown(struct wi_softc *sc)
sta != TAILQ_END(&whi->sta_list); sta = next) {
timeout_del(&sta->tmo);
if (sc->sc_ic.ic_if.if_flags & IFF_DEBUG)
- printf("wihap_shutdown: FREE(sta=0x%x)\n", sta);
+ printf("wihap_shutdown: FREE(sta=%p)\n", sta);
next = TAILQ_NEXT(sta, list);
if (sta->challenge)
FREE(sta->challenge, M_TEMP);
diff --git a/sys/dev/ic/isp.c b/sys/dev/ic/isp.c
index a8a9440b2f6..002213f08f9 100644
--- a/sys/dev/ic/isp.c
+++ b/sys/dev/ic/isp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: isp.c,v 1.35 2004/07/18 03:36:35 deraadt Exp $ */
+/* $OpenBSD: isp.c,v 1.36 2006/04/20 20:31:12 miod Exp $ */
/*
* Machine and OS Independent (well, as best as possible)
* code for the Qlogic ISP SCSI adapters.
@@ -99,7 +99,7 @@ static const char topology[] =
static const char swrej[] =
"Fabric Nameserver rejected %s (Reason=0x%x Expl=0x%x) for Port ID 0x%x";
static const char finmsg[] =
- "(%d.%d.%d): FIN dl%d resid %d STS 0x%x SKEY %c XS_ERR=0x%x";
+ "(%d.%d.%d): FIN dl%d resid %zu STS 0x%x SKEY %c XS_ERR=0x%x";
static const char sc0[] =
"%s CHAN %d FTHRSH %d IID %d RESETD %d RETRYC %d RETRYD %d ASD 0x%x";
static const char sc1[] =
diff --git a/sys/dev/ic/mfi.c b/sys/dev/ic/mfi.c
index 072a0be0d4b..1b0aebe65a9 100644
--- a/sys/dev/ic/mfi.c
+++ b/sys/dev/ic/mfi.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mfi.c,v 1.20 2006/04/20 14:01:08 dlg Exp $ */
+/* $OpenBSD: mfi.c,v 1.21 2006/04/20 20:31:12 miod Exp $ */
/*
* Copyright (c) 2006 Marco Peereboom <marco@peereboom.us>
*
@@ -306,8 +306,8 @@ mfi_transition_firmware(struct mfi_softc *sc)
break;
}
if (fw_state == cur_state) {
- printf("%s: firmware stuck in state %#x\n", fw_state,
- DEVNAME(sc));
+ printf("%s: firmware stuck in state %#x\n",
+ DEVNAME(sc), fw_state);
return (1);
}
}
diff --git a/sys/dev/ic/rt2560.c b/sys/dev/ic/rt2560.c
index 1701faa529c..bb9e526363c 100644
--- a/sys/dev/ic/rt2560.c
+++ b/sys/dev/ic/rt2560.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rt2560.c,v 1.14 2006/03/27 20:54:15 damien Exp $ */
+/* $OpenBSD: rt2560.c,v 1.15 2006/04/20 20:31:12 miod Exp $ */
/*-
* Copyright (c) 2005, 2006
@@ -2743,7 +2743,8 @@ rt2560_init(struct ifnet *ifp)
/* for CardBus, power on the socket */
if (!(sc->sc_flags & RT2560_ENABLED)) {
if (sc->sc_enable != NULL && (*sc->sc_enable)(sc) != 0) {
- printf("%s: could not enable device\n");
+ printf("%s: could not enable device\n",
+ sc->sc_dev.dv_xname);
return EIO;
}
sc->sc_flags |= RT2560_ENABLED;
diff --git a/sys/dev/ic/rt2661.c b/sys/dev/ic/rt2661.c
index 0fd7fa8a48c..f925d327e2a 100644
--- a/sys/dev/ic/rt2661.c
+++ b/sys/dev/ic/rt2661.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rt2661.c,v 1.15 2006/03/27 20:54:15 damien Exp $ */
+/* $OpenBSD: rt2661.c,v 1.16 2006/04/20 20:31:12 miod Exp $ */
/*-
* Copyright (c) 2006
@@ -2553,7 +2553,8 @@ rt2661_init(struct ifnet *ifp)
/* for CardBus, power on the socket */
if (!(sc->sc_flags & RT2661_ENABLED)) {
if (sc->sc_enable != NULL && (*sc->sc_enable)(sc) != 0) {
- printf("%s: could not enable device\n");
+ printf("%s: could not enable device\n",
+ sc->sc_dev.dv_xname);
return EIO;
}
sc->sc_flags |= RT2661_ENABLED;
diff --git a/sys/dev/ic/rtl81x9.c b/sys/dev/ic/rtl81x9.c
index b1bfcfe4e62..874073ea00d 100644
--- a/sys/dev/ic/rtl81x9.c
+++ b/sys/dev/ic/rtl81x9.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rtl81x9.c,v 1.48 2006/03/25 22:41:43 djm Exp $ */
+/* $OpenBSD: rtl81x9.c,v 1.49 2006/04/20 20:31:12 miod Exp $ */
/*
* Copyright (c) 1997, 1998
@@ -1289,7 +1289,8 @@ rl_attach(sc)
for (i = 0; i < RL_TX_LIST_CNT; i++) {
if (bus_dmamap_create(sc->sc_dmat, MCLBYTES, 1, MCLBYTES, 0,
BUS_DMA_NOWAIT, &sc->rl_cdata.rl_tx_dmamap[i]) != 0) {
- printf("%s: can't create tx maps\n");
+ printf("%s: can't create tx maps\n",
+ sc->sc_dev.dv_xname);
/* XXX free any allocated... */
return (1);
}
diff --git a/sys/dev/ipmi.c b/sys/dev/ipmi.c
index fc5dc6ba467..0d450eb7d10 100644
--- a/sys/dev/ipmi.c
+++ b/sys/dev/ipmi.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ipmi.c,v 1.34 2006/01/29 17:29:29 marco Exp $ */
+/* $OpenBSD: ipmi.c,v 1.35 2006/04/20 20:31:10 miod Exp $ */
/*
* Copyright (c) 2005 Jordan Hargrave
@@ -1607,7 +1607,7 @@ ipmi_map_regs(struct ipmi_softc *sc, struct ipmi_attach_args *ia)
if (bus_space_map(sc->sc_iot, ia->iaa_if_iobase,
sc->sc_if->nregs * sc->sc_if_iospacing,
0, &sc->sc_ioh)) {
- printf("ipmi: bus_space_map(%x %x %x 0 %x) failed\n",
+ printf("ipmi: bus_space_map(%x %x %x 0 %p) failed\n",
sc->sc_iot, ia->iaa_if_iobase,
sc->sc_if->nregs * sc->sc_if_iospacing, &sc->sc_ioh);
return (-1);
diff --git a/sys/dev/pci/auich.c b/sys/dev/pci/auich.c
index 8e961aa244a..13f569bbe1f 100644
--- a/sys/dev/pci/auich.c
+++ b/sys/dev/pci/auich.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: auich.c,v 1.58 2006/02/13 06:15:32 brad Exp $ */
+/* $OpenBSD: auich.c,v 1.59 2006/04/20 20:31:12 miod Exp $ */
/*
* Copyright (c) 2000,2001 Michael Shalayeff
@@ -423,7 +423,8 @@ auich_attach(parent, self, aux)
}
if (bus_dmamap_load_raw(sc->dmat, sc->dmalist_map, sc->dmalist_seg,
segs, dmasz, BUS_DMA_NOWAIT)) {
- printf(": failed to load dmalist map: %d segs %u size\n", segs, dmasz);
+ printf(": failed to load dmalist map: %d segs %lu size\n",
+ segs, (u_long)dmasz);
bus_dmamap_destroy(sc->dmat, sc->dmalist_map);
bus_dmamem_unmap(sc->dmat, sc->dmalist_kva, dmasz);
bus_dmamem_free(sc->dmat, sc->dmalist_seg, segs);
diff --git a/sys/dev/pci/if_epic_pci.c b/sys/dev/pci/if_epic_pci.c
index 33bea022c41..e6f0d53ccd6 100644
--- a/sys/dev/pci/if_epic_pci.c
+++ b/sys/dev/pci/if_epic_pci.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_epic_pci.c,v 1.4 2005/12/15 23:17:23 krw Exp $ */
+/* $OpenBSD: if_epic_pci.c,v 1.5 2006/04/20 20:31:12 miod Exp $ */
/* $NetBSD: if_epic_pci.c,v 1.28 2005/02/27 00:27:32 perry Exp $ */
/*-
@@ -167,7 +167,7 @@ epic_pci_attach(struct device *parent, struct device *self, void *aux)
case PCI_PMCSR_STATE_D1:
case PCI_PMCSR_STATE_D2:
printf(": waking up from power state D%d\n",
- sc->sc_dev.dv_xname, reg & PCI_PMCSR_STATE_MASK);
+ reg & PCI_PMCSR_STATE_MASK);
pci_conf_write(pc, pa->pa_tag, pmreg + PCI_PMCSR,
(reg & ~PCI_PMCSR_STATE_MASK) |
PCI_PMCSR_STATE_D0);
@@ -179,7 +179,7 @@ epic_pci_attach(struct device *parent, struct device *self, void *aux)
*/
printf(
": unable to wake up from power state D3, "
- "reboot required.\n", sc->sc_dev.dv_xname);
+ "reboot required.\n");
pci_conf_write(pc, pa->pa_tag, pmreg + PCI_PMCSR,
(reg & ~PCI_PMCSR_STATE_MASK) |
PCI_PMCSR_STATE_D0);
@@ -204,8 +204,7 @@ epic_pci_attach(struct device *parent, struct device *self, void *aux)
sc->sc_st = iot;
sc->sc_sh = ioh;
} else {
- printf(": unable to map device registers\n",
- sc->sc_dev.dv_xname);
+ printf(": unable to map device registers\n");
return;
}
@@ -215,8 +214,7 @@ epic_pci_attach(struct device *parent, struct device *self, void *aux)
* Map and establish our interrupt.
*/
if (pci_intr_map(pa, &ih)) {
- printf(": unable to map interrupt\n",
- sc->sc_dev.dv_xname);
+ printf(": unable to map interrupt\n");
return;
}
intrstr = pci_intr_string(pc, ih);
diff --git a/sys/dev/pci/if_ixgb.c b/sys/dev/pci/if_ixgb.c
index 1cd01e88b17..947694ecffd 100644
--- a/sys/dev/pci/if_ixgb.c
+++ b/sys/dev/pci/if_ixgb.c
@@ -31,7 +31,7 @@ POSSIBILITY OF SUCH DAMAGE.
***************************************************************************/
-/* $OpenBSD: if_ixgb.c,v 1.12 2006/03/27 17:07:10 brad Exp $ */
+/* $OpenBSD: if_ixgb.c,v 1.13 2006/04/20 20:31:12 miod Exp $ */
#include <dev/pci/if_ixgb.h>
@@ -2002,7 +2002,7 @@ ixgb_print_hw_stats(struct ixgb_softc *sc)
bus_speed == ixgb_bus_speed_100 ? "100MHz" :
bus_speed == ixgb_bus_speed_133 ? "133MHz" :
"UNKNOWN");
- printf("ixgb%d: PCI_Bus_Speed = %s\n", unit,
+ printf("%s: PCI_Bus_Speed = %s\n", unit,
buf_speed);
snprintf(buf_type, sizeof(buf_type),
diff --git a/sys/dev/pci/if_pcn.c b/sys/dev/pci/if_pcn.c
index 1b112af8961..3dd09b6da54 100644
--- a/sys/dev/pci/if_pcn.c
+++ b/sys/dev/pci/if_pcn.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_pcn.c,v 1.10 2006/03/25 22:41:45 djm Exp $ */
+/* $OpenBSD: if_pcn.c,v 1.11 2006/04/20 20:31:12 miod Exp $ */
/* $NetBSD: if_pcn.c,v 1.26 2005/05/07 09:15:44 is Exp $ */
/*
@@ -640,7 +640,7 @@ pcn_attach(struct device *parent, struct device *self, void *aux)
* Map and establish our interrupt.
*/
if (pci_intr_map(pa, &ih)) {
- printf(": unable to map interrupt\n", sc->sc_dev.dv_xname);
+ printf(": unable to map interrupt\n");
return;
}
intrstr = pci_intr_string(pc, ih);
diff --git a/sys/dev/pci/if_san_xilinx.c b/sys/dev/pci/if_san_xilinx.c
index 78cf98742a2..b63e29d4f28 100644
--- a/sys/dev/pci/if_san_xilinx.c
+++ b/sys/dev/pci/if_san_xilinx.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_san_xilinx.c,v 1.17 2005/12/13 05:56:22 canacar Exp $ */
+/* $OpenBSD: if_san_xilinx.c,v 1.18 2006/04/20 20:31:12 miod Exp $ */
/*-
* Copyright (c) 2001-2004 Sangoma Technologies (SAN)
@@ -485,7 +485,7 @@ wan_xilinx_up(struct ifnet *ifp)
sc->dma_mtu = xilinx_valid_mtu(ifp->if_mtu+100);
if (!sc->dma_mtu) {
- log(LOG_INFO, "%s:%s: Error invalid MTU %d\n",
+ log(LOG_INFO, "%s:%s: Error invalid MTU %lu\n",
card->devname, sc->if_name, ifp->if_mtu);
return (EINVAL);
}
@@ -1832,7 +1832,7 @@ xilinx_dma_tx(sdla_t *card, xilinx_softc_t *sc)
if (ADDR_MASK(mtod(m, caddr_t), 0x03)) {
/* The mbuf should already be aligned */
log(LOG_INFO, "%s: TX packet not aligned!\n",
- sc->if_name, MAX_XILINX_TX_DMA_SIZE);
+ sc->if_name);
m_freem(m);
bit_clear((u_int8_t *)&sc->dma_status, TX_BUSY);
return (EINVAL);
diff --git a/sys/dev/pci/if_sandrv.c b/sys/dev/pci/if_sandrv.c
index 7a7d3ae058f..b0687a6aa24 100644
--- a/sys/dev/pci/if_sandrv.c
+++ b/sys/dev/pci/if_sandrv.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_sandrv.c,v 1.10 2005/04/01 21:42:36 canacar Exp $ */
+/* $OpenBSD: if_sandrv.c,v 1.11 2006/04/20 20:31:12 miod Exp $ */
/*-
* Copyright (c) 2001-2004 Sangoma Technologies (SAN)
@@ -555,7 +555,7 @@ sdla_intr_disestablish(void *phw)
{
sdlahw_t *hw = (sdlahw_t*)phw;
- log(LOG_INFO, "%d: Disestablish interrupt is not defined!\n",
+ log(LOG_INFO, "%s: Disestablish interrupt is not defined!\n",
hw->devname);
return (EINVAL);
}
diff --git a/sys/dev/pci/if_sk.c b/sys/dev/pci/if_sk.c
index 80e5ee6367c..f4ec075dd85 100644
--- a/sys/dev/pci/if_sk.c
+++ b/sys/dev/pci/if_sk.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_sk.c,v 1.98 2006/04/17 10:11:29 brad Exp $ */
+/* $OpenBSD: if_sk.c,v 1.99 2006/04/20 20:31:12 miod Exp $ */
/*
* Copyright (c) 1997, 1998, 1999, 2000
@@ -1244,7 +1244,7 @@ sk_attach(struct device *parent, struct device *self, void *aux)
}
if (bus_dmamem_map(sc->sc_dmatag, &seg, rseg,
sizeof(struct sk_ring_data), &kva, BUS_DMA_NOWAIT)) {
- printf(": can't map dma buffers (%d bytes)\n",
+ printf(": can't map dma buffers (%z bytes)\n",
sizeof(struct sk_ring_data));
goto fail_1;
}
diff --git a/sys/dev/pci/ises.c b/sys/dev/pci/ises.c
index 64f0191d3dc..f7f5d728518 100644
--- a/sys/dev/pci/ises.c
+++ b/sys/dev/pci/ises.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ises.c,v 1.29 2005/11/26 14:31:26 krw Exp $ */
+/* $OpenBSD: ises.c,v 1.30 2006/04/20 20:31:12 miod Exp $ */
/*
* Copyright (c) 2000, 2001 Håkan Olsson (ho@crt.se)
@@ -1552,7 +1552,7 @@ ises_hrng_init(struct ises_softc *sc)
/* ACK the response */
WRITE_REG(sc, ISES_A_OQS, 0);
DELAY(1);
- printf(", rng active", sc->sc_dv.dv_xname);
+ printf(", rng active");
#ifdef ISESDEBUG
/* Benchmark the HRNG. */
diff --git a/sys/dev/pci/siop_pci_common.c b/sys/dev/pci/siop_pci_common.c
index aa10e8b34d6..0c609bc34b3 100644
--- a/sys/dev/pci/siop_pci_common.c
+++ b/sys/dev/pci/siop_pci_common.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: siop_pci_common.c,v 1.14 2005/10/08 18:21:33 krw Exp $ */
+/* $OpenBSD: siop_pci_common.c,v 1.15 2006/04/20 20:31:12 miod Exp $ */
/* $NetBSD: siop_pci_common.c,v 1.25 2005/06/28 00:28:42 thorpej Exp $ */
/*
@@ -308,7 +308,8 @@ siop_pci_attach_common(struct siop_pci_common_softc *pci_sc,
if (pci_mapreg_map(pa, bar, memtype, 0,
&siop_sc->sc_ramt, &siop_sc->sc_ramh,
&siop_sc->sc_scriptaddr, &memsize, 0) == 0) {
- printf(", using %dK of on-board RAM", memsize / 1024);
+ printf(", using %luK of on-board RAM",
+ (u_long)memsize / 1024);
} else {
printf(", can't map on-board RAM");
siop_sc->features &= ~SF_CHIP_RAM;
diff --git a/sys/dev/pcmcia/aic_pcmcia.c b/sys/dev/pcmcia/aic_pcmcia.c
index 0734bf9b600..39adae6ae6f 100644
--- a/sys/dev/pcmcia/aic_pcmcia.c
+++ b/sys/dev/pcmcia/aic_pcmcia.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: aic_pcmcia.c,v 1.12 2005/11/21 18:16:41 millert Exp $ */
+/* $OpenBSD: aic_pcmcia.c,v 1.13 2006/04/20 20:31:13 miod Exp $ */
/* $NetBSD: aic_pcmcia.c,v 1.6 1998/07/19 17:28:15 christos Exp $ */
/*
@@ -153,7 +153,8 @@ aic_pcmcia_attach(parent, self, aux)
return;
}
- printf(" port 0x%lx/%d", psc->sc_pcioh.addr, psc->sc_pcioh.size);
+ printf(" port 0x%lx/%lu", psc->sc_pcioh.addr,
+ (u_long)psc->sc_pcioh.size);
if (!aic_find(sc->sc_iot, sc->sc_ioh)) {
printf(": unable to detect chip!\n");
diff --git a/sys/dev/pcmcia/com_pcmcia.c b/sys/dev/pcmcia/com_pcmcia.c
index ee3327a5364..e5a9f82acf4 100644
--- a/sys/dev/pcmcia/com_pcmcia.c
+++ b/sys/dev/pcmcia/com_pcmcia.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: com_pcmcia.c,v 1.44 2005/12/13 23:07:31 mickey Exp $ */
+/* $OpenBSD: com_pcmcia.c,v 1.45 2006/04/20 20:31:13 miod Exp $ */
/* $NetBSD: com_pcmcia.c,v 1.15 1998/08/22 17:47:58 msaitoh Exp $ */
/*
@@ -318,7 +318,8 @@ found:
return;
}
- printf(" port 0x%lx/%d", psc->sc_pcioh.addr, psc->sc_pcioh.size);
+ printf(" port 0x%lx/%lu", psc->sc_pcioh.addr,
+ (u_long)psc->sc_pcioh.size);
sc->sc_iobase = -1;
sc->enable = com_pcmcia_enable;
diff --git a/sys/dev/pcmcia/if_sm_pcmcia.c b/sys/dev/pcmcia/if_sm_pcmcia.c
index f5d1262d6d3..c496caa3a87 100644
--- a/sys/dev/pcmcia/if_sm_pcmcia.c
+++ b/sys/dev/pcmcia/if_sm_pcmcia.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_sm_pcmcia.c,v 1.25 2006/01/23 14:42:55 martin Exp $ */
+/* $OpenBSD: if_sm_pcmcia.c,v 1.26 2006/04/20 20:31:13 miod Exp $ */
/* $NetBSD: if_sm_pcmcia.c,v 1.11 1998/08/15 20:47:32 thorpej Exp $ */
/*-
@@ -189,7 +189,8 @@ sm_pcmcia_attach(parent, self, aux)
return;
}
- printf(" port 0x%lx/%d", psc->sc_pcioh.addr, psc->sc_pcioh.size);
+ printf(" port 0x%lx/%lu", psc->sc_pcioh.addr,
+ (u_long)psc->sc_pcioh.size);
/*
* First try to get the Ethernet address from FUNCE/LANNID tuple.
diff --git a/sys/dev/pcmcia/if_wi_pcmcia.c b/sys/dev/pcmcia/if_wi_pcmcia.c
index 5355ea86bda..112dc6dee20 100644
--- a/sys/dev/pcmcia/if_wi_pcmcia.c
+++ b/sys/dev/pcmcia/if_wi_pcmcia.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_wi_pcmcia.c,v 1.64 2005/10/31 05:37:13 jsg Exp $ */
+/* $OpenBSD: if_wi_pcmcia.c,v 1.65 2006/04/20 20:31:13 miod Exp $ */
/* $NetBSD: if_wi_pcmcia.c,v 1.14 2001/11/26 04:34:56 ichiro Exp $ */
/*
@@ -405,7 +405,8 @@ wi_pcmcia_attach(struct device *parent, struct device *self, void *aux)
}
state++;
- printf(" port 0x%lx/%d", psc->sc_pcioh.addr, psc->sc_pcioh.size);
+ printf(" port 0x%lx/%lu", psc->sc_pcioh.addr,
+ (u_long)psc->sc_pcioh.size);
sc->wi_ltag = sc->wi_btag = psc->sc_pcioh.iot;
sc->wi_lhandle = sc->wi_bhandle = psc->sc_pcioh.ioh;
diff --git a/sys/dev/pcmcia/wdc_pcmcia.c b/sys/dev/pcmcia/wdc_pcmcia.c
index 98426340090..47567962991 100644
--- a/sys/dev/pcmcia/wdc_pcmcia.c
+++ b/sys/dev/pcmcia/wdc_pcmcia.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: wdc_pcmcia.c,v 1.16 2005/01/27 17:04:56 millert Exp $ */
+/* $OpenBSD: wdc_pcmcia.c,v 1.17 2006/04/20 20:31:13 miod Exp $ */
/* $NetBSD: wdc_pcmcia.c,v 1.19 1999/02/19 21:49:43 abs Exp $ */
/*-
@@ -333,11 +333,11 @@ wdc_pcmcia_attach(parent, self, aux)
goto iomapaux_failed;
}
- printf(" port 0x%lx/%d",
- sc->sc_pioh.addr, sc->sc_pioh.size);
+ printf(" port 0x%lx/%lu",
+ sc->sc_pioh.addr, (u_long)sc->sc_pioh.size);
if (cfe->num_iospace > 1 && sc->sc_auxpioh.size > 0)
- printf(",0x%lx/%d",
- sc->sc_auxpioh.addr, sc->sc_auxpioh.size);
+ printf(",0x%lx/%lu",
+ sc->sc_auxpioh.addr, (u_long)sc->sc_auxpioh.size);
sc->wdc_channel.cmd_iot = sc->sc_pioh.iot;
sc->wdc_channel.cmd_ioh = sc->sc_pioh.ioh;
diff --git a/sys/scsi/scsi_ioctl.c b/sys/scsi/scsi_ioctl.c
index c20b33f5086..6951f452939 100644
--- a/sys/scsi/scsi_ioctl.c
+++ b/sys/scsi/scsi_ioctl.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: scsi_ioctl.c,v 1.22 2005/12/08 14:02:47 krw Exp $ */
+/* $OpenBSD: scsi_ioctl.c,v 1.23 2006/04/20 20:31:13 miod Exp $ */
/* $NetBSD: scsi_ioctl.c,v 1.23 1996/10/12 23:23:17 christos Exp $ */
/*
@@ -442,7 +442,7 @@ scsi_do_ioctl( struct scsi_link *sc_link, dev_t dev, u_long cmd, caddr_t addr,
}
default:
#ifdef DIAGNOSTIC
- panic("scsi_do_ioctl: impossible cmd (%#x)", cmd);
+ panic("scsi_do_ioctl: impossible cmd (%#lx)", cmd);
#endif
return (0);
}
diff --git a/sys/scsi/ses.c b/sys/scsi/ses.c
index 3b495452da3..8bd4fb78f6c 100644
--- a/sys/scsi/ses.c
+++ b/sys/scsi/ses.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ses.c,v 1.34 2006/01/19 17:08:40 grange Exp $ */
+/* $OpenBSD: ses.c,v 1.35 2006/04/20 20:31:13 miod Exp $ */
/*
* Copyright (c) 2005 David Gwynne <dlg@openbsd.org>
@@ -552,7 +552,7 @@ ses_refresh_sensors(void *arg)
lockmgr(&sc->sc_lock, LK_RELEASE, NULL);
if (ret)
- printf("%s: error in sensor data\n");
+ printf("%s: error in sensor data\n", DEVNAME(sc));
}
#if NBIO > 0