diff options
author | Kenneth R Westerback <krw@cvs.openbsd.org> | 2006-09-24 22:43:01 +0000 |
---|---|---|
committer | Kenneth R Westerback <krw@cvs.openbsd.org> | 2006-09-24 22:43:01 +0000 |
commit | 71152e2201043de893452b0f5bafac7acc8bb5a4 (patch) | |
tree | ba66c8e270572900ce4d0d31b72acf0944033d96 /sys/arch/mac68k | |
parent | 9235ce80e50d27b570a55af0deecd2d72b83029f (diff) |
Bring hp300, mac68k and mvme68k disklabel initialization code into
line with all other archs by initializing partitions up to RAWPART the
same way. Should be no functional change.
ok martin@ miod@
Diffstat (limited to 'sys/arch/mac68k')
-rw-r--r-- | sys/arch/mac68k/mac68k/disksubr.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/arch/mac68k/mac68k/disksubr.c b/sys/arch/mac68k/mac68k/disksubr.c index 3d9408dc6d9..e1f9d0f064e 100644 --- a/sys/arch/mac68k/mac68k/disksubr.c +++ b/sys/arch/mac68k/mac68k/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.30 2006/08/17 10:34:14 krw Exp $ */ +/* $OpenBSD: disksubr.c,v 1.31 2006/09/24 22:43:00 krw Exp $ */ /* $NetBSD: disksubr.c,v 1.22 1997/11/26 04:18:20 briggs Exp $ */ /* @@ -377,12 +377,13 @@ readdisklabel(dev, strat, lp, osdep, spoofonly) if (lp->d_secpercyl == 0) return ("invalid geometry"); lp->d_npartitions = RAW_PART + 1; - for (i = 0; i < MAXPARTITIONS; i++) { + for (i = 0; i < RAW_PART; i++) { lp->d_partitions[i].p_size = 0; lp->d_partitions[i].p_offset = 0; - lp->d_partitions[i].p_fstype = FS_UNUSED; } - lp->d_partitions[RAW_PART].p_size = lp->d_secperunit; + if (lp->d_partitions[i].p_size == 0) + lp->d_partitions[i].p_size = lp->d_secperunit; + lp->d_partitions[i].p_offset = 0; /* don't read the on-disk label if we are in spoofed-only mode */ if (spoofonly) |