SRU: For skylake system, u-s-d cause a black screen when resume from S3 via Lid Close

Bug #1471708 reported by Tim Chen
12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OEM Priority Project
Fix Released
Critical
Unassigned
Trusty
Fix Released
Critical
Unassigned
unity-settings-daemon (Ubuntu)
Fix Released
High
Alberto Milone
Trusty
Fix Released
High
Unassigned

Bug Description

OEM LP private bug: https://bugs.launchpad.net/bugs/1466441

Title: Sometimes system turns a black screen when resume from S3 via Lid Close

[Impact]

Sometimes system turns a black screen when resume from S3 via Lid Close
It only has cursor on screen but still can switch to tty1.
Failure rate ~ 1/5

[Test Case]
1. install Ubuntu 14.04.2 & 3.19+ kernel and boot to OS
2. Close the lid
3. Open the lid
4. check the display status

Expected results: System should resume to the log in screen when open the lid

Actual results:
System sometimes fails to resume back to the log in screen but blackscreen instead.
(Failure rate~ 1/5)

[Regression Potential]
Low. Killing touchscreen mapping after 3 seconds should not affect any other input device.

Details:

unity-settings-deamon will call "xinput --map-to-output 11 eDP1" at background,
and it's being blocked so only cursor will show on screen.

1. Switch to tty1 when this happen
2. Login with user account on tty1.
3. Use "DISPLAY=:0 xrandr " on commandline you'll see it's being blocked.

Since xinput is being blocked for some unknown reason (in gdb it shows polling on xcb_connect_to_fd() in XOpenDisplay() ),

a possible workaround is to set a timeout for xinput in u-s-d.

=== modified file 'plugins/xrandr/gsd-xrandr-manager.c'
--- plugins/xrandr/gsd-xrandr-manager.c 2014-06-05 11:56:15 +0000
+++ plugins/xrandr/gsd-xrandr-manager.c 2015-07-01 08:59:56 +0000
@@ -2199,7 +2199,7 @@
         if (gnome_rr_output_info_is_active(output)) {
                 g_debug ("Mapping touchscreen %d onto output %s",
                          device_id, name);
- sprintf (command, "xinput --map-to-output %d %s",
+ sprintf (command, "timeout 3s xinput --map-to-output %d %s",
                          device_id, name);
                 status = system (command);
         }

Tim Chen (timchen119)
Changed in oem-priority:
importance: Undecided → Critical
Changed in unity-settings-daemon (Ubuntu):
status: New → Triaged
importance: Undecided → High
assignee: nobody → Alberto Milone (albertomilone)
Revision history for this message
Alberto Milone (albertomilone) wrote :

I created a merge request of Tim's branch into the 14.04 branch.

Changed in unity-settings-daemon (Ubuntu):
status: Triaged → In Progress
description: updated
summary: - For skylake system, u-s-d cause a black screen when resume from S3 via
- Lid Close
+ SRU: For skylake system, u-s-d cause a black screen when resume from S3
+ via Lid Close
description: updated
Revision history for this message
Alberto Milone (albertomilone) wrote :
Revision history for this message
Tim Chen (timchen119) wrote :

@Alberto

It was originally a quick workaround for the possible race condition so could you help to modify the code with what Iain had suggested? Totally agree that making it asynchronous, adding more verbose log and finding out the root cause are better ways to fix this issue.

Revision history for this message
Alberto Milone (albertomilone) wrote :

I'm working on it, and I hope to have something available for testing soon.

Revision history for this message
Alberto Milone (albertomilone) wrote :

I wrote a fix, the Desktop team reviewed it, and they requested some changes before they merge my code, as you can see in the following code review:
https://code.launchpad.net/~albertomilone/unity-settings-daemon/non-blocking-touch-mapping-wily/+merge/266248

I am still working to adjust my code to their requests.

Ara Pulido (ara)
Changed in oem-priority:
status: New → Triaged
Changed in unity-settings-daemon (Ubuntu Trusty):
status: New → In Progress
Revision history for this message
Alberto Milone (albertomilone) wrote :

Another update: yesterday I submitted my new code for a review

Revision history for this message
Alberto Milone (albertomilone) wrote :

@sru-team: my code should be in trusty-proposed now. Please approve it for testing.

P.S. the code is also in wily-proposed

Revision history for this message
Chris J Arges (arges) wrote : Please test proposed package

Hello Tim, or anyone else affected,

Accepted unity-settings-daemon into trusty-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/unity-settings-daemon/14.04.0+14.04.20150825-0ubuntu1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in unity-settings-daemon (Ubuntu Trusty):
status: In Progress → Fix Committed
tags: added: verification-needed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package unity-settings-daemon - 15.04.1+15.10.20150825-0ubuntu1

---------------
unity-settings-daemon (15.04.1+15.10.20150825-0ubuntu1) wily; urgency=medium

  [ Alberto Milone ]
  * Make touchscreen mapping non-blocking, and kill it if it takes more
    than 3 seconds; finally, in case of failure, try again after a few
    seconds. This helps on resume from S3 (LP: #1471708). (LP: #1471708)

 -- CI Train Bot <email address hidden> Tue, 25 Aug 2015 09:09:33 +0000

Changed in unity-settings-daemon (Ubuntu):
status: In Progress → Fix Released
Mathew Hodson (mhodson)
Changed in unity-settings-daemon (Ubuntu Trusty):
importance: Undecided → High
Revision history for this message
Tammy Yang (wanchingy) wrote :

Issue has been verified on one Dell platform.
Tried open/close lid to suspend and resume for more than 20 times, cannot re-produce the issue.

Since the HW has not yet been shipped, more details please see https://bugs.launchpad.net/somerville/+bug/1466441/comments/53

tags: added: verification-done
removed: verification-needed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package unity-settings-daemon - 14.04.0+14.04.20150825-0ubuntu1

---------------
unity-settings-daemon (14.04.0+14.04.20150825-0ubuntu1) trusty; urgency=medium

  [ Alberto Milone ]
  * Make touchscreen mapping non-blocking, and kill it if it takes more
    than 3 seconds; finally, in case of failure, try again after a few
    seconds. This helps on resume from S3 (LP: #1471708). (LP: #1471708)

 -- CI Train Bot <email address hidden> Tue, 25 Aug 2015 09:20:43 +0000

Changed in unity-settings-daemon (Ubuntu Trusty):
status: Fix Committed → Fix Released
Revision history for this message
Timo Aaltonen (tjaalton) wrote : Update Released

The verification of the Stable Release Update for unity-settings-daemon has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Ara Pulido (ara)
Changed in oem-priority:
status: Triaged → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.