Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/netbsd-6]: src Pull up following revision(s) (requested by abs in ticket...
details: https://anonhg.NetBSD.org/src/rev/d5d99ee4ba32
branches: netbsd-6
changeset: 774315:d5d99ee4ba32
user: riz <riz%NetBSD.org@localhost>
date: Thu Jul 05 18:16:14 2012 +0000
description:
Pull up following revision(s) (requested by abs in ticket #403):
sys/arch/vax/include/disklabel.h: revision 1.6
sys/sys/bootblock.h: revision 1.54
sys/arch/vax/include/types.h: revision 1.46
distrib/vax/miniroot/Makefile.inc: revision 1.21
- Increase MAXPARTITIONS for vax from 8 to 16, using the standard NetBSD
mechanism to ensure all existing /dev nodes continue to work
- Adjust boot block layout to fit additional partitions
- Adjust number of inodes on install media
diffstat:
distrib/vax/miniroot/Makefile.inc | 4 ++--
sys/arch/vax/include/disklabel.h | 26 ++++++++++++++++++++------
sys/arch/vax/include/types.h | 3 ++-
sys/sys/bootblock.h | 7 ++++---
4 files changed, 28 insertions(+), 12 deletions(-)
diffs (98 lines):
diff -r 7d8e625f3be1 -r d5d99ee4ba32 distrib/vax/miniroot/Makefile.inc
--- a/distrib/vax/miniroot/Makefile.inc Thu Jul 05 18:12:46 2012 +0000
+++ b/distrib/vax/miniroot/Makefile.inc Thu Jul 05 18:16:14 2012 +0000
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile.inc,v 1.20 2010/02/11 09:06:51 roy Exp $
+# $NetBSD: Makefile.inc,v 1.20.8.1 2012/07/05 18:16:15 riz Exp $
IMAGESIZE= 7m
-MAKEFS_FLAGS= -o density=4k
+MAKEFS_FLAGS= -o density=3k
IMAGEENDIAN= le
MAKEDEVTARGETS= all
LISTS+= ${DISTRIBDIR}/common/list.sysinst
diff -r 7d8e625f3be1 -r d5d99ee4ba32 sys/arch/vax/include/disklabel.h
--- a/sys/arch/vax/include/disklabel.h Thu Jul 05 18:12:46 2012 +0000
+++ b/sys/arch/vax/include/disklabel.h Thu Jul 05 18:16:14 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: disklabel.h,v 1.5 2011/08/30 12:39:59 bouyer Exp $ */
+/* $NetBSD: disklabel.h,v 1.5.8.1 2012/07/05 18:16:14 riz Exp $ */
/*
* Copyright (c) 1994 Christopher G. Demetriou
@@ -33,11 +33,25 @@
#ifndef _MACHINE_DISKLABEL_H_
#define _MACHINE_DISKLABEL_H_
-#define LABELUSESMBR 0 /* no MBR partitionning */
-#define LABELSECTOR 0 /* sector containing label */
-#define LABELOFFSET 64 /* offset of label in sector */
-#define MAXPARTITIONS 8 /* number of partitions */
-#define RAW_PART 2 /* raw partition: xx?c */
+#define LABELUSESMBR 0 /* no MBR partitionning */
+#define LABELSECTOR 0 /* sector containing label */
+#define LABELOFFSET 64 /* offset of label in sector */
+#define MAXPARTITIONS 16 /* number of partitions */
+#define OLDMAXPARTITIONS 8 /* number of partitions before nb-6 */
+#define RAW_PART 2 /* raw partition: xx?c */
+
+/*
+ * We use the highest bit of the minor number for the partition number.
+ * This maintains backward compatibility with device nodes created before
+ * MAXPARTITIONS was increased.
+ */
+#define __VAX_MAXDISKS ((1 << 20) / MAXPARTITIONS)
+#define DISKUNIT(dev) ((minor(dev) / OLDMAXPARTITIONS) % __VAX_MAXDISKS)
+#define DISKPART(dev) ((minor(dev) % OLDMAXPARTITIONS) + \
+ ((minor(dev) / (__VAX_MAXDISKS * OLDMAXPARTITIONS)) * OLDMAXPARTITIONS))
+#define DISKMINOR(unit, part) \
+ (((unit) * OLDMAXPARTITIONS) + ((part) % OLDMAXPARTITIONS) + \
+ ((part) / OLDMAXPARTITIONS) * (__VAX_MAXDISKS * OLDMAXPARTITIONS))
/* Just a dummy */
#ifndef _LOCORE
diff -r 7d8e625f3be1 -r d5d99ee4ba32 sys/arch/vax/include/types.h
--- a/sys/arch/vax/include/types.h Thu Jul 05 18:12:46 2012 +0000
+++ b/sys/arch/vax/include/types.h Thu Jul 05 18:16:14 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: types.h,v 1.44 2012/01/17 20:34:57 joerg Exp $ */
+/* $NetBSD: types.h,v 1.44.2.1 2012/07/05 18:16:14 riz Exp $ */
/*-
* Copyright (c) 1990 The Regents of the University of California.
@@ -78,6 +78,7 @@
#define __HAVE_CPU_DATA_FIRST
#define __HAVE_MM_MD_READWRITE
#define __HAVE_MM_MD_DIRECT_MAPPED_PHYS
+#define __HAVE_OLD_DISKLABEL
#define __HAVE___LWP_GETPRIVATE_FAST
#define __HAVE_NO___THREAD
diff -r 7d8e625f3be1 -r d5d99ee4ba32 sys/sys/bootblock.h
--- a/sys/sys/bootblock.h Thu Jul 05 18:12:46 2012 +0000
+++ b/sys/sys/bootblock.h Thu Jul 05 18:16:14 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: bootblock.h,v 1.52 2011/01/06 01:08:48 jakllsch Exp $ */
+/* $NetBSD: bootblock.h,v 1.52.14.1 2012/07/05 18:16:15 riz Exp $ */
/*-
* Copyright (c) 2002-2004 The NetBSD Foundation, Inc.
@@ -1389,7 +1389,8 @@
uint8_t bb_mbone; /* must be one */
uint16_t bb_lbn_hi; /* lbn (hi word) of bootstrap */
uint16_t bb_lbn_low; /* lbn (low word) of bootstrap */
- uint8_t pad1[332];
+ uint8_t pad1[460];
+ /* disklabel offset is 64 from base, or 56 from start of pad1 */
/* The rest of these fields are identification area and describe
* the secondary block for uVAX VMB.
@@ -1411,7 +1412,7 @@
/* The rest is unused.
*/
- uint8_t pad2[148];
+ uint8_t pad2[20];
} __packed;
#define VAX_BOOT_MAGIC1 0x18 /* size of BB info? */
Home |
Main Index |
Thread Index |
Old Index