Bug 13887

Summary: Broken backlight for Acer Aspire 4736z
Product: ACPI Reporter: vaibhav (vaibhav_19842002)
Component: BIOSAssignee: acpi_bios
Status: REJECTED DOCUMENTED    
Severity: normal CC: daavelino, lenb, rui.zhang, yakui.zhao
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: 2.6.31-rc5 Tree: Mainline
Regression: No
Attachments: decompiled dsdt
dmesg output
acpidump
dmidecode
dmi workaround for Acer Aspire 4736Z
dmesg reporting invalid brightness
dmesg output for 2.6.31-rc5
debug patch
dmesg after debug patch
debug patch v2
debug patch v2
dmesg after the patch
patch: disable _BQC once it returns an invalid value
acpidump of my acer timeline 4810TZ-4658
dsdt after latest bios for acer 4736z

Description vaibhav 2009-08-01 10:25:14 UTC
Created attachment 22562 [details]
decompiled dsdt

while changing brightness value in sys or proc doesn't change brightness of the laptop.

# cat /sys/class/backlight/acpi_video0/brightness 
9
# cat /proc/acpi/video/OVGA/DD03/brightness 
levels:  10 20 30 40 50 60 70 80 90 100
current: 100

I changed values to 1 and 10 corresponding in sys and proc, brightness doesn't change.

OS : Debian/unstable

I am attaching decompiled dsdt for my laptop. I am not sure that it is an acpi bug or the video driver bug. Fn+left/right keys change the value of brightness in proc and sys.

# lspci -vxxx -s 00:02.0
00:02.0 VGA compatible controller: Intel Corporation Mobile 4 Series Chipset Integrated Graphics Controller (rev 09) (prog-if 00 [VGA controller])
	Subsystem: Acer Incorporated [ALI] Device 0260
	Flags: bus master, fast devsel, latency 0, IRQ 29
	Memory at 90000000 (64-bit, non-prefetchable) [size=4M]
	Memory at 80000000 (64-bit, prefetchable) [size=256M]
	I/O ports at 60f0 [size=8]
	Expansion ROM at <unassigned> [disabled]
	Capabilities: [90] MSI: Enable+ Count=1/1 Maskable- 64bit-
	Capabilities: [d0] Power Management version 3
00: 86 80 42 2a 07 04 90 00 09 00 00 03 00 00 80 00
10: 04 00 00 90 00 00 00 00 0c 00 00 80 00 00 00 00
20: f1 60 00 00 00 00 00 00 00 00 00 00 25 10 60 02
30: 00 00 00 00 90 00 00 00 00 00 00 00 0b 01 00 00
40: 00 00 00 00 48 00 00 00 09 00 0a 61 b1 6d 51 1f
50: b9 e1 70 03 19 00 00 00 00 00 00 00 00 00 00 7c
60: 00 00 00 00 00 00 02 00 00 00 00 00 00 00 00 00
70: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
90: 05 d0 01 00 0c 30 e0 fe b1 41 00 00 00 00 00 00
a0: 00 00 00 00 09 00 06 20 00 00 00 00 00 00 00 00
b0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
c0: 00 00 00 00 00 00 00 00 00 00 00 00 40 01 00 00
d0: 01 00 23 00 00 00 00 00 00 00 00 00 34 00 00 00
e0: 00 00 00 00 00 00 00 00 00 80 00 1a 41 20 00 00
f0: 0b 19 34 07 cc 00 00 00 a0 0f 09 00 18 c0 a8 7b
Comment 1 vaibhav 2009-08-01 10:30:27 UTC
Created attachment 22563 [details]
dmesg output
Comment 2 ykzhao 2009-08-03 00:59:21 UTC
Will you please also attach the output of acpidump?
Thanks.
Comment 3 Zhang Rui 2009-08-03 01:14:31 UTC
this is a duplicate of bug #13121.
please attach your dmidecode output so that I can generate a dmi patch that enables backlight control on your laptop.
Comment 4 vaibhav 2009-08-03 18:54:33 UTC
Created attachment 22592 [details]
acpidump

Attaching acpidump as requested by ykzhao
Comment 5 vaibhav 2009-08-03 18:57:20 UTC
Created attachment 22593 [details]
dmidecode

Attaching dmidecode output as requested by Zhang Rui.
Comment 6 Zhang Rui 2009-08-04 01:41:58 UTC
Created attachment 22598 [details]
dmi workaround for Acer Aspire 4736Z

please try this patch and see if it helps.
Comment 7 vaibhav 2009-08-04 23:56:24 UTC
initial bug reported was kernel 2.6.30.3, it was mistake on my part. Sorry for that. Today it updated to 2.6.30.4

I am getting this error with or without patch..

ACPI Error (video-0537): Current brightness invalid [20090320]

when i try to change brightness using fn keys i get..

ACPI: Failed to switch the brightness

