summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2015-01-12 16:33:32 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2015-01-12 16:33:32 +0000
commit0f19f197e4c7dbe7db988f2bb501c7b513644f64 (patch)
tree07f634ed4d90dcfaf89374ce8934767be9c89ce9
parenta3fb551dc33f569f1fb5383b8cee4036616b508e (diff)
Enable lid suspends by default in the kernel, and remove the question from
the installer. We used a full release cycle to learn that suspend/resume is reliable enough for this default. Personal policy can disable this using machdep.lidsuspend=0 in /etc/sysctl.conf ok more people begging, and less people whining
-rw-r--r--distrib/amd64/common/install.md3
-rw-r--r--distrib/i386/common/install.md3
-rw-r--r--distrib/miniroot/install.sub11
-rw-r--r--sys/arch/amd64/amd64/machdep.c4
-rw-r--r--sys/arch/arm/arm/arm32_machdep.c4
-rw-r--r--sys/arch/i386/i386/machdep.c4
6 files changed, 9 insertions, 20 deletions
diff --git a/distrib/amd64/common/install.md b/distrib/amd64/common/install.md
index 74580dd6b93..830f5dc8a94 100644
--- a/distrib/amd64/common/install.md
+++ b/distrib/amd64/common/install.md
@@ -1,4 +1,4 @@
-# $OpenBSD: install.md,v 1.36 2014/08/15 09:45:54 rpe Exp $
+# $OpenBSD: install.md,v 1.37 2015/01/12 16:33:31 deraadt Exp $
#
#
# Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -34,7 +34,6 @@
MDXAPERTURE=2
MDXDM=y
-MDLID=y
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 992dc1bc8a7..f6599eeac7b 100644
--- a/distrib/i386/common/install.md
+++ b/distrib/i386/common/install.md
@@ -1,4 +1,4 @@
-# $OpenBSD: install.md,v 1.59 2014/08/15 09:45:54 rpe Exp $
+# $OpenBSD: install.md,v 1.60 2015/01/12 16:33:31 deraadt Exp $
#
#
# Copyright (c) 1996 The NetBSD Foundation, Inc.
@@ -34,7 +34,6 @@
MDXAPERTURE=2
MDXDM=y
-MDLID=y
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 5a32649cf9e..0aff0d0f65d 100644
--- a/distrib/miniroot/install.sub
+++ b/distrib/miniroot/install.sub
@@ -1,4 +1,4 @@
-# $OpenBSD: install.sub,v 1.808 2015/01/07 19:31:51 rpe Exp $
+# $OpenBSD: install.sub,v 1.809 2015/01/12 16:33:31 deraadt Exp $
#
# Copyright (c) 1997-2009 Todd Miller, Theo de Raadt, Ken Westerback
# All rights reserved.
@@ -1842,10 +1842,6 @@ apply()
echo "machdep.allowaperture=$aperture # See xf86(4)" \
>>/mnt/etc/sysctl.conf
- [[ -n $lidsuspend ]] &&
- echo "machdep.lidsuspend=1 # Try to suspend on lid close" \
- >>/mnt/etc/sysctl.conf
-
[[ $xdm == y && -x /mnt/usr/X11R6/bin/xdm ]] &&
echo "xdm_flags=" >>/mnt/etc/rc.conf.local
@@ -1876,7 +1872,6 @@ questions() {
aperture=
xdm=
- lidsuspend=
if [[ -n $DISPLAY ]]; then
if [[ -n $(scan_dmesg '/^[a-z]*[01]: aperture needed/p') ]]; then
ask_yn "Do you expect to run the X Window System?" yes &&
@@ -1886,10 +1881,6 @@ questions() {
ask_yn "Do you want the X Window System to be started by xdm(1)?"
xdm=$resp
fi
- if [[ -n $MDLID ]]; then
- ask_yn "Do you want to suspend on lid close?" yes && \
- lidsuspend=$resp
- fi
fi
if [[ -n $CDEV ]]; then
diff --git a/sys/arch/amd64/amd64/machdep.c b/sys/arch/amd64/amd64/machdep.c
index fcf04826732..c7810aa9961 100644
--- a/sys/arch/amd64/amd64/machdep.c
+++ b/sys/arch/amd64/amd64/machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: machdep.c,v 1.205 2015/01/06 12:50:47 dlg Exp $ */
+/* $OpenBSD: machdep.c,v 1.206 2015/01/12 16:33:31 deraadt Exp $ */
/* $NetBSD: machdep.c,v 1.3 2003/05/07 22:58:18 fvdl Exp $ */
/*-
@@ -190,7 +190,7 @@ paddr_t lo32_paddr;
paddr_t tramp_pdirpa;
int kbd_reset;
-int lid_suspend;
+int lid_suspend = 1;
/*
* safepri is a safe priority for sleep to set for a spin-wait
diff --git a/sys/arch/arm/arm/arm32_machdep.c b/sys/arch/arm/arm/arm32_machdep.c
index 7a9d9dcd29f..4fc89d541d4 100644
--- a/sys/arch/arm/arm/arm32_machdep.c
+++ b/sys/arch/arm/arm/arm32_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: arm32_machdep.c,v 1.46 2014/11/16 12:30:56 deraadt Exp $ */
+/* $OpenBSD: arm32_machdep.c,v 1.47 2015/01/12 16:33:31 deraadt Exp $ */
/* $NetBSD: arm32_machdep.c,v 1.42 2003/12/30 12:33:15 pk Exp $ */
/*
@@ -111,7 +111,7 @@ int allowaperture = 0;
#endif
#if defined(__zaurus__)
-int lid_suspend;
+int lid_suspend = 1;
extern int xscale_maxspeed;
#endif
diff --git a/sys/arch/i386/i386/machdep.c b/sys/arch/i386/i386/machdep.c
index e3a72ca98e3..ec638cdc682 100644
--- a/sys/arch/i386/i386/machdep.c
+++ b/sys/arch/i386/i386/machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: machdep.c,v 1.560 2014/12/10 15:29:53 mikeb Exp $ */
+/* $OpenBSD: machdep.c,v 1.561 2015/01/12 16:33:31 deraadt Exp $ */
/* $NetBSD: machdep.c,v 1.214 1996/11/10 03:16:17 thorpej Exp $ */
/*-
@@ -237,7 +237,7 @@ void (*update_cpuspeed)(void) = NULL;
void via_update_sensor(void *args);
#endif
int kbd_reset;
-int lid_suspend;
+int lid_suspend = 1;
/*
* safepri is a safe priority for sleep to set for a spin-wait