summaryrefslogtreecommitdiff
path: root/sys/arch/alpha
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2007-06-06 17:15:15 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2007-06-06 17:15:15 +0000
commit64b0758a0244e515108eec4f2cd5d05a5939ebf1 (patch)
treee5e991586e626374ede95d07956bcaf6a47372be /sys/arch/alpha
parenta0f03208acbc7a85466c7cf68058959c1bbe9668 (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/alpha')
-rw-r--r--sys/arch/alpha/alpha/disksubr.c4
-rw-r--r--sys/arch/alpha/alpha/machdep.c8
-rw-r--r--sys/arch/alpha/stand/installboot.c8
3 files changed, 10 insertions, 10 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);