Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 27 May 2009 12:24:05 +0100
From:      Rui Paulo <rpaulo@freebsd.org>
To:        nocturnal <swehack@gmail.com>
Cc:        freebsd-acpi@freebsd.org
Subject:   Re: MacBook, acpiconf sleep state shuts machine down
Message-ID:  <E3F5E38B-8FBA-4CD9-9C09-46EFA3785CE7@freebsd.org>
In-Reply-To: <9aed80930905260648h41633265p1f69f4368a2c9b44@mail.gmail.com>
References:  <9aed80930905260648h41633265p1f69f4368a2c9b44@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 2440 and 3156)
--Apple-Mail-1-975756977
Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes
Content-Transfer-Encoding: 7bit

On 26 May 2009, at 14:48, nocturnal wrote:

> I'm trying to get my MacBook with FreeBSD 7.2-RELEASE to at least  
> suspend to
> RAM, even though hw.acpi.supported_sleep_state lists S3, S4 and S5.
>
> Though it doesn't matter which one i use, it will not wake back up  
> from the
> sleep state.
>
> So far i've created a devd notify which runs a script that in turn  
> runs
> acpiconf when the Lid is closed and sets state S3. When the script  
> receives
> 0x01 it sets S1.
>
> I've tried with S3, S4 and S5 at 0x00 and it never wakes up, should  
> i use
> something other than S1 for 0x01?
>
> It goes into some sort of sleep state, the apple light goes off and  
> i hear a
> noise similar from my other macbooks with Darwin that indicates the  
> HDD has
> turned off(I BELIEVE), it's basically the macbook-is-sleeping-sound  
> again.
> ;D
>
> But when i then open the lid, it either shuts down and i have to  
> turn it
> back on, or it gets stuck in sleep state and i have to do a cold  
> shutdown
> and reboot it to get back into the system.
>
> How can i have acpi recognize the Lid is opened and do what it's  
> being told
> even in sleep state? Is ACPI being disabled in sleep state?
>
> I've also set hw.acpi.disable_on_reboot="1" in loader.conf to  
> hopefully make
> it stop this behaviour but it did not help.
>
> Also something i find weird or confusing is that sysctl has a value
> hw.acpi.power_button_state that is set to S5 and one
> hw.acpi.sleep_button_state set to S3. Also a  
> hw.acpi.lid_switch_state set to
> NONE.
>
> hw.acpi.standby_state: S1
> hw.acpi.suspend_state: S3
> hw.acpi.s4bios: 0
> hw.acpi.handle_reboot: 0
>
> I would appreciate any other hints & tips from people who have  
> experience
> with CPU states and ACPI on macbooks.

You may want to try a newer FreeBSD version that supports SMP suspend.
Otherwise you need to disable SMP in loader.conf, 'kern.smp.disabled=1'.

Either way, I haven't tested this for a long time so I don't know if  
it will work.

--
Rui Paulo

--Apple-Mail-1-975756977
content-type: application/pgp-signature; x-mac-type=70674453;
	name=PGP.sig
content-description: This is a digitally signed message part
content-disposition: inline; filename=PGP.sig
content-transfer-encoding: 7bit

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Darwin)

iEYEARECAAYFAkodItUACgkQfD8M/ASTygJNVwCfT00sQBzCd/nWogOeCBTBHJgm
dBgAmgPjHIunDlAzpiRpj/aZIMifWcWK
=Vk6n
-----END PGP SIGNATURE-----

--Apple-Mail-1-975756977--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E3F5E38B-8FBA-4CD9-9C09-46EFA3785CE7>