summaryrefslogtreecommitdiff
path: root/sys/arch/amd64/amd64/disksubr.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/arch/amd64/amd64/disksubr.c')
-rw-r--r--sys/arch/amd64/amd64/disksubr.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/arch/amd64/amd64/disksubr.c b/sys/arch/amd64/amd64/disksubr.c
index d9f3f22fa51..eed94b62ddb 100644
--- a/sys/arch/amd64/amd64/disksubr.c
+++ b/sys/arch/amd64/amd64/disksubr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disksubr.c,v 1.46 2007/06/12 20:57:42 deraadt Exp $ */
+/* $OpenBSD: disksubr.c,v 1.47 2007/06/14 03:29:34 deraadt Exp $ */
/* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */
/*
@@ -96,9 +96,9 @@ readdisklabel(dev_t dev, void (*strat)(struct buf *),
DL_SETPSIZE(&lp->d_partitions[i], 0);
DL_SETPOFFSET(&lp->d_partitions[i], 0);
}
- if (DL_GETPSIZE(&lp->d_partitions[i]) == 0)
- DL_SETPSIZE(&lp->d_partitions[i], DL_GETDSIZE(lp));
- DL_SETPOFFSET(&lp->d_partitions[i], 0);
+ if (DL_GETPSIZE(&lp->d_partitions[RAW_PART]) == 0)
+ DL_SETPSIZE(&lp->d_partitions[RAW_PART], DL_GETDSIZE(lp));
+ DL_SETPOFFSET(&lp->d_partitions[RAW_PART], 0);
/* Look for any BIOS geometry information we should honour. */
devno = chrtoblk(dev);