From 5f88472daab576b55cc2d1a61f91397b305acdb8 Mon Sep 17 00:00:00 2001 From: Kenneth R Westerback Date: Thu, 24 Aug 2006 00:22:23 +0000 Subject: Move d_secpercyl test to after setting default size. Missed in earlier adjustment of other disksubr.c's. --- sys/arch/amd64/amd64/disksubr.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/arch/amd64/amd64/disksubr.c b/sys/arch/amd64/amd64/disksubr.c index 4131dd5d64d..30e89d1fd20 100644 --- a/sys/arch/amd64/amd64/disksubr.c +++ b/sys/arch/amd64/amd64/disksubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: disksubr.c,v 1.12 2006/08/20 03:14:21 krw Exp $ */ +/* $OpenBSD: disksubr.c,v 1.13 2006/08/24 00:22:22 krw Exp $ */ /* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */ /* @@ -78,10 +78,10 @@ readdisklabel(dev, strat, lp, osdep, spoofonly) /* minimal requirements for archetypal disk label */ if (lp->d_secsize < DEV_BSIZE) lp->d_secsize = DEV_BSIZE; - if (lp->d_secpercyl == 0) - return ("invalid geometry"); if (lp->d_secperunit == 0) lp->d_secperunit = 0x1fffffff; + if (lp->d_secpercyl == 0) + return ("invalid geometry"); lp->d_npartitions = RAW_PART + 1; for (i = 0; i < RAW_PART; i++) { lp->d_partitions[i].p_size = 0; -- cgit v1.2.3