On Fri 03. Mar - 08:26:44, Stefan Seyfried wrote:
> On Thu, Mar 02, 2006 at 01:10:39PM -0700, Holger Macht wrote:
>  
> > Modified:
> >    trunk/powersave/daemon/pm_interface.cpp
> > Log:
> > remove check if suspend2disk is supported. We either would disable it on
> > apm or always support it because we have no check for apm.
>  
> > Modified: trunk/powersave/daemon/pm_interface.cpp
> > ===================================================================
> > --- trunk/powersave/daemon/pm_interface.cpp 2006-03-02 16:54:42 UTC (rev 
> > 1976)
> > +++ trunk/powersave/daemon/pm_interface.cpp 2006-03-02 20:10:39 UTC (rev 
> > 1977)
> > @@ -977,9 +977,6 @@
> >                     && interface != PS_DBUS_ADMIN_INTERFACE) {
> >                     pDebug(DBG_DIAG, "Suspend to disk is disabled in 
> > config.");
> >                     return REPLY_DISABLED;
> > -           } else if (!(_supported_sleeping_states & ACPI_S4) && 
> > !haveSuspend2()) {
> > -                   pDebug(DBG_DIAG, "Suspend2disk is not supported");
> > -                   return REPLY_HW_NOT_SUPPORTED;
> >             } else {
> >                     pDebug(DBG_INFO, "Client has requested suspend2disk");
> >                     _requested_sleep_state = PSD_SUSPEND2DISK;
> 
> Generally this is correct - all environments should support suspend to
> disk.

I did not remove the check because of this assumption ;-)

>  
> One thing that could happen is, that the kernel was built without support
> for suspend to disk. In this case, we could check if /sys/power/state
> contains "disk" (but better double check, some time ago it always was
> "standby mem disk" regardless of the available options, this changed, my
> machine only contains "mem disk").

I removed the check because it broke apm systems and I needed a quick
solution because of the next release. There is no check if suspend2disk is
supported for apm. The problem is that if you have an apm system, we set
suspend and standy to "supported" without any check. This needs some
further work in the powersave library in getSupportedSleepStates() or
there has to be added a check for apm/acpi in the dbus handler.


Regards,
        Holger
_______________________________________________
powersave-devel mailing list
[email protected]
http://forge.novell.com/mailman/listinfo/powersave-devel

Reply via email to