Module Name:    src
Committed By:   mlelstv
Date:           Sat Oct 11 14:05:12 UTC 2014

Modified Files:
        src/sys/dev/ata: wd.c

Log Message:
The partition size is always computed in native blocks. The code also assumes
that native blocks are always DEVB_SIZE (a few lines earlier) which makes
the current calculation a no-op.


To generate a diff of this commit:
cvs rdiff -u -r1.413 -r1.414 src/sys/dev/ata/wd.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/ata/wd.c
diff -u src/sys/dev/ata/wd.c:1.413 src/sys/dev/ata/wd.c:1.414
--- src/sys/dev/ata/wd.c:1.413	Wed Sep 10 07:04:48 2014
+++ src/sys/dev/ata/wd.c	Sat Oct 11 14:05:11 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: wd.c,v 1.413 2014/09/10 07:04:48 matt Exp $ */
+/*	$NetBSD: wd.c,v 1.414 2014/10/11 14:05:11 mlelstv Exp $ */
 
 /*
  * Copyright (c) 1998, 2001 Manuel Bouyer.  All rights reserved.
@@ -54,7 +54,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: wd.c,v 1.413 2014/09/10 07:04:48 matt Exp $");
+__KERNEL_RCSID(0, "$NetBSD: wd.c,v 1.414 2014/10/11 14:05:11 mlelstv Exp $");
 
 #include "opt_ata.h"
 
@@ -1082,8 +1082,7 @@ wdgetdefaultlabel(struct wd_softc *wd, s
 	lp->d_flags = 0;
 
 	lp->d_partitions[RAW_PART].p_offset = 0;
-	lp->d_partitions[RAW_PART].p_size =
-	    lp->d_secperunit * (lp->d_secsize / DEV_BSIZE);
+	lp->d_partitions[RAW_PART].p_size = lp->d_secperunit;
 	lp->d_partitions[RAW_PART].p_fstype = FS_UNUSED;
 	lp->d_npartitions = RAW_PART + 1;
 

Reply via email to