So the reason "force" was added was to do something explicitly. The
user case was:

1) User is on AC. And triggers a Suspend. While on AC, LMT is inactive
2) User moves on the road
3) User settles in a cafe.
4) User resumes laptop at the cafe, on BATT.
5) LMT earlier used to not get triggered, thus it never applied the
battery savings.


But for some time now, since we started relying on udev, this
limitation is no more. I do notice that I still am carrying the "force"
option in the udev rule, but I think that is not needed anymore. I got
away from that dependency some time ago.


There is another one, that the chromium guys had submitted. One where
you could only trigger a module of LMT. But that is a corner case and I
haven't thought much about it.



So, to sum up, I went and verified the behavior.  Suspended the laptop
which on AC, when LMT was:

Laptop mode 
enabled, not active [unchanged]
2015-09-14 / 21:01:34 ♒♒♒  ☺    


Then, unplugged it. And then again resumed it.

At that point, LMT was:

Laptop mode 
enabled, active [unchanged]
2015-09-14 / 21:02:11 ♒♒♒  ☺    



So can you please confirm the behavior on your box. I think that "force
" is not needed anymore.

On Mon, 2015-09-14 at 20:54 +0530, Ritesh Raj Sarraf wrote:
> Hello Tomas,
> 
> Thank you for the bug report.
> 
> On Sat, 2015-09-12 at 16:26 +0200, Tomas Janousek wrote:
> > Since lmt-udev now only runs systemctl reload regardless of what
> > parameters it
> > was run with, laptop mode is no longer forcefully reactivated upon
> > resume.
> > 
> 
> Yes. I'm still wondering how to deal with that. But getting it
> integrated with systemd was my prime target.
> 
> 
> > I worked it around with doing "systemctl restart laptop-mode" in
> > /lib/systemd/system-sleep/laptopmode.sh, but maybe lmt-udev could
> > detect if
> > it's called with "force" and do that itself. Or something.
> 
> 
> Good point. I think this is needed. Because in the udev rule, we
> still
> have the functionality, to call just one single module.
-- 
Ritesh Raj Sarraf | http://people.debian.org/~rrs
Debian - The Universal Operating System

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to