diff options
author | Kenneth R Westerback <krw@cvs.openbsd.org> | 2013-10-20 10:11:18 +0000 |
---|---|---|
committer | Kenneth R Westerback <krw@cvs.openbsd.org> | 2013-10-20 10:11:18 +0000 |
commit | 95c7a7e8448aceffb1dc9ab5854db4252b367b90 (patch) | |
tree | 9c7a097306f2cb90ad99a5ad818dfb7ef6b29698 /sys/arch/sparc/dev/xd.c | |
parent | 062c213f0e80b7a369acb9b7291eee884ceaea1c (diff) |
(daddr_t) -> (u_int64_t) when multiplying ncylinders * secpercyl to
get disk size, since DL_SETDSIZE() takes disk sector values, not
512-byte block values.
Diffstat (limited to 'sys/arch/sparc/dev/xd.c')
-rw-r--r-- | sys/arch/sparc/dev/xd.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/arch/sparc/dev/xd.c b/sys/arch/sparc/dev/xd.c index f7dd8eba5ad..f16c7bce5e5 100644 --- a/sys/arch/sparc/dev/xd.c +++ b/sys/arch/sparc/dev/xd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: xd.c,v 1.59 2013/10/14 23:26:22 krw Exp $ */ +/* $OpenBSD: xd.c,v 1.60 2013/10/20 10:11:16 krw Exp $ */ /* $NetBSD: xd.c,v 1.37 1997/07/29 09:58:16 fair Exp $ */ /* @@ -300,7 +300,7 @@ xdgetdisklabel(xd, b) lp->d_secsize = XDFM_BPS; if (sl->sl_magic == SUN_DKMAGIC) { lp->d_secpercyl = sl->sl_nsectors * sl->sl_ntracks; - DL_SETDSIZE(lp, (daddr_t)lp->d_secpercyl * sl->sl_ncylinders); + DL_SETDSIZE(lp, (u_int64_t)lp->d_secpercyl * sl->sl_ncylinders); } else { lp->d_secpercyl = 1; } |