Bug 12106
Summary: | System crashes when setting backlight - Samsung R510 Laptop | ||
---|---|---|---|
Product: | ACPI | Reporter: | Mike Lothian (mike) |
Component: | BIOS | Assignee: | acpi_bios |
Status: | CLOSED DOCUMENTED | ||
Severity: | normal | CC: | acpi-bugzilla, lenb |
Priority: | P1 | ||
Hardware: | All | ||
OS: | Linux | ||
Kernel Version: | 2.6.28-rc | Subsystem: | |
Regression: | No | Bisected commit-id: | |
Attachments: |
Dmesg Output after video modprobed
Backlight grep Video grep 2 levels Video grep 3 levels customized DSDT: new _BCL package Dmesg Output with DSDT customized DSDT Latest dmesg Origional DSDT Dmesg with IRQPOLL Dmesg 40 Debug output of ACPI customized DSDT: more debug info Dmesg 10/12/08 customized DSDT: don't trap when changing backlight customized DSDT |
Description
Mike Lothian
2008-11-26 11:48:27 UTC
Created attachment 19035 [details]
Dmesg Output after video modprobed
Created attachment 19036 [details]
Backlight grep
Created attachment 19037 [details]
Video grep 2 levels
Created attachment 19038 [details]
Video grep 3 levels
When I tried changing the brighness level from 0 to 1 nothing happens when I changed it to 5 the laptop crashed Nothing is shown on the screen when this happens it simply turns black and the laptop reboots Is there any other pieces of info you would like to help diagnose this? so there are two problem here, 1. crashes when setting the brightness level, when X is not started 2. crashes when starting X, with ACPI video driver loaded, right? Created attachment 19042 [details] customized DSDT: new _BCL package the _BCL method on this laptop is buggy. please try this new DSDT. how to override a DSDT can be found at: http://www.lesswatts.org/projects/acpi/overridingDSDT.php let's work on problem 1 first. please do the following test after applying the customized DSDT, 1. cat /proc/acpi/video/GFX0/DD04/brightness 2. set it to a different but not maximum value 3. cat /proc/acpi/video/GFX0/DD04/brightness 4. echo 100 > /proc/acpi/video/GFX0/DD04/brightness 5, does the system still crash? if not, please run "cat /proc/acpi/video/GFX0/DD04/brightness" 6. attach the test result here. Created attachment 19067 [details]
Dmesg Output with DSDT
Attaching this just to make sure I overrode the DSDT properly
tau fireburn # cat /proc/acpi/video/GFX0/DD04/brightness levels: 100 25 35 45 60 70 80 90 current: 35 Trying to change this causes the laptop to crash still and Xorg loading with video module loaded crashes too Is that definitely the right DSDT for my system? this bug is filed against 2.6.28-rc6 What was the most recent Linux release that did not show this problem? There aren't any that don't show this problem This I believe is the first kernel that has both the video detection patch and the Reserve low 64K of RAM on AMI/Phoenix BIOSes Without these patches the module cannot even be loaded with out causeing a crash and simply unpluggin the A/C causes the laptop to crash too. Please see bug 11658 for more details Created attachment 19083 [details]
customized DSDT
please try this one. :)
please set CONFIG_ACPI_DEBUG and boot with acpi.debug_level=0x03
No change laptop still crashes changing values and starting X Created attachment 19093 [details]
Latest dmesg
please attach the content of "/proc/acpi/video/GFX0/DD04/brightness" after applying the customized DSDT. echoing any value to file results in a system crash? irq 16: nobody cared (try booting with the "irqpoll" option) Pid: 0, comm: swapper Tainted: G A 2.6.28-rc6 #14 Call Trace: <IRQ> [<ffffffff802729ce>] 0xffffffff802729ce [<ffffffff80272bc8>] 0xffffffff80272bc8 [<ffffffff802734d5>] 0xffffffff802734d5 [<ffffffff8020eae4>] 0xffffffff8020eae4 [<ffffffff8020c066>] 0xffffffff8020c066 <EOI> [<ffffffff80513210>] 0xffffffff80513210 [<ffffffff80415b6d>] 0xffffffff80415b6d [<ffffffff80415b63>] 0xffffffff80415b63 [<ffffffff8051249a>] 0xffffffff8051249a [<ffffffff8020a2ce>] 0xffffffff8020a2ce [<ffffffff807abc3d>] 0xffffffff807abc3d [<ffffffff807ab36a>] 0xffffffff807ab36a handlers: [<ffffffff804d1540>] Disabling IRQ #16 PCI device 0000:00:02.0 (vga) is routed to irq 16. so, let's fix the irq problem first. what if you boot with irqpoll? does it still hang when starting X? Created attachment 19103 [details]
Origional DSDT
Thought this might be useful
levels: 100 90 25 35 45 60 70 80 90 100 current: 25 Out put of /proc/acpi/video/GFX0/DD04/brightness lines 1-2/2 (END) Still changes when I change /sys/class/backlight ... brighness If I change the above proc to this: levels: 100 90 25 35 45 60 70 80 90 100 current: 50 [ Error writing /proc/acpi/video/GFX0/DD04/brightness: Invalid argument ] and echo 50 > /proc/acpi/video/GFX0/DD04/brightness does nothing and echo 100 > /proc/acpi/video/GFX0/DD04/brightness crashes the laptop Created attachment 19105 [details]
Dmesg with IRQPOLL
(In reply to comment #18) > levels: 100 90 25 35 45 60 70 80 90 100 > current: 25 > > Out put of /proc/acpi/video/GFX0/DD04/brightness lines 1-2/2 (END) > > Still changes when I change /sys/class/backlight ... brighness that's right. there is a 1v1 match between ACPI backlight procfs I/F and sysfs I/F. in order to make the problem easier, please poking only one I/F during the test. > > If I change the above proc to this: > > levels: 100 90 25 35 45 60 70 80 90 100 > current: 50 > how can you change the current value to 50?? only the values listed in the "levels:" line are valid. > > [ Error writing /proc/acpi/video/GFX0/DD04/brightness: Invalid argument ] > > and > > echo 50 > /proc/acpi/video/GFX0/DD04/brightness > > does nothing and > > echo 100 > /proc/acpi/video/GFX0/DD04/brightness > > crashes the laptop > please run: 1.dmesg -c 2.echo 40 > /proc/acpi/video/GFX0/DD04/brightness 3.dmesg > dmesg-40 4.dmesg -c 5.echo 90 > /proc/acpi/video/GFX0/DD04/brightness 6.dmesg >dmesg-90 and attach these two dmesg outputs here. Created attachment 19131 [details]
Dmesg 40
The laptop crashed with 90 I relised that I modprobed video after doing the dmesg -c but before the echo 40 So that dmesg.40 should be empty so, echoing 40 doesn't crash, right? please attach the dmesg output after echoing 40. It's blank what does "blank" mean? is it the same like 90? can the computer still work? or it crashes? can you login via network? does the keyboard still work (can ctrl+atl+del restarts the computer)? please give a more detailed description of the symptom after "echo 40 > /proc/acpi/.../brightness" When I do a dmesg-c echo 40 > brightness My computer carries on working and dmesg is then empty Hope I've explained things better now I'll try loggin on to my laptop from another PC OK I did a tail -f /var/log/messages and tried echoing different values to brightness I echo'd 45 60 & 70 successfully and 80 caused the laptop to crash Nothing appeared in the messages file during any of this testing and the brightness of the laptop's screen didn't change No dmesg output? weird. please attach the content of /sys/module/acpi/parameters/{debug_level, debug_layer} if these two files don't exist, which mean that CONFIG_ACPI_DEBUG is not set. please set it and rebuild the kernel, then attach the dmesg output after "echoing 40" :). Created attachment 19219 [details]
Debug output of ACPI
cd /sys/module/acpi/parameters/
grep . * > ~fireburn/ACPI_Debug
hah, I see. please run "echo 0x03 > /sys/module/acpi/parameters/debug_level" and then attach the dmesg output after "echo 40" I echo'd 0x03 as requested then echod 45 (40 wasn't on the list of available levels) Output is: tau fireburn # dmesg [ACPI Debug] String [0x07] "In _BCM" [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000005 When I then tried to echo 60 the computer crashed On a side related note Xorg now can start whilst the video module is loaded I'm guessing this is due to updates in git mater of libdrm, mesa or xf86-video-intel or possibly the kernel itself But the screen brightness still doesn't change then what about 60 and 70? please attach the dmesg as well Every value that doesn't crash the machine produces the exact same output [ACPI Debug] String [0x07] "In _BCM" [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000005 Each time Created attachment 19234 [details]
customized DSDT: more debug info
that's weird.
this is the piece of AML code:
Store ("In _BCM", Debug)
Divide (Arg0, 0x0A, Local0, Local1)
Store ("Local0", Debug)
Store (Local0, Debug)
we can see that local0 = Arg0%0x0A
Arg0 is the brightness value we want to set, it's really weird if we always get local0 == 0x05 no matter what value we set.
please try this DSDT which can provide more debug info.
Well maybe it's not so weird if you consider the screens actual brightness isn't changing I'll try the DSDT now The output for echo 35, 45 then 25 is: [ACPI Debug] String [0x07] "In _BCM" [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x0000000000000023 [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000005 [ACPI Debug] String [0x07] "In _BCM" [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x000000000000002D [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000005 [ACPI Debug] String [0x07] "In _BCM" [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x0000000000000019 [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000005 I'm ataching the full dmesg Created attachment 19235 [details]
Dmesg 10/12/08
Oh yes forgot to say echo 60 crashed the laptop all right, then I think echoing {60, 70, 80, 90, 100} all crashes the system, while {25, 35, 45} doesn't, right? Created attachment 19236 [details]
customized DSDT: don't trap when changing backlight
you can try this DSDT and see if it still crashes. all right, then I think echoing {60, 70, 80, 90, 100} all crashes the system, while {25, 35, 45} doesn't, right? Yes that's correct Yes it stopped the crashing Here is the output for 35 45 60 70 80 90 100 [ACPI Debug] String [0x07] "In _BCM" [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x0000000000000023 [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000005 [ACPI Debug] String [0x07] "In _BCM" [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x000000000000002D [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000005 [ACPI Debug] String [0x07] "In _BCM" [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x000000000000003C [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x000000000000003C [ACPI Debug] String [0x04] "ALSE" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x04] "ALAF" [ACPI Debug] Integer 0x0000000000000064 [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x06] "Local1" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x07] "In _BCM" [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x0000000000000046 [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x0000000000000046 [ACPI Debug] String [0x04] "ALSE" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x04] "ALAF" [ACPI Debug] Integer 0x0000000000000064 [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x06] "Local1" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x07] "In _BCM" [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x0000000000000050 [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x0000000000000050 [ACPI Debug] String [0x04] "ALSE" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x04] "ALAF" [ACPI Debug] Integer 0x0000000000000064 [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x06] "Local1" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x07] "In _BCM" [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x000000000000005A [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x000000000000005A [ACPI Debug] String [0x04] "ALSE" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x04] "ALAF" [ACPI Debug] Integer 0x0000000000000064 [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x06] "Local1" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x07] "In _BCM" [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x0000000000000064 [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x04] "Arg0" [ACPI Debug] Integer 0x0000000000000064 [ACPI Debug] String [0x04] "ALSE" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x04] "ALAF" [ACPI Debug] Integer 0x0000000000000064 [ACPI Debug] String [0x06] "Local0" [ACPI Debug] Integer 0x0000000000000000 [ACPI Debug] String [0x06] "Local1" [ACPI Debug] Integer 0x0000000000000000 it's a SMI call that causes the crash. it's weird that it's an IGD OpRegion BIOS. but the backlight control(_BCM) doesn't go via IGD OpRegion. so first please check if there is any BIOS update. if not, please try the customized DSDT attached and see if it can work for you. well, by re-reading your BIOS, it seems that the AML code is not well written, and there are too many places that need to be fixed. let's try to upgrade your BIOS first. :p I have the lastest BIOS version http://www.samsung.com/uk/support/download/supportDown.do?group=itbusiness&type=notebookcomputers&subtype=rseries&model_nm=NP-R510&disp_nm=R510&language=&cate_type=all&dType=D&mType=FM&vType=R&prd_ia_cd=05010400 I have messaged Samsung previously to let them know they have a BIOS problem but they weren't interested :-( Has there been any progress with this? no. As we found that the crash is caused by a SMI call, while SMI is transparent to OS. I have no idea how to debug this any more. Knowing if the SMI is invoked in windows would be help, but unfortunately we can not get this info. Created attachment 19323 [details]
customized DSDT
can you please try this customized DSDT file and see if the system still crashes?
Values of 60 and above still crash the system and there is no change in brightness Is there any further progress with this? well, IMO, this is a BIOS bug to me, and I'm afraid we can not fix it in Linux kernel. please try boot option "acpi_backlight=vendor", and see if there is any backlight I/F available in /sys/class/backlight/ If it still doesn't work, please try a 2.6.26 stable kernel, there should be more than one backlight interfaces in /sys/class/backlight/. try all of them and see if anyone works. Mike, I'd prefer to close this bug as this is a BIOS bug to me. could you please try the test I mentioned in comment #52 please? No backlights are listed with that acpi option Unfortunately older kernels didn't work due to the other bug. I could try patching an older kernel to see if that makes a difference so 2.6.26 doesn't work on your laptop? ping Mike Apologies No anything before 2.6.28 doesn't work without ACPI=OFF at boot time > No anything before 2.6.28 doesn't work without ACPI=OFF at boot time
sorry, do you mean nothing or everything before 2.6.28 work with ACPI enabled?
ping Mike. close this bug as there is no response from the bug reporter. please re-open it if the problem still exists and you can provide the info requested in comment #58 OK I have a work around for the crashing, adding mem=4096M to the boot parms gets my laptop working (as in not crashing) but I loose 1GB of RAM Screen brightness control still doesn't work however but I'm hoping that may be fixable now the crashing has stopped Reopening hmm, could you answer the question in comment #58? There are quiet a lot of answers to #58 The laptop was never tested with anything prior to 2.6.28, it's likely to work with MEM=4096M being passed now or running a 32bit kernel but I didn't know this at the time, only passing ACPI=OFF would stop it from crashing I'm still pestering samsung for a real bios fix (they fixed the issue in the R560) please try the patch at http://patchwork.kernel.org/patch/38246/ and see if it helps. Ping... Unfortunately the same bad behaviour can be observed *** This bug has been marked as a duplicate of bug 11658 *** Quite ironic that after all this time it is indeed the same bug Good news thanks to Windows 7 requiring 64bit to get the Win7 seal of approval Samsung has now put out an updated (and fixed) BIOS!! |