diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 2007-06-06 17:15:15 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 2007-06-06 17:15:15 +0000 |
commit | 64b0758a0244e515108eec4f2cd5d05a5939ebf1 (patch) | |
tree | e5e991586e626374ede95d07956bcaf6a47372be /sys/arch | |
parent | a0f03208acbc7a85466c7cf68058959c1bbe9668 (diff) |
now that all partition size/offsets are potentially 64-bit, change the
type of all variables to daddr64_t. this includes the APIs for XXsize()
and XXdump(), all range checks inside bio drivers, internal variables
for disklabel handling, and even uvm's swap offsets. re-read numerous
times by otto, miod, krw, thib to look for errors
Diffstat (limited to 'sys/arch')
49 files changed, 167 insertions, 160 deletions
diff --git a/sys/arch/alpha/alpha/disksubr.c b/sys/arch/alpha/alpha/disksubr.c index 2e0dbec03da..e41fb68b0b3 100644 --- a/sys/arch/alpha/alpha/disksubr.c +++ b/sys/arch/alpha/alpha/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.74 2007/06/06 16:42:01 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.75 2007/06/06 17:15:11 deraadt Exp $ */ /* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */ /* @@ -208,7 +208,7 @@ readdoslabel(struct buf *bp, void (*strat)(struct buf *), struct partition *pp; unsigned long extoff = 0; unsigned int fattest; - daddr_t part_blkno = DOSBBSECTOR; + daddr64_t part_blkno = DOSBBSECTOR; char *msg = NULL; int dospartoff, cyl, i, ourpart = -1; int wander = 1, n = 0, loop = 0; diff --git a/sys/arch/alpha/alpha/machdep.c b/sys/arch/alpha/alpha/machdep.c index d130bc4bea8..b90acefc027 100644 --- a/sys/arch/alpha/alpha/machdep.c +++ b/sys/arch/alpha/alpha/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.109 2007/05/29 20:36:47 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.110 2007/06/06 17:15:11 deraadt Exp $ */ /* $NetBSD: machdep.c,v 1.210 2000/06/01 17:12:38 thorpej Exp $ */ /*- @@ -1152,7 +1152,7 @@ cpu_dump_mempagecnt() int cpu_dump() { - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); char buf[dbtob(1)]; kcore_seg_t *segp; cpu_kcore_hdr_t *cpuhdrp; @@ -1236,8 +1236,8 @@ dumpsys() u_long totalbytesleft, bytes, i, n, memcl; u_long maddr; int psize; - daddr_t blkno; - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + daddr64_t blkno; + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); int error; extern int msgbufmapped; diff --git a/sys/arch/alpha/stand/installboot.c b/sys/arch/alpha/stand/installboot.c index 65f15260e7f..6ee4487ef65 100644 --- a/sys/arch/alpha/stand/installboot.c +++ b/sys/arch/alpha/stand/installboot.c @@ -1,4 +1,4 @@ -/* $OpenBSD: installboot.c,v 1.13 2005/08/01 05:01:35 deraadt Exp $ */ +/* $OpenBSD: installboot.c,v 1.14 2007/06/06 17:15:11 deraadt Exp $ */ /* $NetBSD: installboot.c,v 1.2 1997/04/06 08:41:12 cgd Exp $ */ /* @@ -92,7 +92,7 @@ main(int argc, char *argv[]) long protosize; struct stat disksb, bootsb; struct disklabel dl; - unsigned long partoffset; + daddr64_t partoffset; #define BBPAD 0x1e0 struct bb { char bb_pad[BBPAD]; /* disklabel lives in here, actually */ @@ -165,8 +165,8 @@ main(int argc, char *argv[]) * into the disk. If disklabels not supported, assume zero. */ if (ioctl(devfd, DIOCGDINFO, &dl) != -1) { - partoffset = dl.d_partitions[minor(bootsb.st_dev) % - getmaxpartitions()].p_offset; + partoffset = DL_GETPOFFSET(&dl.d_partitions[minor(bootsb.st_dev) % + getmaxpartitions()]); } else { if (errno != ENOTTY) err(1, "read disklabel: %s", dev); diff --git a/sys/arch/amd64/amd64/disksubr.c b/sys/arch/amd64/amd64/disksubr.c index 47e36a46727..63b91cd1244 100644 --- a/sys/arch/amd64/amd64/disksubr.c +++ b/sys/arch/amd64/amd64/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.38 2007/06/06 16:42:03 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.39 2007/06/06 17:15:11 deraadt Exp $ */ /* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */ /* @@ -76,7 +76,7 @@ readdisklabel(dev_t dev, void (*strat)(struct buf *), unsigned long extoff = 0; unsigned int fattest; struct buf *bp = NULL; - daddr_t part_blkno = DOSBBSECTOR; + daddr64_t part_blkno = DOSBBSECTOR; dev_t devno; char *msg = NULL; int dospartoff, cyl, i, ourpart = -1; diff --git a/sys/arch/amd64/amd64/machdep.c b/sys/arch/amd64/amd64/machdep.c index ac74697d2ea..f1aa836c45d 100644 --- a/sys/arch/amd64/amd64/machdep.c +++ b/sys/arch/amd64/amd64/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.58 2007/05/29 20:36:47 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.59 2007/06/06 17:15:11 deraadt Exp $ */ /* $NetBSD: machdep.c,v 1.3 2003/05/07 22:58:18 fvdl Exp $ */ /*- @@ -815,7 +815,7 @@ long dumplo = 0; /* blocks */ int cpu_dump(void) { - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); char buf[dbtob(1)]; kcore_seg_t *segp; cpu_kcore_hdr_t *cpuhdrp; @@ -908,8 +908,8 @@ dumpsys(void) { u_long totalbytesleft, bytes, i, n, memseg; u_long maddr; - daddr_t blkno; - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + daddr64_t blkno; + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); int error; /* Save registers. */ diff --git a/sys/arch/arm/arm/disksubr.c b/sys/arch/arm/arm/disksubr.c index 2e7b9b3024e..99d54ca7060 100644 --- a/sys/arch/arm/arm/disksubr.c +++ b/sys/arch/arm/arm/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.33 2007/06/06 16:42:04 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.34 2007/06/06 17:15:11 deraadt Exp $ */ /* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */ /* @@ -69,7 +69,7 @@ readdisklabel(dev_t dev, void (*strat)(struct buf *), unsigned long extoff = 0; unsigned int fattest; struct buf *bp = NULL; - daddr_t part_blkno = DOSBBSECTOR; + daddr64_t part_blkno = DOSBBSECTOR; char *msg = NULL; int dospartoff, cyl, i, ourpart = -1; int wander = 1, n = 0, loop = 0; diff --git a/sys/arch/arm/arm/stubs.c b/sys/arch/arm/arm/stubs.c index 7565e137d38..d1654a45bb7 100644 --- a/sys/arch/arm/arm/stubs.c +++ b/sys/arch/arm/arm/stubs.c @@ -1,4 +1,4 @@ -/* $OpenBSD: stubs.c,v 1.4 2007/05/29 20:36:47 deraadt Exp $ */ +/* $OpenBSD: stubs.c,v 1.5 2007/06/06 17:15:11 deraadt Exp $ */ /* $NetBSD: stubs.c,v 1.14 2003/07/15 00:24:42 lukem Exp $ */ /* @@ -124,7 +124,7 @@ void dumpsys() { const struct bdevsw *bdev; - daddr_t blkno; + daddr64_t blkno; int psize; int error; int addr; diff --git a/sys/arch/aviion/aviion/disksubr.c b/sys/arch/aviion/aviion/disksubr.c index 02f6b44b5d7..88fb632e334 100644 --- a/sys/arch/aviion/aviion/disksubr.c +++ b/sys/arch/aviion/aviion/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.24 2007/06/06 16:42:06 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.25 2007/06/06 17:15:11 deraadt Exp $ */ /* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */ /* @@ -69,7 +69,7 @@ readdisklabel(dev_t dev, void (*strat)(struct buf *), unsigned long extoff = 0; unsigned int fattest; struct buf *bp = NULL; - daddr_t part_blkno = DOSBBSECTOR; + daddr64_t part_blkno = DOSBBSECTOR; char *msg = NULL; int dospartoff, cyl, i, ourpart = -1; int wander = 1, n = 0, loop = 0; diff --git a/sys/arch/aviion/aviion/machdep.c b/sys/arch/aviion/aviion/machdep.c index 55ed1f2843d..4676e19f088 100644 --- a/sys/arch/aviion/aviion/machdep.c +++ b/sys/arch/aviion/aviion/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.9 2007/05/29 20:36:47 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.10 2007/06/06 17:15:11 deraadt Exp $ */ /* * Copyright (c) 1998, 1999, 2000, 2001 Steve Murphree, Jr. * Copyright (c) 1996 Nivas Madhur @@ -458,9 +458,9 @@ dumpsys() { int maj; int psize; - daddr_t blkno; /* current block to write */ + daddr64_t blkno; /* current block to write */ /* dump routine */ - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); int pg; /* page being dumped */ paddr_t maddr; /* PA being dumped */ int error; /* error code from (*dump)() */ diff --git a/sys/arch/hp300/dev/ct.c b/sys/arch/hp300/dev/ct.c index 26ed0837b65..b6577c31318 100644 --- a/sys/arch/hp300/dev/ct.c +++ b/sys/arch/hp300/dev/ct.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ct.c,v 1.17 2007/03/13 19:44:53 miod Exp $ */ +/* $OpenBSD: ct.c,v 1.18 2007/06/06 17:15:11 deraadt Exp $ */ /* $NetBSD: ct.c,v 1.21 1997/04/02 22:37:23 scottr Exp $ */ /* @@ -927,7 +927,7 @@ ctioctl(dev, cmd, data, flag, p) int ctdump(dev, blkno, va, size) dev_t dev; - daddr_t blkno; + daddr64_t blkno; caddr_t va; size_t size; { diff --git a/sys/arch/hp300/dev/hd.c b/sys/arch/hp300/dev/hd.c index 0113225da01..8e577a1ea97 100644 --- a/sys/arch/hp300/dev/hd.c +++ b/sys/arch/hp300/dev/hd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: hd.c,v 1.48 2007/06/05 00:38:14 deraadt Exp $ */ +/* $OpenBSD: hd.c,v 1.49 2007/06/06 17:15:11 deraadt Exp $ */ /* $NetBSD: rd.c,v 1.33 1997/07/10 18:14:08 kleink Exp $ */ /* @@ -1015,7 +1015,7 @@ hderror(unit) struct hd_softc *rs = hd_cd.cd_devs[unit]; struct hd_stat *sp; struct buf *bp; - daddr_t hwbn, pbn; + daddr64_t hwbn, pbn; if (hdstatus(rs)) { #ifdef DEBUG @@ -1214,7 +1214,7 @@ exit: return (error); } -int +daddr64_t hdsize(dev) dev_t dev; { @@ -1283,13 +1283,13 @@ static int hddoingadump; /* simple mutex */ int hddump(dev, blkno, va, size) dev_t dev; - daddr_t blkno; + daddr64_t blkno; caddr_t va; size_t size; { int sectorsize; /* size of a disk sector */ - int nsects; /* number of sectors in partition */ - int sectoff; /* sector offset of partition */ + daddr64_t nsects; /* number of sectors in partition */ + daddr64_t sectoff; /* sector offset of partition */ int totwrt; /* total number of sectors left to write */ int nwrt; /* current number of sectors to write */ int unit, part; diff --git a/sys/arch/hp300/dev/mt.c b/sys/arch/hp300/dev/mt.c index 1d2d00bffd1..39f35576a9b 100644 --- a/sys/arch/hp300/dev/mt.c +++ b/sys/arch/hp300/dev/mt.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mt.c,v 1.17 2006/01/20 23:27:25 miod Exp $ */ +/* $OpenBSD: mt.c,v 1.18 2007/06/06 17:15:11 deraadt Exp $ */ /* $NetBSD: mt.c,v 1.8 1997/03/31 07:37:29 scottr Exp $ */ /* @@ -988,7 +988,7 @@ mtioctl(dev, cmd, data, flag, p) int mtdump(dev, blkno, va, size) dev_t dev; - daddr_t blkno; + daddr64_t blkno; caddr_t va; size_t size; { diff --git a/sys/arch/hp300/hp300/machdep.c b/sys/arch/hp300/hp300/machdep.c index 0feb6c02e46..67f3611ad3d 100644 --- a/sys/arch/hp300/hp300/machdep.c +++ b/sys/arch/hp300/hp300/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.114 2007/05/29 20:36:47 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.115 2007/06/06 17:15:11 deraadt Exp $ */ /* $NetBSD: machdep.c,v 1.121 1999/03/26 23:41:29 mycroft Exp $ */ /* @@ -757,9 +757,9 @@ dumpconf(void) void dumpsys() { - daddr_t blkno; /* current block to write */ + daddr64_t blkno; /* current block to write */ /* dump routine */ - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); int pg; /* page being dumped */ paddr_t maddr; /* PA being dumped */ int error; /* error code from (*dump)() */ diff --git a/sys/arch/hppa/hppa/disksubr.c b/sys/arch/hppa/hppa/disksubr.c index 75d0aafe7d5..ef1b35c1c32 100644 --- a/sys/arch/hppa/hppa/disksubr.c +++ b/sys/arch/hppa/hppa/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.54 2007/06/06 16:42:06 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.55 2007/06/06 17:15:11 deraadt Exp $ */ /* * Copyright (c) 1999 Michael Shalayeff @@ -211,7 +211,7 @@ readdoslabel(struct buf *bp, void (*strat)(struct buf *), struct partition *pp; unsigned long extoff = 0; unsigned int fattest; - daddr_t part_blkno = DOSBBSECTOR; + daddr64_t part_blkno = DOSBBSECTOR; char *msg = NULL; int dospartoff, cyl, i, ourpart = -1; int wander = 1, n = 0, loop = 0; diff --git a/sys/arch/hppa/hppa/machdep.c b/sys/arch/hppa/hppa/machdep.c index 3548ac24a78..5cedb131f08 100644 --- a/sys/arch/hppa/hppa/machdep.c +++ b/sys/arch/hppa/hppa/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.157 2007/05/27 17:31:56 miod Exp $ */ +/* $OpenBSD: machdep.c,v 1.158 2007/06/06 17:15:11 deraadt Exp $ */ /* * Copyright (c) 1999-2003 Michael Shalayeff @@ -1047,10 +1047,10 @@ void dumpsys(void) { int psize, bytes, i, n; - register caddr_t maddr; - register daddr_t blkno; - register int (*dump)(dev_t, daddr_t, caddr_t, size_t); - register int error; + caddr_t maddr; + daddr64_t blkno; + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); + int error; /* Save registers savectx(&dumppcb); */ diff --git a/sys/arch/hppa64/hppa64/disksubr.c b/sys/arch/hppa64/hppa64/disksubr.c index 37f6050133c..6fd42238d63 100644 --- a/sys/arch/hppa64/hppa64/disksubr.c +++ b/sys/arch/hppa64/hppa64/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.37 2007/06/06 16:42:06 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.38 2007/06/06 17:15:12 deraadt Exp $ */ /* * Copyright (c) 1999 Michael Shalayeff @@ -211,7 +211,7 @@ readdoslabel(struct buf *bp, void (*strat)(struct buf *), struct partition *pp; unsigned long extoff = 0; unsigned int fattest; - daddr_t part_blkno = DOSBBSECTOR; + daddr64_t part_blkno = DOSBBSECTOR; char *msg = NULL; int dospartoff, cyl, i, ourpart = -1; int wander = 1, n = 0, loop = 0; diff --git a/sys/arch/hppa64/hppa64/machdep.c b/sys/arch/hppa64/hppa64/machdep.c index 70c7c882c33..1f5d478681b 100644 --- a/sys/arch/hppa64/hppa64/machdep.c +++ b/sys/arch/hppa64/hppa64/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.6 2007/05/27 17:31:56 miod Exp $ */ +/* $OpenBSD: machdep.c,v 1.7 2007/06/06 17:15:12 deraadt Exp $ */ /* * Copyright (c) 2005 Michael Shalayeff @@ -747,10 +747,10 @@ void dumpsys(void) { int psize, bytes, i, n; - register caddr_t maddr; - register daddr_t blkno; - register int (*dump)(dev_t, daddr_t, caddr_t, size_t); - register int error; + caddr_t maddr; + daddr64_t blkno; + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); + int error; /* Save registers savectx(&dumppcb); */ diff --git a/sys/arch/i386/i386/disksubr.c b/sys/arch/i386/i386/disksubr.c index ef955d27a98..206453d5da6 100644 --- a/sys/arch/i386/i386/disksubr.c +++ b/sys/arch/i386/i386/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.78 2007/06/06 16:42:06 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.79 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */ /* @@ -76,7 +76,7 @@ readdisklabel(dev_t dev, void (*strat)(struct buf *), unsigned long extoff = 0; unsigned int fattest; struct buf *bp = NULL; - daddr_t part_blkno = DOSBBSECTOR; + daddr64_t part_blkno = DOSBBSECTOR; dev_t devno; char *msg = NULL; int dospartoff, cyl, i, ourpart = -1; diff --git a/sys/arch/i386/i386/machdep.c b/sys/arch/i386/i386/machdep.c index 8d24c76d5a6..2db15f2b8fd 100644 --- a/sys/arch/i386/i386/machdep.c +++ b/sys/arch/i386/i386/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.400 2007/06/04 06:57:56 jsg Exp $ */ +/* $OpenBSD: machdep.c,v 1.401 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: machdep.c,v 1.214 1996/11/10 03:16:17 thorpej Exp $ */ /*- @@ -2493,7 +2493,7 @@ dumpconf(void) int cpu_dump() { - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); long buf[dbtob(1) / sizeof (long)]; kcore_seg_t *segp; @@ -2530,8 +2530,8 @@ dumpsys() { u_int i, j, npg; int maddr; - daddr_t blkno; - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + daddr64_t blkno; + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); int error; char *str; extern int msgbufmapped; @@ -2574,7 +2574,7 @@ dumpsys() maddr = ctob(dumpmem[i].start); blkno = dumplo + btodb(maddr) + 1; #if 0 - printf("(%d %ld %d) ", maddr, blkno, npg); + printf("(%d %lld %d) ", maddr, blkno, npg); #endif for (j = npg; j--; maddr += NBPG, blkno += btodb(NBPG)) { @@ -2583,7 +2583,7 @@ dumpsys() printf("%d ", (ctob(dumpsize) - maddr) / (1024 * 1024)); #if 0 - printf("(%x %d) ", maddr, blkno); + printf("(%x %lld) ", maddr, blkno); #endif pmap_enter(pmap_kernel(), dumpspace, maddr, VM_PROT_READ, PMAP_WIRED); diff --git a/sys/arch/landisk/landisk/disksubr.c b/sys/arch/landisk/landisk/disksubr.c index 74f6161b793..4306b2d09b0 100644 --- a/sys/arch/landisk/landisk/disksubr.c +++ b/sys/arch/landisk/landisk/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.21 2007/06/06 16:42:06 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.22 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */ /* @@ -69,7 +69,7 @@ readdisklabel(dev_t dev, void (*strat)(struct buf *), unsigned long extoff = 0; unsigned int fattest; struct buf *bp = NULL; - daddr_t part_blkno = DOSBBSECTOR; + daddr64_t part_blkno = DOSBBSECTOR; char *msg = NULL; int dospartoff, cyl, i, ourpart = -1; int wander = 1, n = 0, loop = 0; diff --git a/sys/arch/landisk/landisk/machdep.c b/sys/arch/landisk/landisk/machdep.c index ed7e19d7ed7..b16721fce55 100644 --- a/sys/arch/landisk/landisk/machdep.c +++ b/sys/arch/landisk/landisk/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.12 2007/04/29 18:18:03 miod Exp $ */ +/* $OpenBSD: machdep.c,v 1.13 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: machdep.c,v 1.1 2006/09/01 21:26:18 uwe Exp $ */ /*- @@ -385,7 +385,7 @@ InitializeBsc(void) * Dump the machine-dependent dump header. */ u_int -cpu_dump(int (*dump)(dev_t, daddr_t, caddr_t, size_t), daddr_t *blknop) +cpu_dump(int (*dump)(dev_t, daddr64_t, caddr_t, size_t), daddr64_t *blknop) { extern cpu_kcore_hdr_t cpu_kcore_hdr; char buf[dbtob(1)]; diff --git a/sys/arch/luna88k/luna88k/machdep.c b/sys/arch/luna88k/luna88k/machdep.c index 66f0ecfdf75..0a40e973bd7 100644 --- a/sys/arch/luna88k/luna88k/machdep.c +++ b/sys/arch/luna88k/luna88k/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.43 2007/05/29 20:36:47 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.44 2007/06/06 17:15:12 deraadt Exp $ */ /* * Copyright (c) 1998, 1999, 2000, 2001 Steve Murphree, Jr. * Copyright (c) 1996 Nivas Madhur @@ -649,9 +649,9 @@ dumpsys() { int maj; int psize; - daddr_t blkno; /* current block to write */ + daddr64_t blkno; /* current block to write */ /* dump routine */ - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); int pg; /* page being dumped */ paddr_t maddr; /* PA being dumped */ int error; /* error code from (*dump)() */ diff --git a/sys/arch/mac68k/mac68k/machdep.c b/sys/arch/mac68k/mac68k/machdep.c index 5c9ddc062cb..a05ea981947 100644 --- a/sys/arch/mac68k/mac68k/machdep.c +++ b/sys/arch/mac68k/mac68k/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.140 2007/05/29 20:36:47 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.141 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: machdep.c,v 1.207 1998/07/08 04:39:34 thorpej Exp $ */ /* @@ -214,7 +214,7 @@ u_long get_physical(u_int, u_long *); caddr_t allocsys(caddr_t); void initcpu(void); int cpu_dumpsize(void); -int cpu_dump(int (*)(dev_t, daddr_t, caddr_t, size_t), daddr_t *); +int cpu_dump(int (*)(dev_t, daddr64_t, caddr_t, size_t), daddr64_t *); void cpu_init_kcore_hdr(void); int fpu_probe(void); @@ -654,8 +654,8 @@ cpu_dumpsize() */ int cpu_dump(dump, blknop) - int (*dump)(dev_t, daddr_t, caddr_t, size_t); - daddr_t *blknop; + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); + daddr64_t *blknop; { int buf[dbtob(1) / sizeof(int)]; cpu_kcore_hdr_t *chdr; @@ -723,9 +723,9 @@ void dumpsys() { cpu_kcore_hdr_t *h = &cpu_kcore_hdr; - daddr_t blkno; /* current block to write */ + daddr64_t blkno; /* current block to write */ /* dump routine */ - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); int pg; /* page being dumped */ vaddr_t maddr; /* PA being dumped */ int seg; /* RAM segment being dumped */ diff --git a/sys/arch/macppc/macppc/disksubr.c b/sys/arch/macppc/macppc/disksubr.c index c4792457d20..fccd1135086 100644 --- a/sys/arch/macppc/macppc/disksubr.c +++ b/sys/arch/macppc/macppc/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.43 2007/06/06 16:42:06 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.44 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */ /* @@ -72,7 +72,7 @@ readdisklabel(dev_t dev, void (*strat)(struct buf *), unsigned long extoff = 0; unsigned int fattest; struct buf *bp = NULL; - daddr_t part_blkno = DOSBBSECTOR; + daddr64_t part_blkno = DOSBBSECTOR; char *msg = NULL; char *s; int dospartoff, cyl, i, ourpart = -1; diff --git a/sys/arch/macppc/macppc/machdep.c b/sys/arch/macppc/macppc/machdep.c index a287c034ca5..ba5be68cfda 100644 --- a/sys/arch/macppc/macppc/machdep.c +++ b/sys/arch/macppc/macppc/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.92 2007/05/29 20:36:47 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.93 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: machdep.c,v 1.4 1996/10/16 19:33:11 ws Exp $ */ /* @@ -779,7 +779,7 @@ int cpu_dump(void); int cpu_dump() { - int (*dump) (dev_t, daddr_t, caddr_t, size_t); + int (*dump) (dev_t, daddr64_t, caddr_t, size_t); long buf[dbtob(1) / sizeof (long)]; kcore_seg_t *segp; @@ -802,8 +802,8 @@ dumpsys() #if 0 u_int npg; u_int i, j; - daddr_t blkno; - int (*dump) (dev_t, daddr_t, caddr_t, size_t); + daddr64_t blkno; + int (*dump) (dev_t, daddr64_t, caddr_t, size_t); char *str; int maddr; extern int msgbufmapped; diff --git a/sys/arch/macppc/stand/ofdev.c b/sys/arch/macppc/stand/ofdev.c index 6ab2517727a..6130b465c17 100644 --- a/sys/arch/macppc/stand/ofdev.c +++ b/sys/arch/macppc/stand/ofdev.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ofdev.c,v 1.11 2007/06/02 15:28:09 deraadt Exp $ */ +/* $OpenBSD: ofdev.c,v 1.12 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: ofdev.c,v 1.1 1997/04/16 20:29:20 thorpej Exp $ */ /* @@ -98,7 +98,7 @@ filename(char *str, char *ppart) } static int -strategy(void *devdata, int rw, daddr_t blk, size_t size, void *buf, +strategy(void *devdata, int rw, daddr64_t blk, size_t size, void *buf, size_t *rsize) { struct of_dev *dev = devdata; diff --git a/sys/arch/mips64/mips64/disksubr.c b/sys/arch/mips64/mips64/disksubr.c index dd82015753a..80cd0166b5a 100644 --- a/sys/arch/mips64/mips64/disksubr.c +++ b/sys/arch/mips64/mips64/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.43 2007/06/06 16:42:06 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.44 2007/06/06 17:15:12 deraadt Exp $ */ /* * Copyright (c) 1999 Michael Shalayeff @@ -221,7 +221,7 @@ readdoslabel(bp, strat, lp, osdep, partoffp, cylp, spoofonly) struct partition *pp; unsigned long extoff = 0; unsigned int fattest; - daddr_t part_blkno = DOSBBSECTOR; + daddr64_t part_blkno = DOSBBSECTOR; char *msg = NULL; int dospartoff, cyl, i, ourpart = -1; int wander = 1, n = 0, loop = 0; diff --git a/sys/arch/mvme68k/mvme68k/machdep.c b/sys/arch/mvme68k/mvme68k/machdep.c index 678fcf0b11c..335be2eda67 100644 --- a/sys/arch/mvme68k/mvme68k/machdep.c +++ b/sys/arch/mvme68k/mvme68k/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.105 2007/05/29 20:36:47 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.106 2007/06/06 17:15:12 deraadt Exp $ */ /* * Copyright (c) 1995 Theo de Raadt @@ -603,9 +603,9 @@ dumpsys() { int maj; int psize; - daddr_t blkno; /* current block to write */ + daddr64_t blkno; /* current block to write */ /* dump routine */ - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); int pg; /* page being dumped */ paddr_t maddr; /* PA being dumped */ int error; /* error code from (*dump)() */ diff --git a/sys/arch/mvme88k/mvme88k/machdep.c b/sys/arch/mvme88k/mvme88k/machdep.c index 0b596a9f5ab..c743056aafa 100644 --- a/sys/arch/mvme88k/mvme88k/machdep.c +++ b/sys/arch/mvme88k/mvme88k/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.191 2007/05/29 20:36:48 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.192 2007/06/06 17:15:12 deraadt Exp $ */ /* * Copyright (c) 1998, 1999, 2000, 2001 Steve Murphree, Jr. * Copyright (c) 1996 Nivas Madhur @@ -572,9 +572,9 @@ dumpsys() { int maj; int psize; - daddr_t blkno; /* current block to write */ + daddr64_t blkno; /* current block to write */ /* dump routine */ - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); int pg; /* page being dumped */ paddr_t maddr; /* PA being dumped */ int error; /* error code from (*dump)() */ diff --git a/sys/arch/mvmeppc/mvmeppc/disksubr.c b/sys/arch/mvmeppc/mvmeppc/disksubr.c index bef2fa99d68..9b8f5736100 100644 --- a/sys/arch/mvmeppc/mvmeppc/disksubr.c +++ b/sys/arch/mvmeppc/mvmeppc/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.39 2007/06/06 16:42:06 deraadt Exp $ */ +/* $OpenBSD: disksubr.c,v 1.40 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */ /* @@ -72,7 +72,7 @@ readdisklabel(dev_t dev, void (*strat)(struct buf *), unsigned long extoff = 0; unsigned int fattest; struct buf *bp = NULL; - daddr_t part_blkno = DOSBBSECTOR; + daddr64_t part_blkno = DOSBBSECTOR; char *msg = NULL; int dospartoff, cyl, i, ourpart = -1; int wander = 1, n = 0, loop = 0; diff --git a/sys/arch/sh/include/cpu.h b/sys/arch/sh/include/cpu.h index 7d2fa1a539e..b29d7247ce0 100644 --- a/sys/arch/sh/include/cpu.h +++ b/sys/arch/sh/include/cpu.h @@ -1,4 +1,4 @@ -/* $OpenBSD: cpu.h,v 1.9 2007/05/14 07:05:49 art Exp $ */ +/* $OpenBSD: cpu.h,v 1.10 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: cpu.h,v 1.41 2006/01/21 04:24:12 uwe Exp $ */ /*- @@ -210,7 +210,7 @@ void savectx(struct pcb *); struct fpreg; void fpu_save(struct fpreg *); void fpu_restore(struct fpreg *); -u_int cpu_dump(int (*)(dev_t, daddr_t, caddr_t, size_t), daddr_t *); +u_int cpu_dump(int (*)(dev_t, daddr64_t, caddr_t, size_t), daddr64_t *); u_int cpu_dumpsize(void); void dumpconf(void); void dumpsys(void); diff --git a/sys/arch/sh/sh/sh_machdep.c b/sys/arch/sh/sh/sh_machdep.c index fbb17be337b..d81017ac0f1 100644 --- a/sys/arch/sh/sh/sh_machdep.c +++ b/sys/arch/sh/sh/sh_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sh_machdep.c,v 1.15 2007/05/29 20:36:48 deraadt Exp $ */ +/* $OpenBSD: sh_machdep.c,v 1.16 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: sh3_machdep.c,v 1.59 2006/03/04 01:13:36 uwe Exp $ */ /* @@ -403,8 +403,8 @@ void dumpsys() { cpu_kcore_hdr_t *h = &cpu_kcore_hdr; - daddr_t blkno; - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + daddr64_t blkno; + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); u_int page = 0; paddr_t dumppa; u_int seg; diff --git a/sys/arch/sparc/dev/fd.c b/sys/arch/sparc/dev/fd.c index 39205876b29..75abaf79f40 100644 --- a/sys/arch/sparc/dev/fd.c +++ b/sys/arch/sparc/dev/fd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fd.c,v 1.50 2007/06/05 00:38:18 deraadt Exp $ */ +/* $OpenBSD: fd.c,v 1.51 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: fd.c,v 1.51 1997/05/24 20:16:19 pk Exp $ */ /*- @@ -208,7 +208,7 @@ struct fd_softc { struct fd_type *sc_deftype; /* default type descriptor */ struct fd_type *sc_type; /* current type descriptor */ - daddr_t sc_blkno; /* starting block number */ + daddr64_t sc_blkno; /* starting block number */ int sc_bcount; /* byte count left */ int sc_skip; /* bytes already transferred */ int sc_nblks; /* number of blocks currently transferring */ @@ -1750,7 +1750,7 @@ fdsize(dev) int fddump(dev, blkno, va, size) dev_t dev; - daddr_t blkno; + daddr64_t blkno; caddr_t va; size_t size; { diff --git a/sys/arch/sparc/dev/presto.c b/sys/arch/sparc/dev/presto.c index 8fa71113b39..ddbd32f56e4 100644 --- a/sys/arch/sparc/dev/presto.c +++ b/sys/arch/sparc/dev/presto.c @@ -1,4 +1,4 @@ -/* $OpenBSD: presto.c,v 1.9 2007/06/05 00:38:18 deraadt Exp $ */ +/* $OpenBSD: presto.c,v 1.10 2007/06/06 17:15:12 deraadt Exp $ */ /* * Copyright (c) 2003, Miodrag Vallat. * All rights reserved. @@ -174,7 +174,7 @@ presto_attach(struct device *parent, struct device *self, void *args) */ int -prestodump(dev_t dev, daddr_t blkno, caddr_t va, size_t size) +prestodump(dev_t dev, daddr64_t blkno, caddr_t va, size_t size) { /* * A dump to nvram is theoretically possible, but its size is diff --git a/sys/arch/sparc/dev/xd.c b/sys/arch/sparc/dev/xd.c index 41683456a49..14e9c94d38f 100644 --- a/sys/arch/sparc/dev/xd.c +++ b/sys/arch/sparc/dev/xd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: xd.c,v 1.36 2007/06/05 00:38:18 deraadt Exp $ */ +/* $OpenBSD: xd.c,v 1.37 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: xd.c,v 1.37 1997/07/29 09:58:16 fair Exp $ */ /* @@ -780,7 +780,7 @@ xdclose(dev, flag, fmt, p) int xddump(dev, blkno, va, size) dev_t dev; - daddr_t blkno; + daddr64_t blkno; caddr_t va; size_t size; { @@ -1410,8 +1410,9 @@ xdc_startbuf(xdcsc, xdsc, bp) } partno = DISKPART(bp->b_dev); #ifdef XDC_DEBUG - printf("xdc_startbuf: %s%c: %s block %d\n", xdsc->sc_dev.dv_xname, - 'a' + partno, (bp->b_flags & B_READ) ? "read" : "write", bp->b_blkno); + 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); 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 f860780ff4c..397193cc322 100644 --- a/sys/arch/sparc/dev/xy.c +++ b/sys/arch/sparc/dev/xy.c @@ -1,4 +1,4 @@ -/* $OpenBSD: xy.c,v 1.32 2007/06/05 00:38:18 deraadt Exp $ */ +/* $OpenBSD: xy.c,v 1.33 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: xy.c,v 1.26 1997/07/19 21:43:56 pk Exp $ */ /* @@ -741,7 +741,7 @@ xyclose(dev, flag, fmt, p) int xydump(dev, blkno, va, size) dev_t dev; - daddr_t blkno; + daddr64_t blkno; caddr_t va; size_t size; { @@ -1255,7 +1255,7 @@ xyc_startbuf(xycsc, xysc, bp) int partno; struct xy_iorq *iorq; struct xy_iopb *iopb; - u_long block; + daddr64_t block; caddr_t dbuf; iorq = xysc->xyrq; @@ -1268,8 +1268,9 @@ xyc_startbuf(xycsc, xysc, bp) partno = DISKPART(bp->b_dev); #ifdef XYC_DEBUG - printf("xyc_startbuf: %s%c: %s block %d\n", xysc->sc_dev.dv_xname, - 'a' + partno, (bp->b_flags & B_READ) ? "read" : "write", bp->b_blkno); + 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); printf("xyc_startbuf: b_bcount %d, b_data 0x%x\n", bp->b_bcount, bp->b_data); #endif diff --git a/sys/arch/sparc/include/pmap.h b/sys/arch/sparc/include/pmap.h index b6586168a1c..8e0e2a94973 100644 --- a/sys/arch/sparc/include/pmap.h +++ b/sys/arch/sparc/include/pmap.h @@ -1,4 +1,4 @@ -/* $OpenBSD: pmap.h,v 1.40 2005/04/17 18:47:48 miod Exp $ */ +/* $OpenBSD: pmap.h,v 1.41 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: pmap.h,v 1.30 1997/08/04 20:00:47 pk Exp $ */ /* @@ -256,7 +256,7 @@ extern struct pmap kernel_pmap_store; #define PMAP_IOENC(io) (CPU_ISSUN4M ? PMAP_IOENC_SRMMU(io) : PMAP_IOENC_4(io)) int pmap_dumpsize(void); -int pmap_dumpmmu(int (*)(dev_t, daddr_t, caddr_t, size_t), daddr_t); +int pmap_dumpmmu(int (*)(dev_t, daddr64_t, caddr_t, size_t), daddr64_t); #define pmap_kernel() (&kernel_pmap_store) #define pmap_resident_count(pmap) pmap_count_ptes(pmap) diff --git a/sys/arch/sparc/sparc/machdep.c b/sys/arch/sparc/sparc/machdep.c index 72a2514b88d..8cc6fe62ce2 100644 --- a/sys/arch/sparc/sparc/machdep.c +++ b/sys/arch/sparc/sparc/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.112 2007/05/29 20:36:48 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.113 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: machdep.c,v 1.85 1997/09/12 08:55:02 pk Exp $ */ /* @@ -774,8 +774,8 @@ void dumpsys() { int psize; - daddr_t blkno; - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + daddr64_t blkno; + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); int error = 0; struct memarr *mp; int nmem; diff --git a/sys/arch/sparc/sparc/pmap.c b/sys/arch/sparc/sparc/pmap.c index 594b9784db7..5eceee1cffd 100644 --- a/sys/arch/sparc/sparc/pmap.c +++ b/sys/arch/sparc/sparc/pmap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pmap.c,v 1.144 2006/06/26 22:23:03 miod Exp $ */ +/* $OpenBSD: pmap.c,v 1.145 2007/06/06 17:15:12 deraadt Exp $ */ /* $NetBSD: pmap.c,v 1.118 1998/05/19 19:00:18 thorpej Exp $ */ /* @@ -6385,8 +6385,8 @@ pmap_dumpsize() */ int pmap_dumpmmu(dump, blkno) - daddr_t blkno; - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + daddr64_t blkno; + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); { kcore_seg_t *ksegp; cpu_kcore_hdr_t *kcpup; diff --git a/sys/arch/sparc64/dev/fd.c b/sys/arch/sparc64/dev/fd.c index a3c4990fcc6..aa1bf1a195d 100644 --- a/sys/arch/sparc64/dev/fd.c +++ b/sys/arch/sparc64/dev/fd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: fd.c,v 1.13 2007/06/05 00:38:19 deraadt Exp $ */ +/* $OpenBSD: fd.c,v 1.14 2007/06/06 17:15:13 deraadt Exp $ */ /* $NetBSD: fd.c,v 1.112 2003/08/07 16:29:35 agc Exp $ */ /*- @@ -257,7 +257,7 @@ struct fd_softc { struct timeout sc_motoron_to; struct timeout sc_motoroff_to; - daddr_t sc_blkno; /* starting block number */ + daddr64_t sc_blkno; /* starting block number */ int sc_bcount; /* byte count left */ int sc_skip; /* bytes already transferred */ int sc_nblks; /* number of blocks currently transferring */ @@ -743,9 +743,9 @@ fdstrategy(bp) #ifdef FD_DEBUG if (fdc_debug > 1) - 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); + 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); #endif /* Queue transfer on drive, activate drive and controller if idle. */ @@ -1446,14 +1446,19 @@ loop: head = sec / type->sectrac; sec -= head * type->sectrac; #ifdef DIAGNOSTIC - {int block; - block = (fd->sc_cylin * type->heads + head) * type->sectrac + sec; - if (block != fd->sc_blkno) { - printf("fdcintr: block %d != blkno %d\n", block, (int)fd->sc_blkno); + { + daddr64_t block; + + 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); #if defined(FD_DEBUG) && defined(DDB) - Debugger(); + Debugger(); #endif - }} + } + } #endif read = bp->b_flags & B_READ; @@ -1580,7 +1585,7 @@ loop: bp->b_flags & B_READ ? "read failed" : "write failed"); printf("blkno %lld nblks %d nstat %d tc %d\n", - (long long)fd->sc_blkno, fd->sc_nblks, + fd->sc_blkno, fd->sc_nblks, fdc->sc_nstat, fdc->sc_tc); } #endif @@ -1802,7 +1807,7 @@ fdsize(dev) int fddump(dev, blkno, va, size) dev_t dev; - daddr_t blkno; + daddr64_t blkno; caddr_t va; size_t size; { diff --git a/sys/arch/sparc64/include/pmap.h b/sys/arch/sparc64/include/pmap.h index 95a39e51792..c1793a939b3 100644 --- a/sys/arch/sparc64/include/pmap.h +++ b/sys/arch/sparc64/include/pmap.h @@ -173,7 +173,7 @@ void pmap_bootstrap(u_long kernelstart, u_long kernelend, u_int numctx); /* SPARC specific? */ void pmap_redzone(void); int pmap_dumpsize(void); -int pmap_dumpmmu(int (*)(dev_t, daddr_t, caddr_t, size_t), daddr_t); +int pmap_dumpmmu(int (*)(dev_t, daddr64_t, caddr_t, size_t), daddr64_t); int pmap_pa_exists(paddr_t); struct proc; void switchexit(struct proc *); diff --git a/sys/arch/sparc64/sparc64/machdep.c b/sys/arch/sparc64/sparc64/machdep.c index 0962d15882a..8eb3ef580aa 100644 --- a/sys/arch/sparc64/sparc64/machdep.c +++ b/sys/arch/sparc64/sparc64/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.90 2007/05/29 20:36:48 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.91 2007/06/06 17:15:13 deraadt Exp $ */ /* $NetBSD: machdep.c,v 1.108 2001/07/24 19:30:14 eeh Exp $ */ /*- @@ -822,8 +822,8 @@ void dumpsys() { int psize; - daddr_t blkno; - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + daddr64_t blkno; + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); int error = 0; struct mem_region *mp; extern struct mem_region *mem; @@ -864,7 +864,7 @@ dumpsys() error = pmap_dumpmmu(dump, blkno); blkno += pmap_dumpsize(); -printf("starting dump, blkno %d\n", blkno); +printf("starting dump, blkno %lld\n", blkno); for (mp = mem; mp->size; mp++) { u_int64_t i = 0, n; paddr_t maddr = mp->start; diff --git a/sys/arch/sparc64/sparc64/pmap.c b/sys/arch/sparc64/sparc64/pmap.c index 9c7f49bdd3e..f014c7fe07b 100644 --- a/sys/arch/sparc64/sparc64/pmap.c +++ b/sys/arch/sparc64/sparc64/pmap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pmap.c,v 1.41 2007/05/20 15:11:27 miod Exp $ */ +/* $OpenBSD: pmap.c,v 1.42 2007/06/06 17:15:13 deraadt Exp $ */ /* $NetBSD: pmap.c,v 1.107 2001/08/31 16:47:41 eeh Exp $ */ #undef NO_VCACHE /* Don't forget the locked TLB in dostart */ /* @@ -2294,8 +2294,8 @@ pmap_dumpsize() */ int pmap_dumpmmu(dump, blkno) - register daddr_t blkno; - register int (*dump)(dev_t, daddr_t, caddr_t, size_t); + register daddr64_t blkno; + register int (*dump)(dev_t, daddr64_t, caddr_t, size_t); { kcore_seg_t *kseg; cpu_kcore_hdr_t *kcpu; diff --git a/sys/arch/vax/mscp/mscp_disk.c b/sys/arch/vax/mscp/mscp_disk.c index e7c293a3ccc..454f35be0c0 100644 --- a/sys/arch/vax/mscp/mscp_disk.c +++ b/sys/arch/vax/mscp/mscp_disk.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mscp_disk.c,v 1.20 2007/06/05 00:38:19 deraadt Exp $ */ +/* $OpenBSD: mscp_disk.c,v 1.21 2007/06/06 17:15:13 deraadt Exp $ */ /* $NetBSD: mscp_disk.c,v 1.30 2001/11/13 07:38:28 lukem Exp $ */ /* * Copyright (c) 1996 Ludd, University of Lule}, Sweden. @@ -110,7 +110,7 @@ void rastrategy(struct buf *); int raread(dev_t, struct uio *); int rawrite(dev_t, struct uio *); int raioctl(dev_t, int, caddr_t, int, struct proc *); -int radump(dev_t, daddr_t, caddr_t, size_t); +int radump(dev_t, daddr64_t, caddr_t, size_t); int rasize(dev_t); int ra_putonline(struct ra_softc *); @@ -418,7 +418,7 @@ raioctl(dev, cmd, data, flag, p) int radump(dev, blkno, va, size) dev_t dev; - daddr_t blkno; + daddr64_t blkno; caddr_t va; size_t size; { @@ -459,7 +459,7 @@ void rxstrategy(struct buf *); int rxread(dev_t, struct uio *); int rxwrite(dev_t, struct uio *); int rxioctl(dev_t, int, caddr_t, int, struct proc *); -int rxdump(dev_t, daddr_t, caddr_t, size_t); +int rxdump(dev_t, daddr64_t, caddr_t, size_t); int rxsize(dev_t); struct cfattach rx_ca = { @@ -730,7 +730,7 @@ rxioctl(dev, cmd, data, flag, p) int rxdump(dev, blkno, va, size) dev_t dev; - daddr_t blkno; + daddr64_t blkno; caddr_t va; size_t size; { @@ -828,7 +828,7 @@ rronline(usc, mp) rx->ra_state = DK_OPEN; dl = rx->ra_disk.dk_label; - DL_SETDSIZE(dl, (daddr_t)mp->mscp_onle.onle_unitsize); + DL_SETDSIZE(dl, mp->mscp_onle.onle_unitsize); if (dl->d_secpercyl) { dl->d_ncylinders = DL_GETDSIZE(dl) / dl->d_secpercyl; diff --git a/sys/arch/vax/mscp/mscp_tape.c b/sys/arch/vax/mscp/mscp_tape.c index 5eb952fa3e8..d192564076b 100644 --- a/sys/arch/vax/mscp/mscp_tape.c +++ b/sys/arch/vax/mscp/mscp_tape.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mscp_tape.c,v 1.9 2006/03/15 20:04:36 miod Exp $ */ +/* $OpenBSD: mscp_tape.c,v 1.10 2007/06/06 17:15:13 deraadt Exp $ */ /* $NetBSD: mscp_tape.c,v 1.16 2001/11/13 07:38:28 lukem Exp $ */ /* * Copyright (c) 1996 Ludd, University of Lule}, Sweden. @@ -91,7 +91,7 @@ void mtstrategy(struct buf *); int mtread(dev_t, struct uio *); int mtwrite(dev_t, struct uio *); int mtioctl(dev_t, int, caddr_t, int, struct proc *); -int mtdump(dev_t, daddr_t, caddr_t, size_t); +int mtdump(dev_t, daddr64_t, caddr_t, size_t); int mtcmd(struct mt_softc *, int, int, int); void mtcmddone(struct device *, struct mscp *); int mt_putonline(struct mt_softc *); @@ -471,7 +471,7 @@ mtioctl(dev, cmd, data, flag, p) int mtdump(dev, blkno, va, size) dev_t dev; - daddr_t blkno; + daddr64_t blkno; caddr_t va; size_t size; { diff --git a/sys/arch/vax/uba/ts.c b/sys/arch/vax/uba/ts.c index a58bfa56808..48cb15a7845 100644 --- a/sys/arch/vax/uba/ts.c +++ b/sys/arch/vax/uba/ts.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ts.c,v 1.16 2004/01/29 21:34:17 deraadt Exp $ */ +/* $OpenBSD: ts.c,v 1.17 2007/06/06 17:15:13 deraadt Exp $ */ /* $NetBSD: ts.c,v 1.11 1997/01/11 11:34:43 ragge Exp $ */ /*- @@ -193,7 +193,7 @@ int tsclose(dev_t, int, int, struct proc *); int tsioctl(dev_t, u_long, caddr_t, int, struct proc *); int tsread(dev_t, struct uio *); int tswrite(dev_t, struct uio *); -int tsdump(dev_t, daddr_t, caddr_t, size_t); +int tsdump(dev_t, daddr64_t, caddr_t, size_t); struct cfdriver ts_cd = { NULL, "ts", DV_DULL @@ -1342,7 +1342,7 @@ tswrite (dev, uio) int tsdump(dev, blkno, va, size) dev_t dev; - daddr_t blkno; + daddr64_t blkno; caddr_t va; size_t size; { diff --git a/sys/arch/vax/vax/ctu.c b/sys/arch/vax/vax/ctu.c index 0e1cd8ee015..e7756a79fd0 100644 --- a/sys/arch/vax/vax/ctu.c +++ b/sys/arch/vax/vax/ctu.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ctu.c,v 1.9 2006/01/20 23:27:26 miod Exp $ */ +/* $OpenBSD: ctu.c,v 1.10 2007/06/06 17:15:13 deraadt Exp $ */ /* $NetBSD: ctu.c,v 1.10 2000/03/23 06:46:44 thorpej Exp $ */ /* * Copyright (c) 1996 Ludd, University of Lule}, Sweden. @@ -98,7 +98,7 @@ int ctuopen(dev_t, int, int, struct proc *); int ctuclose(dev_t, int, int, struct proc *); void ctustrategy(struct buf *); int ctuioctl(dev_t, u_long, caddr_t, int, struct proc *); -int ctudump(dev_t, daddr_t, caddr_t, size_t); +int ctudump(dev_t, daddr64_t, caddr_t, size_t); static struct callout ctu_watch_ch = CALLOUT_INITIALIZER; @@ -240,7 +240,7 @@ ctuioctl(dev, cmd, data, fflag, p) int ctudump(dev, blkno, va, size) dev_t dev; - daddr_t blkno; + daddr64_t blkno; caddr_t va; size_t size; { diff --git a/sys/arch/vax/vax/machdep.c b/sys/arch/vax/vax/machdep.c index c2ae7cfc0e0..7b8fa575f70 100644 --- a/sys/arch/vax/vax/machdep.c +++ b/sys/arch/vax/vax/machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: machdep.c,v 1.91 2007/05/29 20:36:48 deraadt Exp $ */ +/* $OpenBSD: machdep.c,v 1.92 2007/06/06 17:15:13 deraadt Exp $ */ /* $NetBSD: machdep.c,v 1.108 2000/09/13 15:00:23 thorpej Exp $ */ /* @@ -595,8 +595,8 @@ void dumpsys() { int maj, psize, pg; - daddr_t blkno; - int (*dump)(dev_t, daddr_t, caddr_t, size_t); + daddr64_t blkno; + int (*dump)(dev_t, daddr64_t, caddr_t, size_t); paddr_t maddr; int error; kcore_seg_t *kseg_p; diff --git a/sys/arch/vax/vsa/hdc9224.c b/sys/arch/vax/vsa/hdc9224.c index 0402691fdd9..94696d9be4a 100644 --- a/sys/arch/vax/vsa/hdc9224.c +++ b/sys/arch/vax/vsa/hdc9224.c @@ -1,4 +1,4 @@ -/* $OpenBSD: hdc9224.c,v 1.15 2007/06/05 00:38:19 deraadt Exp $ */ +/* $OpenBSD: hdc9224.c,v 1.16 2007/06/06 17:15:13 deraadt Exp $ */ /* $NetBSD: hdc9224.c,v 1.16 2001/07/26 15:05:09 wiz Exp $ */ /* * Copyright (c) 1996 Ludd, University of Lule}, Sweden. @@ -438,7 +438,7 @@ hdstrategy(struct buf *bp) struct hdcsoftc *sc; struct disklabel *lp; int unit, s; - daddr_t bn; + daddr64_t bn; unit = DISKUNIT(bp->b_dev); if (unit > hd_cd.cd_ndevs || (hd = hd_cd.cd_devs[unit]) == NULL) { @@ -767,7 +767,7 @@ hdwrite(dev_t dev, struct uio *uio, int flag) * */ int -hddump(dev_t dev, daddr_t daddr, caddr_t addr, size_t size) +hddump(dev_t dev, daddr64_t daddr, caddr_t addr, size_t size) { return 0; } |