[Pm-utils] [PATCH 1/2] Enable autodetection and stacking of sleep methods.

Victor Lowther victor.lowther at gmail.com
Tue Sep 16 10:01:04 PDT 2008


On Tue, 2008-09-16 at 11:34 +0200, Tim Dijkstra wrote:
> Op Wed, 10 Sep 2008 17:12:48 -0500
> schreef Victor Lowther <victor.lowther at gmail.com>:
> 
> > On Wed, 2008-09-10 at 22:10 +0200, Danny Kukawka wrote:
> > > On Dienstag, 9. September 2008, Victor Lowther wrote:
> > Well, I never found any of those reasons convincing -- s2ram has its
> internal whitelist and it is a single executable, but those are not
> compelling reasons to me.  If there is something beyond those, I am
> willing to be enlightened.
> 
> It is also rumored to be more stable. Because it will freeze all
> processes except the one that does all the quirk handling.

But right now s2ram does not do that. s2disk and s2both do, but only to
create the memory snapshot.  You will note that I still support s2disk
and s2both.

> > > If you don't have s2ram (which you obviously do), you have no
> > > trouble. And for the rest, which want to use s2ram, they should report
> it to the s2ram maintainers. But this isn't your problem at all. You
> make it only complicated for all these users. They have to revert your
> patch ....
> >
> > My main issue is maintenance related -- pm-utils has to force s2ram to
> do what 99video would do as well in order to handle the quirks that HAL
> asks us to.
> 
> We could also just drop 99video and just use s2ram that would be much
> easier in maintaining. ;)

well, my experience suggests the opposite. Right now s2ram will die
horribly on systems running opensource nv drivers on nvidia g80 class
hardware, because it requires special handling that HAL and pm-utils
take into account, but that s2ram does not.  I think that is one of the
reasons Ubuntu actually dropped support for s2ram.

> > From a maintenance standpoint, that buys me nothing
> > but maintaining two different mechanisms to handle quirks where one
> would do the job.  If it cost nothing to maintain compatibility with
> s2ram (say, by making it take the same commandline parameters that hal
> passes and having it on a release schedule), it might be another matter,
> but right now the easiest way for me to deal with s2ram is to treat it
> as nothing but another mechanism to echo mem
> > > /sys/power/state, and we already handle that part normally.
> 
> There are enough people who want to maintain the uswsusp part in
> pm-utils, they will have to do it anyway for their respective
> distributions.
> 
> So if you add all the work that all pm-utils maintainers have to do, their
> is no maintenance benefit to remove uswsusp support. So I urge you to not
> apply your patch.

Again, this patch series does not remove uswsusp support -- it is
designed to reduce duplicate code and increase flexibility and
maintainability by allowing sleep methods to stack.  In the process, it
forces 99video to handle all the quirks, which made s2ram completly
redundant, so I eliminated s2ram support. s2disk and s2both are still
supported, and they continue to work normally.

As far as maintanance goes, a quick perusal of the git changelogs should
give you an idea about how familiar I am with maintaining pm-utils.

> > > > s2disk and s2both are still supported by this patch series, and now
> we force s2both to run quirkless.  I could have s2ram do the same
> thing, but since all it ends up doing the same as what we already
> do, it is just as easy to fall back to the kernel method.
> 
> s2both needs the quirks too.

Not if 99video handles them, then all s2both has to do is s2disk +
memory sleep instead of power off.

> > > That all is easy to say if you don't use s2ram. And not everyone is
> doing what you do.
> >
> > Right.  And once pci_state and no_fb support is merged, there will be no
> functional difference between 99video and s2ram, except that s2ram has
> an internal whitelist that pm-utils ignores by design in favor of the
> quirks that HAL gives us.
> 
> Until s2ram adds another quirk, which has to be added to hal and
> pmutils...

Well, right now pm-utils and HAL seem to be getting more traction w.r.t
new quirks.  If you are volunteering to get s2ram up to the point where
it does everything 99video does, be my guest.

> grts Tim
> 
> 
> 
> _______________________________________________
> Pm-utils mailing list
> Pm-utils at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/pm-utils
-- 
Victor Lowther
Ubuntu Certified Professional



More information about the Pm-utils mailing list