https://bugzilla.kernel.org/show_bug.cgi?id=100441

            Bug ID: 100441
           Summary: Screen flickers when changing brightness using keys
                    (Dell laptop, intel i915 backlight)
           Product: ACPI
           Version: 2.5
    Kernel Version: >= 3.17
          Hardware: x86-64
                OS: Linux
              Tree: Mainline
            Status: NEW
          Severity: normal
          Priority: P1
         Component: Power-Video
          Assignee: [email protected]
          Reporter: [email protected]
        Regression: No

Created attachment 180851
  --> https://bugzilla.kernel.org/attachment.cgi?id=180851&action=edit
dmidecode

Pressing the brightness buttons on a Dell Vostro V131 notebook (Intel graphics,
i915) causes the screen to flicker. I am using Arch Linux, Linux 4.0.5 and
plain X without desktop environment. I tested kernel 3.16.4, 3.16.7, 3.17.1 and
3.18.16 as well.

Flickering startet from Kernel 3.17.1 and seems to be some kind of regression
by commit 8ab58e8e7e097bae5fe39cbc. For reference, see:
http://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=8ab58e8e7e097bae5fe39cbc

That commit introduced a 100ms delay after applying a backlight change to let
userspace applications deal with it. As I am not using a desktop environment or
other userspace software to control backlight brightness, the kernel processes
the change on its own.

So far I've tracked it down to the hardware sending two Button/ACPI events. The
logs below are produced by pressing brightness up and brightness down once:

# echo 6 >/sys/module/drm/parameters/debug
# dmesg -w
[ 5636.050982] [drm:asle_set_backlight] bclp = 0x8000000f
[ 5636.050993] [drm:asle_set_backlight] updating opregion backlight 15/255
[ 5636.051002] [drm:intel_panel_actually_set_backlight] set backlight PWM = 287
[ 5636.149849] [drm:asle_set_backlight] bclp = 0x8000007a
[ 5636.149869] [drm:asle_set_backlight] updating opregion backlight 122/255
[ 5636.149876] [drm:intel_panel_actually_set_backlight] set backlight PWM =
2336
[ 5636.708213] [drm:asle_set_backlight] bclp = 0x8000000f
[ 5636.708224] [drm:asle_set_backlight] updating opregion backlight 15/255
[ 5636.708231] [drm:intel_panel_actually_set_backlight] set backlight PWM = 287
[ 5636.806192] [drm:asle_set_backlight] bclp = 0x8000006b
[ 5636.806206] [drm:asle_set_backlight] updating opregion backlight 107/255
[ 5636.806216] [drm:intel_panel_actually_set_backlight] set backlight PWM =
2049

# acpi_listen
video/brightnessup BRTUP 00000086 00000000 K
video/brightnessup BRTUP 00000086 00000000
video/brightnessdown BRTDN 00000087 00000000 K
video/brightnessdown BRTDN 00000087 00000000

The first request always sets the backlight to 15/255, the second request sets
it to the desired value. Before 3.17, both changes were processed as well, but
it was not noticeable. With a 100ms delay, it makes the screen flicker by going
to low brightness first and to the desired brightness 100ms later.

The behaviour differs if the display is at full brightness. The unintended
first brightness change sets the brightness to 255/255, but only if the scren
was at 255/255 before. Log below from pushing brightness up and brightness down
consecutively at max brightness.

# dmesg -w
[ 6278.380826] [drm:asle_set_backlight] bclp = 0x800000ff
[ 6278.380831] [drm:asle_set_backlight] updating opregion backlight 255/255
[ 6278.380834] [drm:intel_panel_actually_set_backlight] set backlight PWM =
4882
[ 6278.479520] [drm:asle_set_backlight] bclp = 0x800000ff
[ 6278.479524] [drm:asle_set_backlight] updating opregion backlight 255/255
[ 6278.479528] [drm:intel_panel_actually_set_backlight] set backlight PWM =
4882
[ 6279.071946] [drm:asle_set_backlight] bclp = 0x800000ff
[ 6279.071961] [drm:asle_set_backlight] updating opregion backlight 255/255
[ 6279.071972] [drm:intel_panel_actually_set_backlight] set backlight PWM =
4882
[ 6279.169386] [drm:asle_set_backlight] bclp = 0x800000e5
[ 6279.169395] [drm:asle_set_backlight] updating opregion backlight 229/255
[ 6279.169401] [drm:intel_panel_actually_set_backlight] set backlight PWM =
4384

I tried disabling the brigness switch control of the ACPI video module by:
# echo 0 >/sys/module/video/parameters/brightness_switch_enabled

That disables the correctly working brightness control, pushing any of the
brightness buttons now sets the brightness to 15/255. Brightness can still be
controlled by
# echo 1000 >/sys/class/backlight/intel_backlight/brightness
but is reset to 15/255 when pushing a button.
This makes me wonder if something else than video.ko processes that request.

I suppose we need to track down the source of the unwanted acpi event and add a
quirk to ignore it on this specific computer model.

-- 
You are receiving this mail because:
You are watching the assignee of the bug.

------------------------------------------------------------------------------
Monitor 25 network devices or servers for free with OpManager!
OpManager is web-based network management software that monitors 
network devices and physical & virtual servers, alerts via email & sms 
for fault. Monitor 25 devices for free with no restriction. Download now
http://ad.doubleclick.net/ddm/clk/292181274;119417398;o
_______________________________________________
acpi-bugzilla mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/acpi-bugzilla

Reply via email to