<html>
<head>
<base href="https://bugs.freedesktop.org/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Priority</th>
<td>medium
</td>
</tr>
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW --- - Systemd sets wrong screen brightness resuming from suspend on Optimus enabled laptop"
href="https://bugs.freedesktop.org/show_bug.cgi?id=79159">79159</a>
</td>
</tr>
<tr>
<th>Assignee</th>
<td>systemd-bugs@lists.freedesktop.org
</td>
</tr>
<tr>
<th>Summary</th>
<td>Systemd sets wrong screen brightness resuming from suspend on Optimus enabled laptop
</td>
</tr>
<tr>
<th>QA Contact</th>
<td>systemd-bugs@lists.freedesktop.org
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux (All)
</td>
</tr>
<tr>
<th>Reporter</th>
<td>poeticrpm@gmail.com
</td>
</tr>
<tr>
<th>Hardware</th>
<td>x86-64 (AMD64)
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Component</th>
<td>general
</td>
</tr>
<tr>
<th>Product</th>
<td>systemd
</td>
</tr></table>
<p>
<div>
<pre>On systems with only one graphics card (or with Optimus disabled in BIOS),
systemd works correctly: whatever the screen brightness when suspend is
initiated is the screen brightness that is set upon resuming from suspend.
If the system has Optimus enabled however, resuming from suspend always sets
the backlight to 100%. This is because systemd is apparently looking at the
wrong device in /sys/class/backlight (the device of the nvidia card, not the
intel card which controls the backlight).
Consider the following contents of /sys/class/backlight on a system with
Optimus disabled:
$ ls /sys/class/backlight
acpi_video0 intel_backlight
Now consider the results of a system with Optimus enabled:
$ ls /sys/class/backlight
acpi_video0 acpi_video1 intel_backlight
In the second case, if I manually:
echo "50" > /sys/class/backlight/acpi_video1/brightness
the laptop will resume from suspend with 50% screen brightness (regardless of
what the brightness is actually set at).
I believe the solution is to have either a config option in logind.conf for
which device to use in /sys/class/backlight, or for systemd to determine this
automatically.
Information:
Lenovo Thinkpad T530
EFI setup
Arch Linux (64bit) (Fully up to date as of this posting)
systemd version: 212 (or: 212-3 in the Arch repos)
lspci | grep "VGA" (Optimus enabled)
00:02.0 VGA compatible controller: Intel Corporation 3rd Gen Core processor
Graphics Controller (rev 09)
01:00.0 VGA compatible controller: NVIDIA Corporation GF108M [NVS 5400M] (rev
a1)
I am not sure whether this is a regression or if it has just never came up- I
only recently starting using Optimus (having disabled it via BIOS before) so..
If you need any other information, just ask :)</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the QA Contact for the bug.</li>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>