diff options
author | Kenneth R Westerback <krw@cvs.openbsd.org> | 2013-11-01 17:36:20 +0000 |
---|---|---|
committer | Kenneth R Westerback <krw@cvs.openbsd.org> | 2013-11-01 17:36:20 +0000 |
commit | b8183a0dbd4877f3cb0a20e0e6125c02674f08d2 (patch) | |
tree | d8807435b56011aa01dbd9ae817d091c18d254de /sys | |
parent | 0b88d158f37a4188b2c37633639614eba0110aa5 (diff) |
Sprinkle (long long) casts where %lld is being used to print daddr_t
variables. Some random whitespace/knf repairs encountered on the way.
ok miod@ on inspection, feedback & more suggestions from millert@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/hp300/dev/hd.c | 4 | ||||
-rw-r--r-- | sys/arch/i386/i386/machdep.c | 6 | ||||
-rw-r--r-- | sys/arch/sparc/dev/fd.c | 15 | ||||
-rw-r--r-- | sys/arch/sparc/dev/xd.c | 4 | ||||
-rw-r--r-- | sys/arch/sparc/dev/xy.c | 4 | ||||
-rw-r--r-- | sys/arch/sparc64/dev/fd.c | 12 | ||||
-rw-r--r-- | sys/arch/sparc64/sparc64/machdep.c | 4 | ||||
-rw-r--r-- | sys/dev/isa/fd.c | 9 | ||||
-rw-r--r-- | sys/dev/softraid.c | 18 | ||||
-rw-r--r-- | sys/dev/softraid_concat.c | 6 | ||||
-rw-r--r-- | sys/dev/softraid_raid0.c | 10 | ||||
-rw-r--r-- | sys/dev/softraid_raid1.c | 6 | ||||
-rw-r--r-- | sys/dev/softraid_raid6.c | 6 | ||||
-rw-r--r-- | sys/dev/softraid_raidp.c | 6 | ||||
-rw-r--r-- | sys/dev/vnd.c | 5 | ||||
-rw-r--r-- | sys/kern/subr_disk.c | 19 | ||||
-rw-r--r-- | sys/scsi/cd.c | 4 | ||||
-rw-r--r-- | sys/scsi/sd.c | 7 | ||||
-rw-r--r-- | sys/scsi/st.c | 4 | ||||
-rw-r--r-- | sys/ufs/ext2fs/ext2fs_subr.c | 6 | ||||
-rw-r--r-- | sys/ufs/ffs/ffs_alloc.c | 28 | ||||
-rw-r--r-- | sys/ufs/ffs/ffs_softdep.c | 62 | ||||
-rw-r--r-- | sys/ufs/ffs/ffs_subr.c | 9 | ||||
-rw-r--r-- | sys/ufs/ufs/ufs_bmap.c | 7 |
24 files changed, 143 insertions, 118 deletions
diff --git a/sys/arch/hp300/dev/hd.c b/sys/arch/hp300/dev/hd.c index 36a40b58056..5aa59b1527d 100644 --- a/sys/arch/hp300/dev/hd.c +++ b/sys/arch/hp300/dev/hd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: hd.c,v 1.72 2013/10/14 23:26:22 krw Exp $ */ +/* $OpenBSD: hd.c,v 1.73 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: rd.c,v 1.33 1997/07/10 18:14:08 kleink Exp $ */ /* @@ -1049,7 +1049,7 @@ hderror(unit) hdprinterr("fault", sp->c_fef, err_fault); hdprinterr("access", sp->c_aef, err_access); hdprinterr("info", sp->c_ief, err_info); - printf(" block: %lld, P1-P10: ", hwbn); + printf(" block: %lld, P1-P10: ", (long long)hwbn); printf("0x%04x", *(u_int *)&sp->c_raw[0]); printf("%04x", *(u_int *)&sp->c_raw[4]); printf("%02x\n", *(u_short *)&sp->c_raw[8]); diff --git a/sys/arch/i386/i386/machdep.c b/sys/arch/i386/i386/machdep.c index eb3bab857e1..7a61ff551ad 100644 --- a/sys/arch/i386/i386/machdep.c +++ b/sys/arch/i386/i386/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.527 2013/10/17 08:02:15 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.528 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: machdep.c,v 1.214 1996/11/10 03:16:17 thorpej Exp $ */ /*- @@ -2803,7 +2803,7 @@ dumpsys() maddr = ptoa(dumpmem[i].start); blkno = dumplo + btodb(maddr) + 1; #if 0 - printf("(%d %lld %d) ", maddr, blkno, npg); + printf("(%d %lld %d) ", maddr, (long long)blkno, npg); #endif for (j = npg; j--; maddr += NBPG, blkno += btodb(NBPG)) { @@ -2812,7 +2812,7 @@ dumpsys() printf("%ld ", (ptoa(dumpsize) - maddr) / (1024 * 1024)); #if 0 - printf("(%x %lld) ", maddr, blkno); + printf("(%x %lld) ", maddr, (long long)blkno); #endif pmap_enter(pmap_kernel(), dumpspace, maddr, VM_PROT_READ, PMAP_WIRED); diff --git a/sys/arch/sparc/dev/fd.c b/sys/arch/sparc/dev/fd.c index 7d9cadf029b..ca2784aedd1 100644 --- a/sys/arch/sparc/dev/fd.c +++ b/sys/arch/sparc/dev/fd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fd.c,v 1.84 2013/06/11 16:42:11 deraadt Exp $ */ +/* $OpenBSD: fd.c,v 1.85 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: fd.c,v 1.51 1997/05/24 20:16:19 pk Exp $ */ /*- @@ -727,8 +727,9 @@ fdstrategy(bp) #ifdef FD_DEBUG if (fdc_debug > 1) - printf("fdstrategy: b_blkno %d b_bcount %ld blkno %lld cylin %ld\n", - bp->b_blkno, bp->b_bcount, fd->sc_blkno, bp->b_cylinder); + printf("fdstrategy: b_blkno %lld b_bcount %ld blkno %lld " + "cylin %ld\n", (long long)bp->b_blkno, bp->b_bcount, + (long long)fd->sc_blkno, bp->b_cylinder); #endif /* Queue transfer on drive, activate drive and controller if idle. */ @@ -1380,9 +1381,11 @@ loop: sec -= head * type->sectrac; #ifdef DIAGNOSTIC {int block; - block = (fd->sc_cylin * type->heads + head) * type->sectrac + sec; + block = (fd->sc_cylin * type->heads + head) * type->sectrac + + sec; if (block != fd->sc_blkno) { - printf("fdcintr: block %d != blkno %lld\n", block, fd->sc_blkno); + printf("fdcintr: block %d != blkno %lld\n", block, + (long long)fd->sc_blkno); #if defined(FD_DEBUG) && defined(DDB) Debugger(); #endif @@ -1510,7 +1513,7 @@ loop: bp->b_flags & B_READ ? "read failed" : "write failed"); printf("blkno %lld nblks %d nstat %d tc %d\n", - fd->sc_blkno, fd->sc_nblks, + (long long)fd->sc_blkno, fd->sc_nblks, fdc->sc_nstat, fdc->sc_tc); } #endif diff --git a/sys/arch/sparc/dev/xd.c b/sys/arch/sparc/dev/xd.c index f16c7bce5e5..6704b446425 100644 --- a/sys/arch/sparc/dev/xd.c +++ b/sys/arch/sparc/dev/xd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: xd.c,v 1.60 2013/10/20 10:11:16 krw Exp $ */ +/* $OpenBSD: xd.c,v 1.61 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: xd.c,v 1.37 1997/07/29 09:58:16 fair Exp $ */ /* @@ -1381,7 +1381,7 @@ xdc_startbuf(xdcsc, xdsc, bp) #ifdef XDC_DEBUG printf("xdc_startbuf: %s%c: %s block %lld\n", xdsc->sc_dev.dv_xname, 'a' + partno, - (bp->b_flags & B_READ) ? "read" : "write", bp->b_blkno); + (bp->b_flags & B_READ) ? "read" : "write", (long long)bp->b_blkno); printf("xdc_startbuf: b_bcount %d, b_data 0x%x\n", bp->b_bcount, bp->b_data); #endif diff --git a/sys/arch/sparc/dev/xy.c b/sys/arch/sparc/dev/xy.c index ba0be46bd01..ea4838dee00 100644 --- a/sys/arch/sparc/dev/xy.c +++ b/sys/arch/sparc/dev/xy.c @@ -1,4 +1,4 @@ -/* $OpenBSD: xy.c,v 1.56 2013/10/20 10:11:16 krw Exp $ */ +/* $OpenBSD: xy.c,v 1.57 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: xy.c,v 1.26 1997/07/19 21:43:56 pk Exp $ */ /* @@ -1238,7 +1238,7 @@ xyc_startbuf(xycsc, xysc, bp) #ifdef XYC_DEBUG printf("xyc_startbuf: %s%c: %s block %lld\n", xysc->sc_dev.dv_xname, 'a' + partno, - (bp->b_flags & B_READ) ? "read" : "write", bp->b_blkno); + (bp->b_flags & B_READ) ? "read" : "write", (long long)bp->b_blkno); printf("xyc_startbuf: b_bcount %d, b_data 0x%x\n", bp->b_bcount, bp->b_data); #endif diff --git a/sys/arch/sparc64/dev/fd.c b/sys/arch/sparc64/dev/fd.c index 3f745b8e7df..72b1c785d12 100644 --- a/sys/arch/sparc64/dev/fd.c +++ b/sys/arch/sparc64/dev/fd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fd.c,v 1.40 2013/10/20 10:11:17 krw Exp $ */ +/* $OpenBSD: fd.c,v 1.41 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: fd.c,v 1.112 2003/08/07 16:29:35 agc Exp $ */ /*- @@ -748,8 +748,8 @@ fdstrategy(bp) #ifdef FD_DEBUG if (fdc_debug > 1) printf("fdstrategy: b_blkno %lld b_bcount %d blkno %lld cylin %d\n", - bp->b_blkno, bp->b_bcount, - fd->sc_blkno, bp->b_cylinder); + (long long)bp->b_blkno, bp->b_bcount, + (long long)fd->sc_blkno, bp->b_cylinder); #endif /* Queue transfer on drive, activate drive and controller if idle. */ @@ -1456,8 +1456,8 @@ loop: block = (fd->sc_cylin * type->heads + head) * type->sectrac + sec; if (block != fd->sc_blkno) { - printf("fdcintr: block %lld != blkno %d\n", - block, (int)fd->sc_blkno); + printf("fdcintr: block %lld != blkno %lld\n", + (long long)block, (long long)fd->sc_blkno); #if defined(FD_DEBUG) && defined(DDB) Debugger(); #endif @@ -1589,7 +1589,7 @@ loop: bp->b_flags & B_READ ? "read failed" : "write failed"); printf("blkno %lld nblks %d nstat %d tc %d\n", - fd->sc_blkno, fd->sc_nblks, + (long long)fd->sc_blkno, fd->sc_nblks, fdc->sc_nstat, fdc->sc_tc); } #endif diff --git a/sys/arch/sparc64/sparc64/machdep.c b/sys/arch/sparc64/sparc64/machdep.c index e35b092009a..be3d7ca1675 100644 --- a/sys/arch/sparc64/sparc64/machdep.c +++ b/sys/arch/sparc64/sparc64/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.148 2013/09/28 12:40:32 miod Exp $ */ +/* $OpenBSD: machdep.c,v 1.149 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: machdep.c,v 1.108 2001/07/24 19:30:14 eeh Exp $ */ /*- @@ -802,7 +802,7 @@ dumpsys() error = pmap_dumpmmu(dump, blkno); blkno += pmap_dumpsize(); -printf("starting dump, blkno %lld\n", blkno); +printf("starting dump, blkno %lld\n", (long long)blkno); for (mp = mem; mp->size; mp++) { u_int64_t i = 0, n; paddr_t maddr = mp->start; diff --git a/sys/dev/isa/fd.c b/sys/dev/isa/fd.c index 134e0c6edd2..aa816b3cbc6 100644 --- a/sys/dev/isa/fd.c +++ b/sys/dev/isa/fd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fd.c,v 1.95 2013/11/01 11:40:20 dlg Exp $ */ +/* $OpenBSD: fd.c,v 1.96 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: fd.c,v 1.90 1996/05/12 23:12:03 mycroft Exp $ */ /*- @@ -412,8 +412,9 @@ fdstrategy(struct buf *bp) bp->b_cylinder = bp->b_blkno / (fd_bsize / DEV_BSIZE) / fd->sc_type->seccyl; #ifdef FD_DEBUG - printf("fdstrategy: b_blkno %lld b_bcount %d blkno %lld cylin %d sz %d\n", - bp->b_blkno, bp->b_bcount, fd->sc_blkno, bp->b_cylinder, sz); + printf("fdstrategy: b_blkno %lld b_bcount %d blkno %lld cylin %d " + "sz %d\n", (long long)bp->b_blkno, bp->b_bcount, + (long long)fd->sc_blkno, bp->b_cylinder, sz); #endif /* Queue I/O */ @@ -834,7 +835,7 @@ loop: fdcstatus(&fd->sc_dev, 7, bp->b_flags & B_READ ? "read failed" : "write failed"); printf("blkno %lld nblks %d\n", - fd->sc_blkno, fd->sc_nblks); + (long long)fd->sc_blkno, fd->sc_nblks); #endif fdretry(fd); goto loop; diff --git a/sys/dev/softraid.c b/sys/dev/softraid.c index ff3d260d184..9641a64272f 100644 --- a/sys/dev/softraid.c +++ b/sys/dev/softraid.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid.c,v 1.311 2013/07/19 17:14:13 krw Exp $ */ +/* $OpenBSD: softraid.c,v 1.312 2013/11/01 17:36:19 krw Exp $ */ /* * Copyright (c) 2007, 2008, 2009 Marco Peereboom <marco@peereboom.us> * Copyright (c) 2008 Chris Kuethe <ckuethe@openbsd.org> @@ -2051,7 +2051,7 @@ sr_ccb_rw(struct sr_discipline *sd, int chunk, daddr_t blkno, DNPRINTF(SR_D_DIS, "%s: %s %s ccb " "b_bcount %d b_blkno %lld b_flags 0x%0x b_data %p\n", DEVNAME(sd->sd_sc), sd->sd_meta->ssd_devname, sd->sd_name, - ccb->ccb_buf.b_bcount, ccb->ccb_buf.b_blkno, + ccb->ccb_buf.b_bcount, (long long)ccb->ccb_buf.b_blkno, ccb->ccb_buf.b_flags, ccb->ccb_buf.b_data); out: @@ -2069,7 +2069,7 @@ sr_ccb_done(struct sr_ccb *ccb) " b_flags 0x%0x block %lld target %d\n", DEVNAME(sc), sd->sd_meta->ssd_devname, sd->sd_name, ccb->ccb_buf.b_bcount, ccb->ccb_buf.b_resid, ccb->ccb_buf.b_flags, - ccb->ccb_buf.b_blkno, ccb->ccb_target); + (long long)ccb->ccb_buf.b_blkno, ccb->ccb_target); splassert(IPL_BIO); @@ -2078,14 +2078,16 @@ sr_ccb_done(struct sr_ccb *ccb) if (ccb->ccb_buf.b_flags & B_ERROR) { DNPRINTF(SR_D_INTR, "%s: i/o error on block %lld target %d\n", - DEVNAME(sc), ccb->ccb_buf.b_blkno, ccb->ccb_target); + DEVNAME(sc), (long long)ccb->ccb_buf.b_blkno, + ccb->ccb_target); if (ISSET(sd->sd_capabilities, SR_CAP_REDUNDANT)) sd->sd_set_chunk_state(sd, ccb->ccb_target, BIOC_SDOFFLINE); else printf("%s: i/o error on block %lld target %d " - "b_error %d\n", DEVNAME(sc), ccb->ccb_buf.b_blkno, - ccb->ccb_target, ccb->ccb_buf.b_error); + "b_error %d\n", DEVNAME(sc), + (long long)ccb->ccb_buf.b_blkno, ccb->ccb_target, + ccb->ccb_buf.b_error); ccb->ccb_state = SR_CCB_FAILED; wu->swu_ios_failed++; } else { @@ -4543,8 +4545,8 @@ sr_validate_io(struct sr_workunit *wu, daddr_t *blk, char *func) if (wu->swu_blk_end > sd->sd_meta->ssdi.ssd_size) { DNPRINTF(SR_D_DIS, "%s: %s out of bounds start: %lld " "end: %lld length: %d\n", - DEVNAME(sd->sd_sc), func, wu->swu_blk_start, - wu->swu_blk_end, xs->datalen); + DEVNAME(sd->sd_sc), func, (long long)wu->swu_blk_start, + (long long)wu->swu_blk_end, xs->datalen); sd->sd_scsi_sense.error_code = SSD_ERRCODE_CURRENT | SSD_ERRCODE_VALID; diff --git a/sys/dev/softraid_concat.c b/sys/dev/softraid_concat.c index 0911464f19c..dd7dad77f13 100644 --- a/sys/dev/softraid_concat.c +++ b/sys/dev/softraid_concat.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid_concat.c,v 1.17 2013/06/11 16:42:13 deraadt Exp $ */ +/* $OpenBSD: softraid_concat.c,v 1.18 2013/11/01 17:36:19 krw Exp $ */ /* * Copyright (c) 2008 Marco Peereboom <marco@peereboom.us> * Copyright (c) 2011 Joel Sing <jsing@openbsd.org> @@ -144,7 +144,9 @@ sr_concat_rw(struct sr_workunit *wu) "chunk %lld chunkend %lld physoffs %lld length %lld " "leftover %lld data %p\n", DEVNAME(sd->sd_sc), sd->sd_meta->ssd_devname, sd->sd_name, - lbaoffs, chunk, chunkend, physoffs, length, leftover, data); + (long long)lbaoffs, (long long)chunk, (long long)chunkend, + (long long)physoffs, (long long)length, (long long)leftover, + data); blk = physoffs >> DEV_BSHIFT; ccb = sr_ccb_rw(sd, chunk, blk, length, data, xs->flags, 0); diff --git a/sys/dev/softraid_raid0.c b/sys/dev/softraid_raid0.c index 045202c9c77..0bb6a1834c2 100644 --- a/sys/dev/softraid_raid0.c +++ b/sys/dev/softraid_raid0.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid_raid0.c,v 1.41 2013/06/11 16:42:13 deraadt Exp $ */ +/* $OpenBSD: softraid_raid0.c,v 1.42 2013/11/01 17:36:19 krw Exp $ */ /* * Copyright (c) 2008 Marco Peereboom <marco@peereboom.us> * @@ -135,7 +135,7 @@ sr_raid0_rw(struct sr_workunit *wu) DNPRINTF(SR_D_DIS, "%s: %s: front end io: lba %lld size %d\n", DEVNAME(sd->sd_sc), sd->sd_meta->ssd_devname, - blk, xs->datalen); + (long long)blk, xs->datalen); /* all offs are in bytes */ lbaoffs = blk << DEV_BSHIFT; @@ -159,8 +159,10 @@ sr_raid0_rw(struct sr_workunit *wu) "chunkoffs %lld physoffs %lld length %lld " "leftover %lld data %p\n", DEVNAME(sd->sd_sc), sd->sd_meta->ssd_devname, sd->sd_name, - lbaoffs, strip_no, chunk, stripoffs, chunkoffs, physoffs, - length, leftover, data); + (long long)lbaoffs, (long long)strip_no, (long long)chunk, + (long long)stripoffs, (long long)chunkoffs, + (long long)physoffs, (long long)length, (long long)leftover, + data); blk = physoffs >> DEV_BSHIFT; ccb = sr_ccb_rw(sd, chunk, blk, length, data, xs->flags, 0); diff --git a/sys/dev/softraid_raid1.c b/sys/dev/softraid_raid1.c index 7f4ab1844d1..fc0af76e9e8 100644 --- a/sys/dev/softraid_raid1.c +++ b/sys/dev/softraid_raid1.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid_raid1.c,v 1.53 2013/06/11 16:42:13 deraadt Exp $ */ +/* $OpenBSD: softraid_raid1.c,v 1.54 2013/11/01 17:36:19 krw Exp $ */ /* * Copyright (c) 2007 Marco Peereboom <marco@peereboom.us> * @@ -426,7 +426,7 @@ sr_raid1_wu_done(struct sr_workunit *wu) /* If all I/O failed, retry reads and give up on writes. */ if (xs->flags & SCSI_DATA_IN) { printf("%s: retrying read on block %lld\n", - sd->sd_meta->ssd_devname, wu->swu_blk_start); + sd->sd_meta->ssd_devname, (long long)wu->swu_blk_start); if (wu->swu_cb_active == 1) panic("%s: sr_raid1_intr_cb", DEVNAME(sd->sd_sc)); @@ -436,7 +436,7 @@ sr_raid1_wu_done(struct sr_workunit *wu) return SR_WU_RESTART; } else { printf("%s: permanently failing write on block %lld\n", - sd->sd_meta->ssd_devname, wu->swu_blk_start); + sd->sd_meta->ssd_devname, (long long)wu->swu_blk_start); } wu->swu_state = SR_WU_FAILED; diff --git a/sys/dev/softraid_raid6.c b/sys/dev/softraid_raid6.c index 8f9ed81b801..d5068d4ab34 100644 --- a/sys/dev/softraid_raid6.c +++ b/sys/dev/softraid_raid6.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid_raid6.c,v 1.53 2013/06/11 16:42:13 deraadt Exp $ */ +/* $OpenBSD: softraid_raid6.c,v 1.54 2013/11/01 17:36:19 krw Exp $ */ /* * Copyright (c) 2009 Marco Peereboom <marco@peereboom.us> * Copyright (c) 2009 Jordan Hargrave <jordan@openbsd.org> @@ -717,14 +717,14 @@ sr_raid6_wu_done(struct sr_workunit *wu) if (xs->flags & SCSI_DATA_IN) { printf("%s: retrying read on block %lld\n", - sd->sd_meta->ssd_devname, wu->swu_blk_start); + sd->sd_meta->ssd_devname, (long long)wu->swu_blk_start); sr_wu_release_ccbs(wu); wu->swu_state = SR_WU_RESTART; if (sd->sd_scsi_rw(wu) == 0) return SR_WU_RESTART; } else { printf("%s: permanently fail write on block %lld\n", - sd->sd_meta->ssd_devname, wu->swu_blk_start); + sd->sd_meta->ssd_devname, (long long)wu->swu_blk_start); } wu->swu_state = SR_WU_FAILED; diff --git a/sys/dev/softraid_raidp.c b/sys/dev/softraid_raidp.c index 99b9571ec8a..e5091428e4b 100644 --- a/sys/dev/softraid_raidp.c +++ b/sys/dev/softraid_raidp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid_raidp.c,v 1.50 2013/06/11 16:42:13 deraadt Exp $ */ +/* $OpenBSD: softraid_raidp.c,v 1.51 2013/11/01 17:36:19 krw Exp $ */ /* * Copyright (c) 2009 Marco Peereboom <marco@peereboom.us> * Copyright (c) 2009 Jordan Hargrave <jordan@openbsd.org> @@ -550,14 +550,14 @@ sr_raidp_wu_done(struct sr_workunit *wu) if (xs->flags & SCSI_DATA_IN) { printf("%s: retrying read on block %lld\n", - sd->sd_meta->ssd_devname, wu->swu_blk_start); + sd->sd_meta->ssd_devname, (long long)wu->swu_blk_start); sr_wu_release_ccbs(wu); wu->swu_state = SR_WU_RESTART; if (sd->sd_scsi_rw(wu) == 0) return SR_WU_RESTART; } else { printf("%s: permanently fail write on block %lld\n", - sd->sd_meta->ssd_devname, wu->swu_blk_start); + sd->sd_meta->ssd_devname, (long long)wu->swu_blk_start); } wu->swu_state = SR_WU_FAILED; diff --git a/sys/dev/vnd.c b/sys/dev/vnd.c index 186bf492ff3..bf92ff26d07 100644 --- a/sys/dev/vnd.c +++ b/sys/dev/vnd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vnd.c,v 1.150 2013/06/11 16:42:14 deraadt Exp $ */ +/* $OpenBSD: vnd.c,v 1.151 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: vnd.c,v 1.26 1996/03/30 23:06:11 christos Exp $ */ /* @@ -310,7 +310,8 @@ vndstrategy(struct buf *bp) printf("%s: sloppy %s from proc %d (%s): " "blkno %lld bcount %ld\n", sc->sc_dev.dv_xname, (bp->b_flags & B_READ) ? "read" : "write", - pr->p_pid, pr->p_comm, bp->b_blkno, origbcount); + pr->p_pid, pr->p_comm, (long long)bp->b_blkno, + origbcount); } #endif } diff --git a/sys/kern/subr_disk.c b/sys/kern/subr_disk.c index 8a7e87846ea..88940ea98db 100644 --- a/sys/kern/subr_disk.c +++ b/sys/kern/subr_disk.c @@ -1,4 +1,4 @@ -/* $OpenBSD: subr_disk.c,v 1.156 2013/10/20 13:15:35 krw Exp $ */ +/* $OpenBSD: subr_disk.c,v 1.157 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: subr_disk.c,v 1.17 1996/03/16 23:17:08 christos Exp $ */ /* @@ -765,22 +765,23 @@ diskerr(struct buf *bp, char *dname, char *what, int pri, int blkdone, bp->b_flags & B_READ ? "read" : "writ"); sn = bp->b_blkno; if (bp->b_bcount <= DEV_BSIZE) - (*pr)("%lld", sn); + (*pr)("%lld", (long long)sn); else { if (blkdone >= 0) { sn += blkdone; - (*pr)("%lld of ", sn); + (*pr)("%lld of ", (long long)sn); } - (*pr)("%lld-%lld", bp->b_blkno, - bp->b_blkno + (bp->b_bcount - 1) / DEV_BSIZE); + (*pr)("%lld-%lld", (long long)bp->b_blkno, + (long long)(bp->b_blkno + (bp->b_bcount - 1) / DEV_BSIZE)); } if (lp && (blkdone >= 0 || bp->b_bcount <= lp->d_secsize)) { sn += DL_SECTOBLK(lp, DL_GETPOFFSET(&lp->d_partitions[part])); - (*pr)(" (%s%d bn %lld; cn %lld", dname, unit, sn, - sn / DL_SECTOBLK(lp, lp->d_secpercyl)); + (*pr)(" (%s%d bn %lld; cn %lld", dname, unit, (long long)sn, + (long long)(sn / DL_SECTOBLK(lp, lp->d_secpercyl))); sn %= DL_SECTOBLK(lp, lp->d_secpercyl); - (*pr)(" tn %lld sn %lld)", sn / DL_SECTOBLK(lp, lp->d_nsectors), - sn % DL_SECTOBLK(lp, lp->d_nsectors)); + (*pr)(" tn %lld sn %lld)", + (long long)(sn / DL_SECTOBLK(lp, lp->d_nsectors)), + (long long)(sn % DL_SECTOBLK(lp, lp->d_nsectors))); } } diff --git a/sys/scsi/cd.c b/sys/scsi/cd.c index 1bbbec7274f..cecb73d9c11 100644 --- a/sys/scsi/cd.c +++ b/sys/scsi/cd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cd.c,v 1.212 2013/10/03 14:07:41 krw Exp $ */ +/* $OpenBSD: cd.c,v 1.213 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: cd.c,v 1.100 1997/04/02 02:29:30 mycroft Exp $ */ /* @@ -458,7 +458,7 @@ cdstrategy(struct buf *bp) } SC_DEBUG(sc->sc_link, SDEV_DB2, ("cdstrategy: %ld bytes @ blk %lld\n", - bp->b_bcount, bp->b_blkno)); + bp->b_bcount, (long long)bp->b_blkno)); /* * If the device has been made invalid, error out * maybe the media changed, or no media loaded diff --git a/sys/scsi/sd.c b/sys/scsi/sd.c index 61a87ce4dac..da02600c0ea 100644 --- a/sys/scsi/sd.c +++ b/sys/scsi/sd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sd.c,v 1.250 2013/10/03 14:07:42 krw Exp $ */ +/* $OpenBSD: sd.c,v 1.251 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: sd.c,v 1.111 1997/04/02 02:29:41 mycroft Exp $ */ /*- @@ -532,7 +532,7 @@ sdstrategy(struct buf *bp) } SC_DEBUG(sc->sc_link, SDEV_DB2, ("sdstrategy: %ld bytes @ blk %lld\n", - bp->b_bcount, bp->b_blkno)); + bp->b_bcount, (long long)bp->b_blkno)); /* * If the device has been made invalid, error out */ @@ -1325,7 +1325,8 @@ sddump(dev_t dev, daddr_t blkno, caddr_t va, size_t size) return (ENXIO); #else /* SD_DUMP_NOT_TRUSTED */ /* Let's just talk about this first... */ - printf("sd%d: dump addr 0x%x, blk %lld\n", unit, va, blkno); + printf("sd%d: dump addr 0x%x, blk %lld\n", unit, va, + (long long)blkno); delay(500 * 1000); /* half a second */ #endif /* SD_DUMP_NOT_TRUSTED */ diff --git a/sys/scsi/st.c b/sys/scsi/st.c index a9cea73c86c..cdf862cf270 100644 --- a/sys/scsi/st.c +++ b/sys/scsi/st.c @@ -1,4 +1,4 @@ -/* $OpenBSD: st.c,v 1.125 2013/10/03 14:07:42 krw Exp $ */ +/* $OpenBSD: st.c,v 1.126 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: st.c,v 1.71 1997/02/21 23:03:49 thorpej Exp $ */ /* @@ -842,7 +842,7 @@ ststrategy(struct buf *bp) sc_link = st->sc_link; SC_DEBUG(sc_link, SDEV_DB2, ("ststrategy: %ld bytes @ blk %lld\n", - bp->b_bcount, bp->b_blkno)); + bp->b_bcount, (long long)bp->b_blkno)); /* * If it's a null transfer, return immediately. diff --git a/sys/ufs/ext2fs/ext2fs_subr.c b/sys/ufs/ext2fs/ext2fs_subr.c index 2d99e193ac7..6374d40dee3 100644 --- a/sys/ufs/ext2fs/ext2fs_subr.c +++ b/sys/ufs/ext2fs/ext2fs_subr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ext2fs_subr.c,v 1.28 2013/06/11 16:42:18 deraadt Exp $ */ +/* $OpenBSD: ext2fs_subr.c,v 1.29 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: ext2fs_subr.c,v 1.1 1997/06/11 09:34:03 bouyer Exp $ */ /* @@ -125,8 +125,8 @@ ext2fs_checkoverlap(struct buf *bp, struct inode *ip) continue; vprint("Disk overlap", vp); printf("\tstart %lld, end %lld overlap start %lld, end %lld\n", - start, last, ep->b_blkno, - ep->b_blkno + btodb(ep->b_bcount) - 1); + start, last, (long long)ep->b_blkno, + (long long)(ep->b_blkno + btodb(ep->b_bcount) - 1)); panic("Disk buffer overlap"); } } diff --git a/sys/ufs/ffs/ffs_alloc.c b/sys/ufs/ffs/ffs_alloc.c index 78ed796e954..04c841807a3 100644 --- a/sys/ufs/ffs/ffs_alloc.c +++ b/sys/ufs/ffs/ffs_alloc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ffs_alloc.c,v 1.96 2013/06/11 16:42:18 deraadt Exp $ */ +/* $OpenBSD: ffs_alloc.c,v 1.97 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: ffs_alloc.c,v 1.11 1996/05/11 18:27:09 mycroft Exp $ */ /* @@ -214,7 +214,7 @@ ffs_realloccg(struct inode *ip, daddr_t lbprev, daddr_t bpref, int osize, if (bprev == 0) { printf("dev = 0x%x, bsize = %d, bprev = %lld, fs = %s\n", - ip->i_dev, fs->fs_bsize, bprev, fs->fs_fsmnt); + ip->i_dev, fs->fs_bsize, (long long)bprev, fs->fs_fsmnt); panic("ffs_realloccg: bad bprev"); } @@ -473,7 +473,7 @@ ffs1_reallocblks(void *v) #ifdef DEBUG if (prtrealloc) printf("realloc: ino %u, lbns %lld-%lld\n\told:", ip->i_number, - start_lbn, end_lbn); + (long long)start_lbn, (long long)end_lbn); #endif blkno = newblk; for (bap = &sbap[soff], i = 0; i < len; i++, blkno += fs->fs_frag) { @@ -554,7 +554,7 @@ ffs1_reallocblks(void *v) dbtofsb(fs, buflist->bs_children[i]->b_blkno), fs->fs_bsize)) panic("ffs1_reallocblks: unallocated block 3"); if (prtrealloc) - printf(" %lld,", blkno); + printf(" %lld,", (long long)blkno); #endif } #ifdef DEBUG @@ -685,7 +685,7 @@ ffs2_reallocblks(void *v) #ifdef DEBUG if (prtrealloc) printf("realloc: ino %u, lbns %lld-%lld\n\told:", ip->i_number, - start_lbn, end_lbn); + (long long)start_lbn, (long long)end_lbn); #endif blkno = newblk; @@ -704,7 +704,7 @@ ffs2_reallocblks(void *v) #endif #ifdef DEBUG if (prtrealloc) - printf(" %lld,", *bap); + printf(" %lld,", (long long)*bap); #endif if (DOINGSOFTDEP(vp)) { if (sbap == &ip->i_din2->di_db[0] && i < ssize) @@ -770,7 +770,7 @@ ffs2_reallocblks(void *v) #endif #ifdef DEBUG if (prtrealloc) - printf(" %lld,", blkno); + printf(" %lld,", (long long)blkno); #endif } #ifdef DEBUG @@ -880,7 +880,7 @@ ffs_inode_alloc(struct inode *pip, mode_t mode, struct ucred *cred, if (DIP(ip, blocks)) { printf("free inode %s/%d had %lld blocks\n", - fs->fs_fsmnt, ino, (daddr_t)DIP(ip, blocks)); + fs->fs_fsmnt, ino, (long long)DIP(ip, blocks)); DIP_ASSIGN(ip, blocks, 0); } @@ -1850,7 +1850,8 @@ ffs_blkfree(struct inode *ip, daddr_t bno, long size) } cg = dtog(fs, bno); if ((u_int)bno >= fs->fs_size) { - printf("bad block %lld, ino %u\n", bno, ip->i_number); + printf("bad block %lld, ino %u\n", (long long)bno, + ip->i_number); ffs_fserr(fs, DIP(ip, uid), "bad block"); return; } @@ -1865,7 +1866,7 @@ ffs_blkfree(struct inode *ip, daddr_t bno, long size) blkno = fragstoblks(fs, bno); if (!ffs_isfreeblock(fs, cg_blksfree(cgp), blkno)) { printf("dev = 0x%x, block = %lld, fs = %s\n", - ip->i_dev, bno, fs->fs_fsmnt); + ip->i_dev, (long long)bno, fs->fs_fsmnt); panic("ffs_blkfree: freeing free block"); } ffs_setblock(fs, cg_blksfree(cgp), blkno); @@ -1894,7 +1895,8 @@ ffs_blkfree(struct inode *ip, daddr_t bno, long size) for (i = 0; i < frags; i++) { if (isset(cg_blksfree(cgp), bno + i)) { printf("dev = 0x%x, block = %lld, fs = %s\n", - ip->i_dev, bno + i, fs->fs_fsmnt); + ip->i_dev, (long long)(bno + i), + fs->fs_fsmnt); panic("ffs_blkfree: freeing free frag"); } setbit(cg_blksfree(cgp), bno + i); @@ -2011,7 +2013,7 @@ ffs_checkblk(struct inode *ip, daddr_t bno, long size) panic("ffs_checkblk: bad size"); } if ((u_int)bno >= fs->fs_size) - panic("ffs_checkblk: bad block %lld", bno); + panic("ffs_checkblk: bad block %lld", (long long)bno); if (!(bp = ffs_cgread(fs, ip, dtog(fs, bno)))) return (0); @@ -2090,7 +2092,7 @@ ffs_mapsearch(struct fs *fs, struct cg *cgp, daddr_t bpref, int allocsiz) subfield <<= 1; } } - printf("bno = %lld, fs = %s\n", bno, fs->fs_fsmnt); + printf("bno = %lld, fs = %s\n", (long long)bno, fs->fs_fsmnt); panic("ffs_alloccg: block not in map"); return (-1); } diff --git a/sys/ufs/ffs/ffs_softdep.c b/sys/ufs/ffs/ffs_softdep.c index 03d51c83346..7129d40b3c0 100644 --- a/sys/ufs/ffs/ffs_softdep.c +++ b/sys/ufs/ffs/ffs_softdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ffs_softdep.c,v 1.120 2013/08/09 08:20:05 syl Exp $ */ +/* $OpenBSD: ffs_softdep.c,v 1.121 2013/11/01 17:36:19 krw Exp $ */ /* * Copyright 1998, 2000 Marshall Kirk McKusick. All Rights Reserved. @@ -1528,8 +1528,9 @@ allocdirect_merge(struct allocdirectlst *adphead, struct allocdirect *newadp, newadp->ad_oldsize != oldadp->ad_newsize || newadp->ad_lbn >= NDADDR) { FREE_LOCK(&lk); - panic("allocdirect_merge: old %lld != new %lld || lbn %lld >= %d", - newadp->ad_oldblkno, oldadp->ad_newblkno, newadp->ad_lbn, + panic("allocdirect_merge: old %lld != new %lld || lbn %lld >= " + "%d", (long long)newadp->ad_oldblkno, + (long long)oldadp->ad_newblkno, (long long)newadp->ad_lbn, NDADDR); } newadp->ad_oldblkno = oldadp->ad_oldblkno; @@ -3425,15 +3426,16 @@ initiate_write_inodeblock_ufs1(struct inodedep *inodedep, struct buf *bp) (d1 = dp->di_db[adp->ad_lbn]) != (d2 = adp->ad_newblkno)) { FREE_LOCK(&lk); panic("%s: direct pointer #%lld mismatch %d != %d", - "softdep_write_inodeblock", adp->ad_lbn, d1, d2); + "softdep_write_inodeblock", (long long)adp->ad_lbn, + d1, d2); } if (adp->ad_lbn >= NDADDR && (d1 = dp->di_ib[adp->ad_lbn - NDADDR]) != (d2 = adp->ad_newblkno)) { FREE_LOCK(&lk); panic("%s: indirect pointer #%lld mismatch %d != %d", - "softdep_write_inodeblock", adp->ad_lbn - NDADDR, - d1, d2); + "softdep_write_inodeblock", (long long)(adp->ad_lbn - + NDADDR), d1, d2); } deplist |= 1 << adp->ad_lbn; if ((adp->ad_state & ATTACHED) == 0) { @@ -3571,7 +3573,8 @@ initiate_write_inodeblock_ufs2(struct inodedep *inodedep, struct buf *bp) (d2 = adp->ad_newblkno)) { FREE_LOCK(&lk); panic("%s: direct pointer #%lld mismatch %lld != %lld", - "softdep_write_inodeblock", adp->ad_lbn, d1, d2); + "softdep_write_inodeblock", (long long)adp->ad_lbn, + d1, d2); } deplist |= 1 << adp->ad_lbn; if ((adp->ad_state & ATTACHED) == 0) { @@ -3638,15 +3641,16 @@ initiate_write_inodeblock_ufs2(struct inodedep *inodedep, struct buf *bp) (d1 = dp->di_db[adp->ad_lbn]) != (d2 = adp->ad_newblkno)) { FREE_LOCK(&lk); panic("%s: direct pointer #%lld mismatch %lld != %lld", - "softdep_write_inodeblock", adp->ad_lbn, d1, d2); + "softdep_write_inodeblock", (long long)adp->ad_lbn, + d1, d2); } if (adp->ad_lbn >= NDADDR && (d1 = dp->di_ib[adp->ad_lbn - NDADDR]) != (d2 = adp->ad_newblkno)) { FREE_LOCK(&lk); panic("%s: indirect pointer #%lld mismatch %lld != %lld", - "softdep_write_inodeblock", adp->ad_lbn - NDADDR, - d1, d2); + "softdep_write_inodeblock", (long long)(adp->ad_lbn - + NDADDR), d1, d2); } deplist |= 1 << adp->ad_lbn; if ((adp->ad_state & ATTACHED) == 0) { @@ -4033,7 +4037,8 @@ handle_written_inodeblock(struct inodedep *inodedep, struct buf *bp) if (dp1->di_db[adp->ad_lbn] != adp->ad_oldblkno) panic("%s: %s #%lld mismatch %d != %lld", "handle_written_inodeblock", - "direct pointer", adp->ad_lbn, + "direct pointer", + (long long)adp->ad_lbn, dp1->di_db[adp->ad_lbn], adp->ad_oldblkno); dp1->di_db[adp->ad_lbn] = adp->ad_newblkno; @@ -4042,7 +4047,7 @@ handle_written_inodeblock(struct inodedep *inodedep, struct buf *bp) panic("%s: %s #%lld allocated as %d", "handle_written_inodeblock", "indirect pointer", - adp->ad_lbn - NDADDR, + (long long)(adp->ad_lbn - NDADDR), dp1->di_ib[adp->ad_lbn - NDADDR]); dp1->di_ib[adp->ad_lbn - NDADDR] = adp->ad_newblkno; @@ -4050,18 +4055,19 @@ handle_written_inodeblock(struct inodedep *inodedep, struct buf *bp) } else { if (adp->ad_lbn < NDADDR) { if (dp2->di_db[adp->ad_lbn] != adp->ad_oldblkno) - panic("%s: %s #%lld mismatch %lld != %lld", - "handle_written_inodeblock", - "direct pointer", adp->ad_lbn, + panic("%s: %s #%lld mismatch %lld != " + "%lld", "handle_written_inodeblock", + "direct pointer", + (long long)adp->ad_lbn, dp2->di_db[adp->ad_lbn], - adp->ad_oldblkno); + (long long)adp->ad_oldblkno); dp2->di_db[adp->ad_lbn] = adp->ad_newblkno; } else { if (dp2->di_ib[adp->ad_lbn - NDADDR] != 0) panic("%s: %s #%lld allocated as %lld", "handle_written_inodeblock", "indirect pointer", - adp->ad_lbn - NDADDR, + (long long)(adp->ad_lbn - NDADDR), dp2->di_ib[adp->ad_lbn - NDADDR]); dp2->di_ib[adp->ad_lbn - NDADDR] = adp->ad_newblkno; @@ -5651,7 +5657,7 @@ worklist_print(struct worklist *wk, int full, case D_PAGEDEP: pagedep = WK_PAGEDEP(wk); (*pr)("mount %p ino %u lbn %lld\n", pagedep->pd_mnt, - pagedep->pd_ino, pagedep->pd_lbn); + pagedep->pd_ino, (long long)pagedep->pd_lbn); break; case D_INODEDEP: inodedep = WK_INODEDEP(wk); @@ -5664,8 +5670,8 @@ worklist_print(struct worklist *wk, int full, case D_NEWBLK: newblk = WK_NEWBLK(wk); (*pr)("fs %p newblk %lld state %d bmsafemap %p\n", - newblk->nb_fs, newblk->nb_newblkno, newblk->nb_state, - newblk->nb_bmsafemap); + newblk->nb_fs, (long long)newblk->nb_newblkno, + newblk->nb_state, newblk->nb_bmsafemap); break; case D_BMSAFEMAP: bmsafemap = WK_BMSAFEMAP(wk); @@ -5673,9 +5679,10 @@ worklist_print(struct worklist *wk, int full, break; case D_ALLOCDIRECT: adp = WK_ALLOCDIRECT(wk); - (*pr)("lbn %lld newlbk %lld oldblk %lld newsize %ld olsize %ld\n" - "%s bp %p inodedep %p freefrag %p\n", adp->ad_lbn, - adp->ad_newblkno, adp->ad_oldblkno, adp->ad_newsize, + (*pr)("lbn %lld newlbk %lld oldblk %lld newsize %ld olsize " + "%ld\n%s bp %p inodedep %p freefrag %p\n", + (long long)adp->ad_lbn, (long long)adp->ad_newblkno, + (long long)adp->ad_oldblkno, adp->ad_newsize, adp->ad_oldsize, prefix, adp->ad_buf, adp->ad_inodedep, adp->ad_freefrag); break; @@ -5688,14 +5695,15 @@ worklist_print(struct worklist *wk, int full, aip = WK_ALLOCINDIR(wk); (*pr)("off %d newblk %lld oldblk %lld freefrag %p\n" "%s indirdep %p buf %p\n", aip->ai_offset, - aip->ai_newblkno, aip->ai_oldblkno, aip->ai_freefrag, - prefix, aip->ai_indirdep, aip->ai_buf); + (long long)aip->ai_newblkno, (long long)aip->ai_oldblkno, + aip->ai_freefrag, prefix, aip->ai_indirdep, aip->ai_buf); break; case D_FREEFRAG: freefrag = WK_FREEFRAG(wk); (*pr)("vnode %p mp %p blkno %lld fsize %ld ino %u\n", - freefrag->ff_devvp, freefrag->ff_mnt, freefrag->ff_blkno, - freefrag->ff_fragsize, freefrag->ff_inum); + freefrag->ff_devvp, freefrag->ff_mnt, + (long long)freefrag->ff_blkno, freefrag->ff_fragsize, + freefrag->ff_inum); break; case D_FREEBLKS: freeblks = WK_FREEBLKS(wk); diff --git a/sys/ufs/ffs/ffs_subr.c b/sys/ufs/ffs/ffs_subr.c index 30cab351fd4..7f5aab936bb 100644 --- a/sys/ufs/ffs/ffs_subr.c +++ b/sys/ufs/ffs/ffs_subr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ffs_subr.c,v 1.27 2013/06/11 16:42:18 deraadt Exp $ */ +/* $OpenBSD: ffs_subr.c,v 1.28 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: ffs_subr.c,v 1.6 1996/03/17 02:16:23 christos Exp $ */ /* @@ -142,9 +142,10 @@ ffs_checkoverlap(struct buf *bp, struct inode *ip) ep->b_blkno + btodb(ep->b_bcount) <= start) continue; vprint("Disk overlap", vp); - (void)printf("\tstart %lld, end %lld overlap start %llu, end %llu\n", - start, last, ep->b_blkno, - ep->b_blkno + btodb(ep->b_bcount) - 1); + (void)printf("\tstart %lld, end %lld overlap start %llu, " + "end %llu\n", (long long)start, (long long)last, + (long long)ep->b_blkno, + (long long)(ep->b_blkno + btodb(ep->b_bcount) - 1)); panic("Disk buffer overlap"); } } diff --git a/sys/ufs/ufs/ufs_bmap.c b/sys/ufs/ufs/ufs_bmap.c index a584164e740..ca606b62bea 100644 --- a/sys/ufs/ufs/ufs_bmap.c +++ b/sys/ufs/ufs/ufs_bmap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ufs_bmap.c,v 1.33 2013/06/11 16:42:19 deraadt Exp $ */ +/* $OpenBSD: ufs_bmap.c,v 1.34 2013/11/01 17:36:19 krw Exp $ */ /* $NetBSD: ufs_bmap.c,v 1.3 1996/02/09 22:36:00 christos Exp $ */ /* @@ -243,7 +243,7 @@ ufs_getlbns(struct vnode *vp, daddr_t bn, struct indir *ap, int *nump) #ifdef DIAGNOSTIC if (realbn < 0 && realbn > -NDADDR) { panic ("ufs_getlbns: Invalid indirect block %lld specified", - realbn); + (long long)realbn); } #endif @@ -299,7 +299,8 @@ ufs_getlbns(struct vnode *vp, daddr_t bn, struct indir *ap, int *nump) } #ifdef DIAGNOSTIC if (realbn < 0 && metalbn != realbn) { - panic("ufs_getlbns: indirect block %lld not found", realbn); + panic("ufs_getlbns: indirect block %lld not found", + (long long)realbn); } #endif if (nump) |