You are not logged in.

#1 2011-04-17 16:09:59

Sowinof
Member
Registered: 2011-04-16
Posts: 3

Changing Backlight Brightness

This is a bit of a beginner problem I've run into that I'm determined to fix somehow.

[enoch@arch-ACER ~]$ uname -impr
2.6.38-ARCH i686 Pentium(R) Dual-Core CPU T4400 @ 2.20GHz GenuineIntel
[enoch@arch-ACER ~]$ lspci -v | grep VGA
00:02.0 VGA compatible controller: Intel Corporation Mobile 4 Series Chipset Integrated Graphics Controller (rev 09) (prog-if 00 [VGA controller])

Actual laptop: Acer Aspire 5732Z with Intel GMA 4500M

The problem is I get a blank screen when booting with KMS enabled (i915,modeset=1). It works fine without KMS. I've tried lots of stuff, like downgrading xf86-video-intel, but nothing seemed to help. Recently though I learned that there was no backlight, which explains why I thought the screen was totally blank.

So I booted without KMS and tried to raise the brightness:

[root@arch-ACER ~]# /sys/class/backlight
bash: /sys/class/backlight: Is a directory
[root@arch-ACER ~]# cd !!
cd /sys/class/backlight
[root@arch-ACER backlight]# ls
[root@arch-ACER backlight]#

ls returned nothing, which makes me assume it was empty, which was weird because the the backlight was working perfectly. Does anyone know what exactly is going on, and how I can get the backlight working?

Edit: Now there suddenly seems to be a director in /sys/class/backlight:

[root@arch-ACER backlight]# ls
acpi_video0
[root@arch-ACER backlight]# cd acpi_video0
[root@arch-ACER acpi_video0]# ls
actual_brightness  brightness  max_brightness  subsystem
bl_power           device      power           uevent
[root@arch-ACER acpi_video0]# nano actual_brightness
[root@arch-ACER acpi_video0]# nano brightness
[root@arch-ACER acpi_video0]#

actual_brightness and brightness have the same amount. When I boot without KMS, it's 7 and clearly visible. When I boot with KMS, though, it's 0 (no brightness).

Can anyone help with the actual_brightness being 0?

Last edited by Sowinof (2011-04-17 16:46:27)

Offline

#2 2011-05-02 08:03:06

Sara
Member
From: USA
Registered: 2009-07-09
Posts: 219
Website

Re: Changing Backlight Brightness

Your question actually isn't a newbie question--it's a kernel bug, which I made a thread for in the Pacman forum when the faulty upgrade (2.6.38 up from 2.6.37.6) was released. Here is the kernel bug report:

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

The good news is that someone recently re-opened this bug report, which was the right thing to do, as we're on 2.6.38.4 and this problem still hasn't been fixed. Also, the person who introduced the faulty commit (no offense on the person), has supplied a patch which he thought might help. The bad news is that the supplied patch does not work on my machine (I just tried it, by using the ABS to obtain a PKGBUILD of the 2.6.38.4 Arch kernel, and adding a line for the brightness patch. Also, since I was compiling the new kernel from a stable kernel (my backup of 2.6.37.5), I also added the line "make localmodconfig" after line 55 in the default PKGBUILD, which causes only modprobed modules to be enabled in the kernel, but if you try to compile it from the commandline in 2.6.38 (presuming you used the nomodeset grub parameter), I'm not sure if there are any modules you would be missing because KMS is not enabled. Nevertheless, I thought to add this tip because it greatly speeds up kernel compilation, so it's an easy way to check if the patch actually works without having to suffer an hour+ for the kernel to compile.

Here is the patch (maybe it will work for you):

diff --git a/drivers/gpu/drm/i915/intel_panel.c b/drivers/gpu/drm/i915/intel_panel.c
index a06ff07..bf61e02 100644
--- a/drivers/gpu/drm/i915/intel_panel.c
+++ b/drivers/gpu/drm/i915/intel_panel.c
@@ -116,11 +116,13 @@ static int is_backlight_combination_mode(struct drm_device *dev)
 {
    struct drm_i915_private *dev_priv = dev->dev_private;
 
+#if 0
    if (INTEL_INFO(dev)->gen >= 4)
        return I915_READ(BLC_PWM_CTL2) & BLM_COMBINATION_MODE;
 
    if (IS_GEN2(dev))
        return I915_READ(BLC_PWM_CTL) & BLM_LEGACY_MODE;
+#endif
 
    return 0;
 }

Though if I were you I would use a text web browser to access the patch, save the RAW of that page, and delete the non-patch lines. This should prevent patch errors due to spacing.

Maybe you'll like to also add comments at the kernel bugtracker for this issue (I supplied the link earlier), with your feedback.

Last edited by Sara (2011-05-02 08:05:10)


Registed Linux User 483618

Offline

Board footer

Powered by FluxBB