summaryrefslogtreecommitdiff
path: root/distrib
diff options
context:
space:
mode:
authorKenneth R Westerback <krw@cvs.openbsd.org>2010-08-08 17:02:15 +0000
committerKenneth R Westerback <krw@cvs.openbsd.org>2010-08-08 17:02:15 +0000
commit6e993c7576c692442c192b8c13aa7f44241c89fb (patch)
tree0aa2a2dd420320c3c5826b6febbaedb5697faee2 /distrib
parent857503eac98e97bc4dec50227754949bd94bad18 (diff)
Look for MD devices or assurance that apmd would be a useful thing to
run. If found, add "apmd_flags=" installed rc.conf.local. Suggested by deraadt@. i386/apm test by kettenis@. ok deraadt@
Diffstat (limited to 'distrib')
-rw-r--r--distrib/amd64/common/install.md3
-rw-r--r--distrib/i386/common/install.md3
-rw-r--r--distrib/miniroot/install.sub9
-rw-r--r--distrib/zaurus/ramdisk/install.md3
4 files changed, 14 insertions, 4 deletions
diff --git a/distrib/amd64/common/install.md b/distrib/amd64/common/install.md
index 1966ef404cb..54c7cf591bb 100644
--- a/distrib/amd64/common/install.md
+++ b/distrib/amd64/common/install.md
@@ -1,4 +1,4 @@
-# $OpenBSD: install.md,v 1.23 2009/06/11 04:28:49 deraadt Exp $
+# $OpenBSD: install.md,v 1.24 2010/08/08 17:02:14 krw Exp $
#
#
# Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -34,6 +34,7 @@
MDXAPERTURE=2
MDXDM=y
+MDAPMD="^acpi0: sleep .* S3"
NCPU=$(sysctl -n hw.ncpufound)
((NCPU > 1)) && { DEFAULTSETS="bsd bsd.rd bsd.mp" ; SANESETS="bsd bsd.mp" ; }
diff --git a/distrib/i386/common/install.md b/distrib/i386/common/install.md
index 301d6362bc8..130a005c45d 100644
--- a/distrib/i386/common/install.md
+++ b/distrib/i386/common/install.md
@@ -1,4 +1,4 @@
-# $OpenBSD: install.md,v 1.47 2009/06/11 17:05:06 deraadt Exp $
+# $OpenBSD: install.md,v 1.48 2010/08/08 17:02:14 krw Exp $
#
#
# Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -34,6 +34,7 @@
MDXAPERTURE=2
MDXDM=y
+MDAPMD="^apm0 |^acpi0: sleep .* S3"
NCPU=$(sysctl -n hw.ncpufound)
((NCPU > 1)) && { DEFAULTSETS="bsd bsd.rd bsd.mp" ; SANESETS="bsd bsd.mp" ; }
diff --git a/distrib/miniroot/install.sub b/distrib/miniroot/install.sub
index adc5dc42d16..d50be3b863f 100644
--- a/distrib/miniroot/install.sub
+++ b/distrib/miniroot/install.sub
@@ -1,4 +1,4 @@
-# $OpenBSD: install.sub,v 1.615 2010/08/05 10:45:32 halex Exp $
+# $OpenBSD: install.sub,v 1.616 2010/08/08 17:02:14 krw 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
@@ -68,6 +68,7 @@
# MDDKDEVS - '/^[sw]d[0-9][0-9]* /s/ .*//p' assumed if not provided
# MDCDDEVS - '/^cd[0-9][0-9]* /s/ .*//p' assumed if not provided
# MDMTDEVS - '/^[cms]t[0-9][0-9]* /s/ .*//p'
+# MDAPMDEV - '' assumed if not provided
# MDXAPERTURE - set machdep.allowaperture=value in sysctl.conf
. install.md
@@ -1756,6 +1757,12 @@ server $1
>>/mnt/etc/rc.conf.local
fi
+ if [[ -n $MDAPMD ]]; then
+ [[ $MDAPMD == y || -n $(egrep "$MDAPMD" /var/run/dmesg.boot) ]] && \
+ echo "apmd_flags= # enabled during install" \
+ >>/mnt/etc/rc.conf.local
+ fi
+
if [[ $defcons == y ]]; then
cp /mnt/etc/ttys /tmp/ttys
sed -e "/^$CTTY/s/std.9600/std.${CSPEED}/" \
diff --git a/distrib/zaurus/ramdisk/install.md b/distrib/zaurus/ramdisk/install.md
index 78a6fdb4608..c9d747badda 100644
--- a/distrib/zaurus/ramdisk/install.md
+++ b/distrib/zaurus/ramdisk/install.md
@@ -1,4 +1,4 @@
-# $OpenBSD: install.md,v 1.24 2009/06/11 18:52:42 deraadt Exp $
+# $OpenBSD: install.md,v 1.25 2010/08/08 17:02:14 krw Exp $
#
#
# Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -33,6 +33,7 @@
#
MDXDM=y
+MDAPMD=y
md_installboot() {
}