Suspend and NetworkManager
Richard Hughes
hughsient at gmail.com
Tue Jan 10 07:58:18 PST 2006
Currently, in CVS HAL the suspend() method calls
hal-system-power-suspend which for RedHat and Fedora calls pm-suspend.
pm-suspend currently does a DBUS message to NetworkManager to tell it to
suspend, wakeup, and lots of other clever stuff.
gnome-power-manager also does a DBUS message to NetworkManager, just to
make sure that the interface goes down for non-redhat platforms (and the
second DBUS call by pm-suspend is just ignored.)
Now that n-m is in common use (not just fedora and redhat) why shouldn't
we remove the NetworkManager sleep/wake code from pm-suspend and g-p-m,
and place it directly in the hal-system-power-suspend and
hal-system-power-hibernate files. e.g.
dbus-send --system \
--dest=org.freedesktop.NetworkManager \
/org/freedesktop/NetworkManager \
org.freedesktop.NetworkManager.wake
There is no delay for systems that are not using n-m.
The other distro-specific bits in pm-suspend should remain (like
starting and stopping services) but I think the n-m case has to be more
generic.
Then other stuff like gnome-session can call the HAL methods directly,
without worrying about n-m, and also all the other distros don't have to
hack together scripts to do this too.
Comments?
Thanks, Richard.
More information about the hal
mailing list