summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRay Lai <ray@cvs.openbsd.org>2007-05-22 04:30:57 +0000
committerRay Lai <ray@cvs.openbsd.org>2007-05-22 04:30:57 +0000
commit7fd2dc11b9c6571ab065f767d0061835ac584adc (patch)
tree81ac696c254f32ee8596c1d3d3aca01e77f20d6b
parentefd3ad8f05a698545a76d25289811ecbbf6cab1d (diff)
%z in printf(9) is not the same as %z in printf(3). Change to %lu
and cast arg to ulong. OK miod@.
-rw-r--r--sys/dev/pci/if_msk.c10
-rw-r--r--sys/dev/pci/if_sk.c6
2 files changed, 8 insertions, 8 deletions
diff --git a/sys/dev/pci/if_msk.c b/sys/dev/pci/if_msk.c
index 74e072fc95e..3934b1fd04f 100644
--- a/sys/dev/pci/if_msk.c
+++ b/sys/dev/pci/if_msk.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_msk.c,v 1.52 2007/05/14 15:28:45 jsg Exp $ */
+/* $OpenBSD: if_msk.c,v 1.53 2007/05/22 04:30:55 ray Exp $ */
/*
* Copyright (c) 1997, 1998, 1999, 2000
@@ -1042,8 +1042,8 @@ msk_attach(struct device *parent, struct device *self, void *aux)
}
if (bus_dmamem_map(sc->sc_dmatag, &seg, rseg,
sizeof(struct msk_ring_data), &kva, BUS_DMA_NOWAIT)) {
- printf(": can't map dma buffers (%z bytes)\n",
- sizeof(struct msk_ring_data));
+ printf(": can't map dma buffers (%lu bytes)\n",
+ (ulong)sizeof(struct msk_ring_data));
goto fail_1;
}
if (bus_dmamap_create(sc->sc_dmatag, sizeof(struct msk_ring_data), 1,
@@ -1255,8 +1255,8 @@ mskc_attach(struct device *parent, struct device *self, void *aux)
if (bus_dmamem_map(sc->sc_dmatag, &seg, rseg,
MSK_STATUS_RING_CNT * sizeof(struct msk_status_desc),
&kva, BUS_DMA_NOWAIT)) {
- printf(": can't map dma buffers (%z bytes)\n",
- MSK_STATUS_RING_CNT * sizeof(struct msk_status_desc));
+ printf(": can't map dma buffers (%lu bytes)\n",
+ (ulong)(MSK_STATUS_RING_CNT * sizeof(struct msk_status_desc)));
goto fail_3;
}
if (bus_dmamap_create(sc->sc_dmatag,
diff --git a/sys/dev/pci/if_sk.c b/sys/dev/pci/if_sk.c
index ced912dc92c..a130ee217e5 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.140 2007/05/07 21:57:23 deraadt Exp $ */
+/* $OpenBSD: if_sk.c,v 1.141 2007/05/22 04:30:56 ray Exp $ */
/*
* Copyright (c) 1997, 1998, 1999, 2000
@@ -1156,8 +1156,8 @@ 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 (%z bytes)\n",
- sizeof(struct sk_ring_data));
+ printf(": can't map dma buffers (%lu bytes)\n",
+ (ulong)sizeof(struct sk_ring_data));
goto fail_1;
}
if (bus_dmamap_create(sc->sc_dmatag, sizeof(struct sk_ring_data), 1,