# cat /proc/acpi/video/*/*/brightness
<not supported>
<not supported>
<not supported>
<not supported>
<not supported>


I tried 2.6.31-rc5 by getting the source and compile but this kernel couldn't boot at all giving device errors, so i wouldn't be able to give any information on that.
Comment 8 vaibhav 2009-08-04 23:58:01 UTC
Created attachment 22605 [details]
dmesg reporting invalid brightness
Comment 9 vaibhav 2009-08-05 16:36:28 UTC
I can confirm for 2.6.31-rc5 that with the following patch issue is not resolved.

In syslog I get :

ACPI Error: Current brightness invalid 20090521 video-538

when i try to change the brightness using fn keys i get :

ACPI: Failed to switch the brightness


# cat /proc/acpi/video/*/*/brightness
<not supported>
<not supported>
<not supported>
<not supported>
<not supported>

/sys/class/backlight directory is empty.

I will attach dmesg out for this kernel.
Comment 10 vaibhav 2009-08-05 16:37:47 UTC
Created attachment 22617 [details]
dmesg output for 2.6.31-rc5
Comment 11 Zhang Rui 2009-08-06 01:03:51 UTC
Created attachment 22620 [details]
debug patch

please apply this patch on top of the previous one and attach the dmesg output after boot.
Comment 12 vaibhav 2009-08-06 03:16:28 UTC
Created attachment 22621 [details]
dmesg after debug patch

I didn't see any debug print msg in dmesg output. To make sure patched module is loaded I modified author name and checked with modinfo for new module and it was fine.
Comment 13 Zhang Rui 2009-08-06 03:32:47 UTC
Created attachment 22622 [details]
debug patch v2

weird.
please try this new debug patch.
Comment 14 Zhang Rui 2009-08-06 03:35:49 UTC
Created attachment 22623 [details]
debug patch v2

refreshed patch that fixes a building error
Comment 15 vaibhav 2009-08-06 17:27:39 UTC
Created attachment 22627 [details]
dmesg after the patch

Print messages were not coming because I didn't generated initrd again and I found it hard way. Sorry for any inconvenience caused due to my ignorance.

In the logs there is one extra print message put by me:

printk("Vai: %d\n", device->backlight); [in function acpi_video_device_lcd_set_level]

which outputs as following:
Vai: 0

So I suspect backlight device is not being detected.
Comment 16 vaibhav 2009-08-07 18:00:24 UTC
I removed all patches and its sort of back to where i had started. after applying that dmi patch backlight device was not being detected. In fact my dsdt is not buggy as reported in 13121. After applying dmi patch my LCD got extreme bright. And removing it got back backlight device and screen is also usable bright.

Issue I had filed initially was that even after reducing backlight 9 to 0 brightness somehow remains same. In xp brightness is clearly visible going low and going high. But thats not the case in linux. In linux backlight deveice detected but brightness remains same no matter increase or decrease values.

dmi patch is not applicable to this model laptop as dsdt is not buggy as reported in 13121. Thanks for all the effort you had put. If you have any idea why brightness doesn't change even after changing values 0-9 in backlight please let me know.
Comment 17 Zhang Rui 2009-08-10 01:23:22 UTC
yes, you are right.
it's not a duplicate of bug #13121.
the symptom is that everything works okay, except that the backlight is not actually changed, right?
Comment 18 Zhang Rui 2009-08-17 06:03:47 UTC
it's weird that the ACPI backlight control methods don't work on this laptop,
although the similar AML code works on many other acer laptops.

vaibhav,
does the problem always exist in every kernel/bios you've tried?

the bios is pretty new, and it fixes the _BQC offset issue which exists in a lot of other laptops.
have you ever upgraded your BIOS?
Comment 19 vaibhav 2009-08-19 16:32:19 UTC
Sorry for late response, I had been away from internet for few days.

I have never updated bios. This is fairly new model and acer seems to have fixed that bios bug(13121) as it appears from the dsdt.

Acer website offers no newer version of bios than present on this laptop.
Comment 20 Zhang Rui 2009-09-28 06:31:44 UTC
Created attachment 23194 [details]
patch: disable _BQC once it returns an invalid value

please try this patch instead.
Comment 21 Zhang Rui 2009-09-28 06:35:34 UTC
wrong patch attached, please ignore comment #20.
Comment 22 Daniel Angelo Avelino 2009-10-06 13:29:47 UTC
Hi guys, 

I have a Acer Aspire Timeline 4810TZ and it has the same problem. 
Could I help you someway?

Thanks
Comment 23 Daniel Angelo Avelino 2009-10-06 13:34:12 UTC
Another info that could be helpful. This problem occurs in the Acer Aspire 5738-6922 too. It is exactly the same symptoms.
Comment 24 Daniel Angelo Avelino 2009-10-08 22:15:56 UTC
Hey! May be it will be a good new!

