summaryrefslogtreecommitdiff
path: root/sys/arch
diff options
context:
space:
mode:
Diffstat (limited to 'sys/arch')
-rw-r--r--sys/arch/alpha/alpha/disksubr.c7
-rw-r--r--sys/arch/amd64/amd64/disksubr.c7
-rw-r--r--sys/arch/arm/arm/disksubr.c7
-rw-r--r--sys/arch/aviion/aviion/disksubr.c7
-rw-r--r--sys/arch/hppa/hppa/disksubr.c7
-rw-r--r--sys/arch/hppa64/hppa64/disksubr.c7
-rw-r--r--sys/arch/i386/i386/disksubr.c7
-rw-r--r--sys/arch/macppc/macppc/disksubr.c7
-rw-r--r--sys/arch/mips64/mips64/disksubr.c7
-rw-r--r--sys/arch/mvmeppc/mvmeppc/disksubr.c7
10 files changed, 20 insertions, 50 deletions
diff --git a/sys/arch/alpha/alpha/disksubr.c b/sys/arch/alpha/alpha/disksubr.c
index 60e2b4c054c..d9f12456d95 100644
--- a/sys/arch/alpha/alpha/disksubr.c
+++ b/sys/arch/alpha/alpha/disksubr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disksubr.c,v 1.52 2006/08/20 03:14:21 krw Exp $ */
+/* $OpenBSD: disksubr.c,v 1.53 2006/09/16 14:56:11 krw Exp $ */
/* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */
/*
@@ -316,13 +316,10 @@ donot:
*/
for (dp2=dp, i=0; i < NDOSPART && n < 8; i++, dp2++) {
struct partition *pp = &lp->d_partitions[8+n];
- u_int64_t blkno = (u_int64_t)part_blkno +
- (u_int64_t)letoh32(dp2->dp_start) +
- (u_int64_t)letoh32(dp2->dp_size);
if (dp2->dp_typ == DOSPTYP_OPENBSD)
continue;
- if (blkno > lp->d_secperunit)
+ if (letoh32(dp2->dp_size) > lp->d_secperunit)
continue;
if (letoh32(dp2->dp_size))
pp->p_size = letoh32(dp2->dp_size);
diff --git a/sys/arch/amd64/amd64/disksubr.c b/sys/arch/amd64/amd64/disksubr.c
index 30e89d1fd20..a7a3e77ad73 100644
--- a/sys/arch/amd64/amd64/disksubr.c
+++ b/sys/arch/amd64/amd64/disksubr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disksubr.c,v 1.13 2006/08/24 00:22:22 krw Exp $ */
+/* $OpenBSD: disksubr.c,v 1.14 2006/09/16 14:56:11 krw Exp $ */
/* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */
/*
@@ -173,13 +173,10 @@ donot:
*/
for (dp2=dp, i=0; i < NDOSPART && n < 8; i++, dp2++) {
struct partition *pp = &lp->d_partitions[8+n];
- u_int64_t blkno = (u_int64_t)part_blkno +
- (u_int64_t)letoh32(dp2->dp_start) +
- (u_int64_t)letoh32(dp2->dp_size);
if (dp2->dp_typ == DOSPTYP_OPENBSD)
continue;
- if (blkno > lp->d_secperunit)
+ if (letoh32(dp2->dp_size) > lp->d_secperunit)
continue;
if (letoh32(dp2->dp_size))
pp->p_size = letoh32(dp2->dp_size);
diff --git a/sys/arch/arm/arm/disksubr.c b/sys/arch/arm/arm/disksubr.c
index 0887fd4c2b3..c7f39959906 100644
--- a/sys/arch/arm/arm/disksubr.c
+++ b/sys/arch/arm/arm/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/09/16 14:56:11 krw Exp $ */
/* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */
/*
@@ -172,13 +172,10 @@ donot:
*/
for (dp2=dp, i=0; i < NDOSPART && n < 8; i++, dp2++) {
struct partition *pp = &lp->d_partitions[8+n];
- u_int64_t blkno = (u_int64_t)part_blkno +
- (u_int64_t)letoh32(dp2->dp_start) +
- (u_int64_t)letoh32(dp2->dp_size);
if (dp2->dp_typ == DOSPTYP_OPENBSD)
continue;
- if (blkno > lp->d_secperunit)
+ if (letoh32(dp2->dp_size) > lp->d_secperunit)
continue;
if (letoh32(dp2->dp_size))
pp->p_size = letoh32(dp2->dp_size);
diff --git a/sys/arch/aviion/aviion/disksubr.c b/sys/arch/aviion/aviion/disksubr.c
index f9ae4a097a4..3a3c4eb2e51 100644
--- a/sys/arch/aviion/aviion/disksubr.c
+++ b/sys/arch/aviion/aviion/disksubr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disksubr.c,v 1.5 2006/08/20 03:14:21 krw Exp $ */
+/* $OpenBSD: disksubr.c,v 1.6 2006/09/16 14:56:11 krw Exp $ */
/* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */
/*
@@ -162,13 +162,10 @@ donot:
*/
for (dp2=dp, i=0; i < NDOSPART && n < 8; i++, dp2++) {
struct partition *pp = &lp->d_partitions[8+n];
- u_int64_t blkno = (u_int64_t)part_blkno +
- (u_int64_t)letoh32(dp2->dp_start) +
- (u_int64_t)letoh32(dp2->dp_size);
if (dp2->dp_typ == DOSPTYP_OPENBSD)
continue;
- if (blkno > lp->d_secperunit)
+ if (letoh32(dp2->dp_size) > lp->d_secperunit)
continue;
if (letoh32(dp2->dp_size))
pp->p_size = letoh32(dp2->dp_size);
diff --git a/sys/arch/hppa/hppa/disksubr.c b/sys/arch/hppa/hppa/disksubr.c
index 404ec4adb4c..1ef84730264 100644
--- a/sys/arch/hppa/hppa/disksubr.c
+++ b/sys/arch/hppa/hppa/disksubr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disksubr.c,v 1.32 2006/08/20 03:14:21 krw Exp $ */
+/* $OpenBSD: disksubr.c,v 1.33 2006/09/16 14:56:11 krw Exp $ */
/*
* Copyright (c) 1999 Michael Shalayeff
@@ -319,13 +319,10 @@ donot:
*/
for (dp2=dp, i=0; i < NDOSPART && n < 8; i++, dp2++) {
struct partition *pp = &lp->d_partitions[8+n];
- u_int64_t blkno = (u_int64_t)part_blkno +
- (u_int64_t)letoh32(dp2->dp_start) +
- (u_int64_t)letoh32(dp2->dp_size);
if (dp2->dp_typ == DOSPTYP_OPENBSD)
continue;
- if (blkno > lp->d_secperunit)
+ if (letoh32(dp2->dp_size) > lp->d_secperunit)
continue;
if (letoh32(dp2->dp_size))
pp->p_size = letoh32(dp2->dp_size);
diff --git a/sys/arch/hppa64/hppa64/disksubr.c b/sys/arch/hppa64/hppa64/disksubr.c
index 937a610adc0..93d4560534d 100644
--- a/sys/arch/hppa64/hppa64/disksubr.c
+++ b/sys/arch/hppa64/hppa64/disksubr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disksubr.c,v 1.15 2006/08/20 03:14:21 krw Exp $ */
+/* $OpenBSD: disksubr.c,v 1.16 2006/09/16 14:56:11 krw Exp $ */
/*
* Copyright (c) 1999 Michael Shalayeff
@@ -315,13 +315,10 @@ donot:
*/
for (dp2=dp, i=0; i < NDOSPART && n < 8; i++, dp2++) {
struct partition *pp = &lp->d_partitions[8+n];
- u_int64_t blkno = (u_int64_t)part_blkno +
- (u_int64_t)letoh32(dp2->dp_start) +
- (u_int64_t)letoh32(dp2->dp_size);
if (dp2->dp_typ == DOSPTYP_OPENBSD)
continue;
- if (blkno > lp->d_secperunit)
+ if (letoh32(dp2->dp_size) > lp->d_secperunit)
continue;
if (letoh32(dp2->dp_size))
pp->p_size = letoh32(dp2->dp_size);
diff --git a/sys/arch/i386/i386/disksubr.c b/sys/arch/i386/i386/disksubr.c
index a1c63891eb1..ed068a03da1 100644
--- a/sys/arch/i386/i386/disksubr.c
+++ b/sys/arch/i386/i386/disksubr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disksubr.c,v 1.54 2006/08/20 03:14:21 krw Exp $ */
+/* $OpenBSD: disksubr.c,v 1.55 2006/09/16 14:56:11 krw Exp $ */
/* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */
/*
@@ -173,13 +173,10 @@ donot:
*/
for (dp2=dp, i=0; i < NDOSPART && n < 8; i++, dp2++) {
struct partition *pp = &lp->d_partitions[8+n];
- u_int64_t blkno = (u_int64_t)part_blkno +
- (u_int64_t)letoh32(dp2->dp_start) +
- (u_int64_t)letoh32(dp2->dp_size);
if (dp2->dp_typ == DOSPTYP_OPENBSD)
continue;
- if (blkno > lp->d_secperunit)
+ if (letoh32(dp2->dp_size) > lp->d_secperunit)
continue;
if (letoh32(dp2->dp_size))
pp->p_size = letoh32(dp2->dp_size);
diff --git a/sys/arch/macppc/macppc/disksubr.c b/sys/arch/macppc/macppc/disksubr.c
index de962013ae6..35195b5e07b 100644
--- a/sys/arch/macppc/macppc/disksubr.c
+++ b/sys/arch/macppc/macppc/disksubr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disksubr.c,v 1.21 2006/08/20 03:14:21 krw Exp $ */
+/* $OpenBSD: disksubr.c,v 1.22 2006/09/16 14:56:11 krw Exp $ */
/* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */
/*
@@ -260,13 +260,10 @@ donot:
*/
for (dp2=dp, i=0; i < NDOSPART && n < 8; i++, dp2++) {
struct partition *pp = &lp->d_partitions[8+n];
- u_int64_t blkno = (u_int64_t)part_blkno +
- (u_int64_t)letoh32(dp2->dp_start) +
- (u_int64_t)letoh32(dp2->dp_size);
if (dp2->dp_typ == DOSPTYP_OPENBSD)
continue;
- if (blkno > lp->d_secperunit)
+ if (letoh32(dp2->dp_size) > lp->d_secperunit)
continue;
if (letoh32(dp2->dp_size))
pp->p_size = letoh32(dp2->dp_size);
diff --git a/sys/arch/mips64/mips64/disksubr.c b/sys/arch/mips64/mips64/disksubr.c
index 9f75b334511..28d7c2e714c 100644
--- a/sys/arch/mips64/mips64/disksubr.c
+++ b/sys/arch/mips64/mips64/disksubr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disksubr.c,v 1.21 2006/08/20 03:14:21 krw Exp $ */
+/* $OpenBSD: disksubr.c,v 1.22 2006/09/16 14:56:12 krw Exp $ */
/*
* Copyright (c) 1999 Michael Shalayeff
@@ -323,13 +323,10 @@ donot:
*/
for (dp2=dp, i=0; i < NDOSPART && n < 8; i++, dp2++) {
struct partition *pp = &lp->d_partitions[8+n];
- u_int64_t blkno = (u_int64_t)part_blkno +
- (u_int64_t)letoh32(dp2->dp_start) +
- (u_int64_t)letoh32(dp2->dp_size);
if (dp2->dp_typ == DOSPTYP_OPENBSD)
continue;
- if (blkno > lp->d_secperunit)
+ if (letoh32(dp2->dp_size) > lp->d_secperunit)
continue;
if (letoh32(dp2->dp_size))
pp->p_size = letoh32(dp2->dp_size);
diff --git a/sys/arch/mvmeppc/mvmeppc/disksubr.c b/sys/arch/mvmeppc/mvmeppc/disksubr.c
index b25418fd5ef..988c08d07b3 100644
--- a/sys/arch/mvmeppc/mvmeppc/disksubr.c
+++ b/sys/arch/mvmeppc/mvmeppc/disksubr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: disksubr.c,v 1.17 2006/08/20 03:14:21 krw Exp $ */
+/* $OpenBSD: disksubr.c,v 1.18 2006/09/16 14:56:12 krw Exp $ */
/* $NetBSD: disksubr.c,v 1.21 1996/05/03 19:42:03 christos Exp $ */
/*
@@ -176,13 +176,10 @@ donot:
*/
for (dp2=dp, i=0; i < NDOSPART && n < 8; i++, dp2++) {
struct partition *pp = &lp->d_partitions[8+n];
- u_int64_t blkno = (u_int64_t)part_blkno +
- (u_int64_t)letoh32(dp2->dp_start) +
- (u_int64_t)letoh32(dp2->dp_size);
if (dp2->dp_typ == DOSPTYP_OPENBSD)
continue;
- if (blkno > lp->d_secperunit)
+ if (letoh32(dp2->dp_size) > lp->d_secperunit)
continue;
if (letoh32(dp2->dp_size))
pp->p_size = letoh32(dp2->dp_size);