Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 22 Jan 2006 07:49:11 +0100
From:      Manfred Lotz <manfred.lotz@arcor.de>
To:        Nate Lawson <nate@root.org>
Cc:        freebsd-acpi@freebsd.org
Subject:   Re: suspend/resume event
Message-ID:  <20060122074911.9d7566fc.manfred.lotz@arcor.de>
In-Reply-To: <43D29A95.7070809@root.org>
References:  <20060120200410.a05870c1.manfred.lotz@arcor.de> <43D13F8A.8000802@root.org> <20060121105719.2eb0c2f9.manfred.lotz@arcor.de> <43D29A95.7070809@root.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 21 Jan 2006 12:33:25 -0800
Nate Lawson <nate@root.org> wrote:

> Manfred Lotz wrote:
> > On Fri, 20 Jan 2006 11:52:42 -0800
> > Nate Lawson <nate@root.org> wrote:
> > 
> > 
> >>Manfred Lotz wrote:
> >>
> >>>Hi there,
> >>>With my Samsung X20 1730 suspend /resume works fine when doing
> >>>acpiconf -s 3. I added /etc/rc.d/moused restart in /etc/rc.resume
> >>>and the touchpad mouse gets awake after resuming. That's great.
> >>>
> >>>However when closing the lid (I set hw.acpi.lid_switch_state=S3)
> >>>and then pressing the power button although suspend/resume works
> >>>fine the mouse won't get restarted. This means /etc/rc.resume and
> >>>presumably /etc/rc.suspend won't get called in this case.
> >>>
> >>>Same happen when pressing Fn-ESC the key for suspend.
> >>>
> >>>How can I make sure /etc/rc.suspend as well as /etc/rc.resuem gets
> >>>called in the "non-acpiconf" cases?
> >>
> >>That's an implementation problem.  I think the right approach is to
> >>add a resume notification to devd.  That should be easy to do and I
> >>may look into it this weekend if no one submits a patch first.
> >>
> > 
> > 
> > Thanks. From what you said and after googling I tried the following:
> > 
> > I set:
> > sysctl hw.acpi.lid_switch_state=NONE
> > 
> > and added the following section at the end of /etc/devd.conf
> > 
> > notify 10 {
> >      match "system"          "ACPI";                   
> >      match "subsystem"       "Lid";                     
> >     action            "/etc/rc.lid  $notify"; 
> > };
> > 
> > created /etc/rc.lid:
> > 
> > <------ snip ---------->
> > #! /bin/sh
> > LOGGER="/usr/bin/logger -t lid_switch -p user.notice"
> > 
> > $LOGGER $1
> > <------ snip ---------->
> > 
> > made it executable
> > and restarted  devd via /etc/rc.d/devd restart
> > 
> > 
> > However after closing and then opening the lid nothing had happened.
> > 
> > Any idea what I did wrong?
> 
> Nothing offhand.  Try running devd manually with the -d flag so it
> won't go into the background and it will print the events on
> console.  Then close/open the lid.
> 
> 


-d flag helped. I just didn't wait long enough. It took almost
12 seconds after closing the lid till the message showed up
in /var/log/messages.

12 seconds is a long time. Is there anything I can adjust to make it
shorter?



-- 
Manfred





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20060122074911.9d7566fc.manfred.lotz>