summaryrefslogtreecommitdiff
path: root/distrib
diff options
context:
space:
mode:
authorAlexander Hall <halex@cvs.openbsd.org>2011-07-06 20:02:17 +0000
committerAlexander Hall <halex@cvs.openbsd.org>2011-07-06 20:02:17 +0000
commit88fa8e979fdda9d0ac55cb2dce68be6a503f8237 (patch)
tree894ae19d8c55b3ff43c299af9197fa8df67decde /distrib
parent58e4bb0ca88838f102fd52d15bc154914ad61482 (diff)
As non-mp install.md's neither set NCPU, nor will have a bsd.mp,
we could as well pull the 'mv bsd.mp bsd' and the associated checks out of there. ok deraadt@ "makes sense" todd@
Diffstat (limited to 'distrib')
-rw-r--r--distrib/amd64/common/install.md8
-rw-r--r--distrib/hppa/install.md8
-rw-r--r--distrib/i386/common/install.md8
-rw-r--r--distrib/macppc/ramdisk/install.md8
-rw-r--r--distrib/miniroot/install.sub9
-rw-r--r--distrib/mvme88k/ramdisk/install.md8
-rw-r--r--distrib/sgi/ramdisk/install.md8
-rw-r--r--distrib/sparc64/common/install.md8
8 files changed, 15 insertions, 50 deletions
diff --git a/distrib/amd64/common/install.md b/distrib/amd64/common/install.md
index b85b3656b02..2a1ee66dd92 100644
--- a/distrib/amd64/common/install.md
+++ b/distrib/amd64/common/install.md
@@ -1,4 +1,4 @@
-# $OpenBSD: install.md,v 1.28 2011/04/17 20:57:10 krw Exp $
+# $OpenBSD: install.md,v 1.29 2011/07/06 20:02:16 halex Exp $
#
#
# Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -39,12 +39,6 @@ NCPU=$(sysctl -n hw.ncpufound)
((NCPU > 1)) && { DEFAULTSETS="bsd bsd.rd bsd.mp" ; SANESETS="bsd bsd.mp" ; }
md_installboot() {
- if [[ -f /mnt/bsd.mp ]] && ((NCPU > 1)); then
- echo "Multiprocessor machine; using bsd.mp instead of bsd."
- mv /mnt/bsd /mnt/bsd.sp 2>/dev/null
- mv /mnt/bsd.mp /mnt/bsd
- fi
-
cp /usr/mdec/boot /mnt/boot
if ! /usr/mdec/installboot /mnt/boot /usr/mdec/biosboot ${1} ; then
echo "\nFailed to install bootblocks."
diff --git a/distrib/hppa/install.md b/distrib/hppa/install.md
index e0e9c71a443..59cc80ae02d 100644
--- a/distrib/hppa/install.md
+++ b/distrib/hppa/install.md
@@ -1,4 +1,4 @@
-# $OpenBSD: install.md,v 1.19 2011/04/17 20:57:10 krw Exp $
+# $OpenBSD: install.md,v 1.20 2011/07/06 20:02:16 halex Exp $
#
# machine dependent section of installation/upgrade script.
#
@@ -9,12 +9,6 @@ NCPU=$(sysctl -n hw.ncpufound)
((NCPU > 1)) && { DEFAULTSETS="bsd bsd.rd bsd.mp" ; SANESETS="bsd bsd.mp" ; }
md_installboot() {
- if [[ -f /mnt/bsd.mp ]] && ((NCPU > 1)); then
- echo "Multiprocessor machine; using bsd.mp instead of bsd."
- mv /mnt/bsd /mnt/bsd.sp 2>/dev/null
- mv /mnt/bsd.mp /mnt/bsd
- fi
-
/sbin/disklabel -B $1
}
diff --git a/distrib/i386/common/install.md b/distrib/i386/common/install.md
index 19a72ee89da..9b25a6bb221 100644
--- a/distrib/i386/common/install.md
+++ b/distrib/i386/common/install.md
@@ -1,4 +1,4 @@
-# $OpenBSD: install.md,v 1.52 2011/04/17 20:57:10 krw Exp $
+# $OpenBSD: install.md,v 1.53 2011/07/06 20:02:16 halex Exp $
#
#
# Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -39,12 +39,6 @@ NCPU=$(sysctl -n hw.ncpufound)
((NCPU > 1)) && { DEFAULTSETS="bsd bsd.rd bsd.mp" ; SANESETS="bsd bsd.mp" ; }
md_installboot() {
- if [[ -f /mnt/bsd.mp ]] && ((NCPU > 1)); then
- echo "Multiprocessor machine; using bsd.mp instead of bsd."
- mv /mnt/bsd /mnt/bsd.sp 2>/dev/null
- mv /mnt/bsd.mp /mnt/bsd
- fi
-
# LBA biosboot uses /boot's i-node number. Using 'cat' preserves that
# number, so multiboot setups (NTLDR) can work across upgrades.
cat /usr/mdec/boot >/mnt/boot
diff --git a/distrib/macppc/ramdisk/install.md b/distrib/macppc/ramdisk/install.md
index e45ed1c0fe7..562ed7978be 100644
--- a/distrib/macppc/ramdisk/install.md
+++ b/distrib/macppc/ramdisk/install.md
@@ -1,4 +1,4 @@
-# $OpenBSD: install.md,v 1.49 2011/04/17 20:57:10 krw Exp $
+# $OpenBSD: install.md,v 1.50 2011/07/06 20:02:16 halex Exp $
#
#
# Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -40,12 +40,6 @@ NCPU=$(sysctl -n hw.ncpufound)
md_installboot() {
local _disk=$1
- if [[ -f /mnt/bsd.mp ]] && ((NCPU > 1)); then
- echo "Multiprocessor machine; using bsd.mp instead of bsd."
- mv /mnt/bsd /mnt/bsd.sp 2>/dev/null
- mv /mnt/bsd.mp /mnt/bsd
- fi
-
# If there is an MSDOS partition on the boot disk, copy ofwboot
# into it.
if fdisk $_disk | grep -q 'Signature: 0xAA55'; then
diff --git a/distrib/miniroot/install.sub b/distrib/miniroot/install.sub
index 0d262158adf..fe639a82f77 100644
--- a/distrib/miniroot/install.sub
+++ b/distrib/miniroot/install.sub
@@ -1,4 +1,4 @@
-# $OpenBSD: install.sub,v 1.640 2011/07/06 15:35:15 ajacoutot Exp $
+# $OpenBSD: install.sub,v 1.641 2011/07/06 20:02:16 halex Exp $
# $NetBSD: install.sub,v 1.5.2.8 1996/09/02 23:25:02 pk Exp $
#
# Copyright (c) 1997-2009 Todd Miller, Theo de Raadt, Ken Westerback
@@ -69,6 +69,7 @@
# MDCDDEVS - '/^cd[0-9][0-9]* /s/ .*//p' assumed if not provided
# MDMTDEVS - '/^[cms]t[0-9][0-9]* /s/ .*//p'
# MDXAPERTURE - set machdep.allowaperture=value in sysctl.conf
+# NCPU - the number of cpus for mp capable arches
. install.md
set_term() {
@@ -1967,6 +1968,12 @@ finish_up() {
md_installboot $ROOTDISK
+ if [[ -f /mnt/bsd.mp ]] && ((NCPU > 1)); then
+ echo "Multiprocessor machine; using bsd.mp instead of bsd."
+ mv /mnt/bsd /mnt/bsd.sp 2>/dev/null
+ mv /mnt/bsd.mp /mnt/bsd
+ fi
+
[[ "$MODE" == upgrade ]] && run_sysmerge
# Pat on the back.
diff --git a/distrib/mvme88k/ramdisk/install.md b/distrib/mvme88k/ramdisk/install.md
index 33b9413d593..efa7ca06170 100644
--- a/distrib/mvme88k/ramdisk/install.md
+++ b/distrib/mvme88k/ramdisk/install.md
@@ -1,4 +1,4 @@
-# $OpenBSD: install.md,v 1.39 2011/04/17 20:57:11 krw Exp $
+# $OpenBSD: install.md,v 1.40 2011/07/06 20:02:16 halex Exp $
# Copyright (c) 1996 The NetBSD Foundation, Inc.
# All rights reserved.
#
@@ -37,12 +37,6 @@ NCPU=$(sysctl -n hw.ncpufound)
((NCPU > 1)) && { DEFAULTSETS="bsd bsd.rd bsd.mp" ; SANESETS="bsd bsd.mp" ; }
md_installboot() {
- if [[ -f /mnt/bsd.mp ]] && ((NCPU > 1)); then
- echo "Multiprocessor machine; using bsd.mp instead of bsd."
- mv /mnt/bsd /mnt/bsd.sp 2>/dev/null
- mv /mnt/bsd.mp /mnt/bsd
- fi
-
cp /mnt/usr/mdec/bootsd /mnt/boot
/mnt/usr/mdec/installboot /mnt/boot /mnt/usr/mdec/bootxx /dev/r${1}a
}
diff --git a/distrib/sgi/ramdisk/install.md b/distrib/sgi/ramdisk/install.md
index 35263ea5981..d1738eeeb33 100644
--- a/distrib/sgi/ramdisk/install.md
+++ b/distrib/sgi/ramdisk/install.md
@@ -1,4 +1,4 @@
-# $OpenBSD: install.md,v 1.28 2011/06/07 09:38:59 jasper Exp $
+# $OpenBSD: install.md,v 1.29 2011/07/06 20:02:16 halex Exp $
#
#
# Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -55,12 +55,6 @@ md_installboot() {
if [[ -f /mnt/bsd.rd.${IPARCH} ]]; then
mv /mnt/bsd.rd.${IPARCH} /mnt/bsd.rd
fi
-
- if [[ -f /mnt/bsd.mp ]] && ((NCPU > 1)); then
- echo "Multiprocessor machine; using bsd.mp instead of bsd."
- mv /mnt/bsd /mnt/bsd.sp 2>/dev/null
- mv /mnt/bsd.mp /mnt/bsd
- fi
}
md_prep_disklabel()
diff --git a/distrib/sparc64/common/install.md b/distrib/sparc64/common/install.md
index 6d252403d14..bd97a3f840f 100644
--- a/distrib/sparc64/common/install.md
+++ b/distrib/sparc64/common/install.md
@@ -1,4 +1,4 @@
-# $OpenBSD: install.md,v 1.35 2011/04/17 20:57:11 krw Exp $
+# $OpenBSD: install.md,v 1.36 2011/07/06 20:02:16 halex Exp $
# $NetBSD: install.md,v 1.3.2.5 1996/08/26 15:45:28 gwr Exp $
#
#
@@ -43,12 +43,6 @@ NCPU=$(sysctl -n hw.ncpufound)
md_installboot() {
local _prefix
- if [[ -f /mnt/bsd.mp ]] && ((NCPU > 1)); then
- echo "Multiprocessor machine; using bsd.mp instead of bsd."
- mv /mnt/bsd /mnt/bsd.sp 2>/dev/null
- mv /mnt/bsd.mp /mnt/bsd
- fi
-
# Figure out which /usr/mdec directory to use
if [ -e /mnt/usr/mdec/ofwboot ]; then
_prefix=/mnt/usr/mdec