Bug 522616 - screen is not locked after resume from suspend
screen is not locked after resume from suspend
Status: CLOSED RAWHIDE
Product: Fedora
Classification: Fedora
Component: gnome-power-manager (Show other bugs)
rawhide
All Linux
low Severity medium
: ---
: ---
Assigned To: Richard Hughes
Fedora Extras Quality Assurance
:
Depends On:
Blocks: F12Target
  Show dependency treegraph
 
Reported: 2009-09-10 16:28 EDT by Michal Nowak
Modified: 2013-03-07 21:06 EST (History)
6 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-09-23 23:16:49 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:


Attachments (Terms of Use)

  None (edit)
Description Michal Nowak 2009-09-10 16:28:28 EDT
Description of problem:

In F-11 the screen used to be locked after resume from suspend, now, with current Rawhide, it's not. I am just blind-guessing component.

Version-Release number of selected component (if applicable):

gnome-screensaver-2.27.0-10.fc12.i686
gnome-power-manager-2.27.92-1.fc12.i686

How reproducible:

always

Steps to Reproduce:
1. Suspend
2. Resume

Additional info:

This is Intel 855GM graphics.
Comment 1 Matthias Clasen 2009-09-11 16:16:19 EDT
Richard, any idea what happened with this ?
Comment 2 Matthias Clasen 2009-09-12 23:44:19 EDT
I looked into this, and the upshot is that

1) gnome-power-manager needs to be fixed to actually connect to gnome-screensaver. There is two problems: a) GS_LISTENER_PATH ought to be "/"
b) gpm_screensaver_init needs to have the commented out code reinstated

This fixes Fn-F3 to lock the screen again.

2) gnome-session is not talking to gpm anymore, but instead calls directly into DKp. Thus no attempt is made to lock the screen. I don't know how this is supposed to be fixed.
Comment 3 Richard Hughes 2009-09-13 04:48:09 EDT
(In reply to comment #2)
> 1) gnome-power-manager needs to be fixed to actually connect to
> gnome-screensaver. There is two problems: a) GS_LISTENER_PATH ought to be "/"

Urgh. When did this change? It used to work. I've changed it to "/" in git master.

> b) gpm_screensaver_init needs to have the commented out code reinstated

You sure? That code wasn't used anywhere.

> 2) gnome-session is not talking to gpm anymore, but instead calls directly into
> DKp. Thus no attempt is made to lock the screen. I don't know how this is
> supposed to be fixed.  

gnome-session needs to Lock() on gnome-screensaver. Long term gnome-power-manager is going to be further downsized, and possibly added as a gsd plugin. As a plugin is won't be doing it's own suspend anyway, it'll just go through gnome-session.

I can work on a patch to gnome-session on Monday if you wish.
Comment 4 Richard Hughes 2009-09-13 06:18:13 EDT
(In reply to comment #3)
> > b) gpm_screensaver_init needs to have the commented out code reinstated
> 
> You sure? That code wasn't used anywhere.

Nope, I misunderstood the code, you're correct. I'll uncomment this now.

I've also tried to add in some self tests for this functionality, but, alas the AuthenticationRequestBegin and AuthenticationRequesEnd functionality has been removed from gnome-screensaver:

commit 4cb1799f0eac4ca0c28c51a10886f15ab683728d
Author: William Jon McCann <jmccann@redhat.com>
Date:   Mon Jan 19 00:54:18 2009 +0000

    Remove obsolete signals and properties.
    
    2009-01-18  William Jon McCann  <jmccann@redhat.com>
    
        * src/gs-listener-dbus.c (listener_set_session_idle_internal),
        (listener_get_property), (do_introspect),
        (listener_dbus_handle_session_message):
        * src/gs-monitor.c (disconnect_manager_signals),
        (connect_manager_signals):
        Remove obsolete signals and properties.

Nobody supplied any patches to g-p-m or even told me about the change. Brilliant. This breaks fixes such as #350291 where the user uses a smartcard to login and the screen needs to be turned on manually as it's been turned off due to inactivity.

I've ifdefd the AuthenticationRequestBegin signal handling in g-p-m for now, but I'll expect bugzillas about the fact that it worked in in earlier releases but not in F12, as I assume this was not tested.

I'm getting a bit annoyed about all this, especially when g-p-m fails in usability respects and people very quickly tell me things are not good enough.
Comment 5 Matthias Clasen 2009-09-13 21:43:42 EDT
> I can work on a patch to gnome-session on Monday if you wish.

I'd appreciate that. I think shipping the gnome-session ported to DK-d with this regression would look a bit foolish.

> I've ifdefd the AuthenticationRequestBegin signal handling in g-p-m for now,
> but I'll expect bugzillas about the fact that it worked in in earlier releases
> but not in F12, as I assume this was not tested.

tbh, I have no idea what this is about. A way to programmatically trigger the lock dialog ? We probably need to talk to Jon about this...
Comment 6 Richard Hughes 2009-09-14 07:23:46 EDT
(In reply to comment #5)
> > I can work on a patch to gnome-session on Monday if you wish.
> 
> I'd appreciate that. I think shipping the gnome-session ported to DK-d with
> this regression would look a bit foolish.

Filed with a patch in https://bugzilla.gnome.org/show_bug.cgi?id=595154

> > I've ifdefd the AuthenticationRequestBegin signal handling in g-p-m for now,
> > but I'll expect bugzillas about the fact that it worked in in earlier releases
> > but not in F12, as I assume this was not tested.
> 
> tbh, I have no idea what this is about. A way to programmatically trigger the
> lock dialog ? We probably need to talk to Jon about this...  

Well, it's a hint to g-p-m that we are no longer idle and we need to turn on the screen, even though no keyboard or mouse activity was detected.
Comment 7 Michal Nowak 2009-09-16 07:06:57 EDT
Just to report it got fixed yesterday, screensaver popped up after 1 m and system was moved to suspend after 10 m.
Comment 8 Michal Nowak 2009-09-18 05:11:10 EDT
(In reply to comment #7)
> Just to report it got fixed yesterday, screensaver popped up after 1 m and
> system was moved to suspend after 10 m.  

Non-sence, I mixed it up with some other bug.
Comment 9 Matthias Clasen 2009-09-23 23:16:49 EDT
Fixed in gnome-session-2.28.0

Note You need to log in before you can comment on or make changes to this bug.