From owner-freebsd-arch@FreeBSD.ORG Sun May 4 15:55:57 2014 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 4E915AE8; Sun, 4 May 2014 15:55:57 +0000 (UTC) Received: from sola.nimnet.asn.au (paqi.nimnet.asn.au [115.70.110.159]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id B671411C4; Sun, 4 May 2014 15:55:56 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by sola.nimnet.asn.au (8.14.2/8.14.2) with ESMTP id s44Ftk9m064089; Mon, 5 May 2014 01:55:46 +1000 (EST) (envelope-from smithi@nimnet.asn.au) Date: Mon, 5 May 2014 01:55:46 +1000 (EST) From: Ian Smith To: Adrian Chadd Subject: Re: proposal: set default lid state to S3, performance/economy Cx states to Cmax In-Reply-To: Message-ID: <20140505011654.O11699@sola.nimnet.asn.au> References: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Cc: Kevin Oberman , "freebsd-acpi@freebsd.org" , "freebsd-arch@freebsd.org" X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 04 May 2014 15:55:57 -0000 On Sun, 4 May 2014 01:27:38 -0700, Adrian Chadd wrote: > Hi, > > I'd like to propose flipping a few things: > > * Flipping the default lid state to S3. I think ACPI suspend/resume > seems to work well enough these days and I've not met anyone lately > who expects the default from their laptop to be "stay awake with the > lid shut." Meet me; sitting here right now with the X200 lid closed, backlight off, idling but 'working' via ssh. Laptops running as (mostly) headless servers would normally run with lid down - been doing this for years, keeps the cockroaches out, mostly :) Anyway, this would be a very poor default on any machine that didn't resume completely well every time. 'Seems to work well enough' on a still fairly limited range of laptops, I gather. I've yet to get this X200 (on stable/9) to suspend without losing USB - after the _second_ suspend, unlike yours - and besides it's not a big deal to set it to S3 when desired. Maybe an rc.conf knob like 'suspend_on_lid="YES"' ono rather than requiring sysctl.conf setting? > * Save chip bugs that we should add workarounds for, we should be OK > to enter lower sleep states when idling. Flipping this may expose some > further crazy driver, platform or timer bugs, but they again likely > should be fixed. This seems likely less controversial, and should suit most, probably. An Nate Lawson said often many years ago, we really need some sort of profile mechanism to describe as a package different ACPI and power settings for different brands / models / usage cases, plugins if you like; then 'resumes_reliably' could condition stuff. But I digress .. 2c, and not assuming myself to be any sort of 'average user', Ian > what do people think? > > > -a > > > Index: etc/defaults/rc.conf > =================================================================== > --- etc/defaults/rc.conf (revision 265255) > +++ etc/defaults/rc.conf (working copy) > @@ -642,9 +642,9 @@ > devfs_set_rulesets="" # A list of /mount/dev=ruleset_name settings to > # apply (must be mounted already, i.e. fstab(5)) > devfs_load_rulesets="YES" # Enable to always load the default rulesets > -performance_cx_lowest="HIGH" # Online CPU idle state > +performance_cx_lowest="Cmax" # Online CPU idle state > performance_cpu_freq="NONE" # Online CPU frequency > -economy_cx_lowest="HIGH" # Offline CPU idle state > +economy_cx_lowest="Cmax" # Offline CPU idle state > economy_cpu_freq="NONE" # Offline CPU frequency > virecover_enable="YES" # Perform housekeeping for the vi(1) editor > ugidfw_enable="NO" # Load mac_bsdextended(4) rules on boot > Index: sys/dev/acpica/acpi.c > =================================================================== > --- sys/dev/acpica/acpi.c (revision 265255) > +++ sys/dev/acpica/acpi.c (working copy) > @@ -620,11 +620,12 @@ > > /* > * Dispatch the default sleep state to devices. The lid switch is set > - * to UNKNOWN by default to avoid surprising users. > + * to S3 to mirror what everything else iBook and later does. > */ > sc->acpi_power_button_sx = acpi_sleep_states[ACPI_STATE_S5] ? > ACPI_STATE_S5 : ACPI_STATE_UNKNOWN; > - sc->acpi_lid_switch_sx = ACPI_STATE_UNKNOWN; > + sc->acpi_lid_switch_sx = acpi_sleep_states[ACPI_STATE_S3] ? > + ACPI_STATE_S3 : ACPI_STATE_UNKNOWN; > sc->acpi_standby_sx = acpi_sleep_states[ACPI_STATE_S1] ? > ACPI_STATE_S1 : ACPI_STATE_UNKNOWN; > sc->acpi_suspend_sx = acpi_sleep_states[ACPI_STATE_S3] ? > _______________________________________________ > freebsd-acpi@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-acpi > To unsubscribe, send any mail to "freebsd-acpi-unsubscribe@freebsd.org" >