I solved my problem updating the bios from 1.23 to 1.28 version. 
In my case, this was only a bios problem, not a driver problem itself.

Try it out and post your results. 

Bios updating can be found in: 

http://gd.panam.acer.com/home/
Comment 25 Zhang Rui 2009-10-09 02:49:54 UTC
yes, that's good news.
vaibhav,
can you please upgrade the BIOS and see if the problem still exists?
Comment 26 Zhang Rui 2009-10-26 08:38:31 UTC
please re-open the bug report if the problem still exists after upgrading the BIOS.
Comment 27 vaibhav 2009-12-20 06:48:34 UTC
Updated bios to latest for this model [released on 2009/12/14, bios version 2.06]. Problem is not yet solved for this model [acer aspire 4736z]. One small thing I noted that when grub screen is there then brightness with fn+arrow key works. After it enters into linux and brightness doen't work. acpi=off at boot also makes brightness work, but i don't want to turn off acpi as a solution to this problem.
Comment 28 Zhang Rui 2009-12-21 01:10:11 UTC
please attach the acpidump output after upgrading the BIOS.
Comment 29 Daniel Angelo Avelino 2009-12-21 11:32:22 UTC
Created attachment 24241 [details]
acpidump of my acer timeline 4810TZ-4658

That is it. The acpidumf of my acer 4810TZ-4658.
There are more bios updating on acer site. I might try
if you think it can be useful.

Cheers,

Daniel
Comment 30 Zhang Rui 2009-12-22 01:21:38 UTC
vaibhav,

the problem is really weird. The laptop works exactly in the same way as the laptops in bug 13121, except that it fixes the _BQC offset BIOS bug.
I don't know why the backlight doesn't change when invoking _BQC.
can you please try xrandr to see if it works for you?
Comment 31 vaibhav 2009-12-22 18:17:56 UTC
Created attachment 24257 [details]
dsdt after latest bios for acer 4736z

I am attaching dsdt after bios upgrade.

xrandr doesn't work in default mode, which is kernel mode. It works in native/legacy/combination mode.

-----------------------------
$ xrandr --prop
BACKLIGHT_CONTROL:	kernel
		supported: native       legacy       combination  kernel 
BACKLIGHT: 0 (0x00000000)	range:  (0,9)

$ xrandr --output LVDS --set BACKLIGHT 9

It doesn't change the brightness.
------------------------------
$ xrandr --output LVDS --set BACKLIGHT_CONTROL native
$ xrandr --prop
BACKLIGHT: 2890 (0x00000b4a)	range:  (0,2890)

reducing the value of backlight makes screen brighter.
------------------------------
$ xrandr --output LVDS --set BACKLIGHT_CONTROL legacy
$ xrandr --prop
BACKLIGHT: 208 (0x000000d0)	range:  (0,255)

This is the best mode i can reduce the brightness to near black by increasing value of BACKLIGHT or increase brightness by going below current value 208. In other modes (native/combination) corresponding of legacy BACKLIGHT 208 is the least bright mode. e.g. native.BACKLIGHT 2890 == legacy.BACKLIGHT 208.
---------------------------------
$ xrandr --output LVDS --set BACKLIGHT_CONTROL combination
$ xrandr --prop
BACKLIGHT: 1445 (0x000005a5)	range:  (0,1445)

brightness increases by decreasing value of BACKLIGHT
---------------------------------

I am not clear what different mode mean, I just had googled for how to change BACKLIGHT using xrandr and posted results here. Please let me know if you need something more.
Comment 32 Zhang Rui 2009-12-23 01:00:10 UTC
kernel mode pokes the ACPI backlight sysfs I/F, which doesn't work on your laptop.
legacy mode changes the backlight via poking a PCI register of the VGA controller.

I don't think there is anything we can do in Linux kernel because ACPI video driver runs the AML code exactly as we expected, and exactly the same as it does on other Acer laptops, except that the backlight fails to change on this laptop.

I think you need to use xrandr as a workaround for now, and wish there is a new BIOS released by Acer soon which fixes this issue. :)
Comment 33 Daniel Angelo Avelino 2009-12-23 11:39:15 UTC
Hey, there are a new BIOS update avaiable at Acer page dating from 12/14/2009.
Why not try it?

http://global-download.acer.com/GDFiles/BIOS/BIOS/BIOS_Acer_2.06_A_A.zip?acerid=633963742660462258&Step1=Notebook&Step2=Aspire&Step3=Aspire%204736Z&OS=V10&LC=en&BC=Acer&SC=PA_7

(I don't know if this link will work correctly but, in the official site, you can find the update).

Good luck!!
Comment 34 vaibhav 2009-12-23 14:25:02 UTC
Hi Daniel, I am already using the bios 2.06, please refer my old post :)

Zhang, I am happy that atleast there is a workaround. I would wait if any future BIOS from acer helps. Thanks for all the help and time you gave.