Bug 9761

Summary: unsupported ACPI video device - Samsung R70
Product: ACPI Reporter: Erwan Velu (erwanaliasr1)
Component: OtherAssignee: Zhang Rui (rui.zhang)
Status: CLOSED CODE_FIX    
Severity: normal CC: acpi-bugzilla, ming.m.lin, rui.zhang
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: 2.6.24-rc7 Subsystem:
Regression: --- Bisected commit-id:
Attachments: Acpi dump from a Samsung R70 (Bios UE6)
video fixup
dmesg
ACPI video debug patch
patch: don't throw out an exception
patch: don't throw out an exception

Description Erwan Velu 2008-01-16 00:08:09 UTC
Latest working kernel version: unknown
Earliest failing kernel version:unknown
Distribution: Mandriva 2008.1 Alpha 2
Hardware Environment: Samsung R70 (BIOS UE6)
Software Environment: 64Bit
Problem Description:
When booting up my system, I can see this error in my dmesg.
As requested on the linux-acpi mailing list, I'm opening that bug.

Here come the dmesg :

ACPI Error (utglobal-0126): Unknown exception code: 0xFFFFFFFE [20070126]
Pid: 1952, comm: modprobe Not tainted 2.6.24-laptop-0.rc7.2mdv #1

Call Trace:
 [<ffffffff8038bd2e>] acpi_ut_update_ref_count+0x50/0x9d
 [<ffffffff8038c1d9>] acpi_format_exception+0x2c/0x35
 [<ffffffff8038af73>] acpi_ut_exception+0x25/0x8c
 [<ffffffff803765cc>] acpi_evaluate_integer+0xb6/0xc7
 [<ffffffff881dcd0a>] :video:acpi_video_bus_add+0xcc9/0xce2
 [<ffffffff802c46a8>] ifind+0x58/0xd0
 [<ffffffff8038f2e8>] acpi_device_probe+0x43/0x91
 [<ffffffff803c321c>] driver_probe_device+0x9c/0x1b0
 [<ffffffff803c34e9>] __driver_attach+0xc9/0xd0
 [<ffffffff803c3420>] __driver_attach+0x0/0xd0
 [<ffffffff803c23fd>] bus_for_each_dev+0x4d/0x80
 [<ffffffff803c286c>] bus_add_driver+0xac/0x220
 [<ffffffff8814603c>] :video:acpi_video_init+0x3c/0x5e
 [<ffffffff8026236e>] sys_init_module+0x18e/0x19a0
 [<ffffffff802522f0>] autoremove_wake_function+0x0/0x30
 [<ffffffff8020c34e>] system_call+0x7e/0x83

ACPI Exception (video-1721): UNKNOWN_STATUS_CODE, Cant attach device [20070126]

Steps to reproduce:
Just bootup on that system.
Comment 1 Erwan Velu 2008-01-16 00:09:37 UTC
Created attachment 14476 [details]
Acpi dump from a Samsung R70 (Bios UE6)
Comment 2 Lin Ming 2008-01-16 00:43:29 UTC
Would you please attach the full dmesg?
Comment 3 Zhang Rui 2008-01-16 01:08:30 UTC
Created attachment 14477 [details]
video fixup

Does this patch help?
Comment 4 Erwan Velu 2008-01-16 01:35:08 UTC
I can't post the complete dmesg and test this patch by now, my ssh connexion is down :/
I'll post answers this evening (in 6-7 hours from now).

Thanks,
Erwan
Comment 5 Erwan Velu 2008-01-16 09:59:31 UTC
Created attachment 14482 [details]
dmesg
Comment 6 Erwan Velu 2008-01-16 10:34:08 UTC
I did apply patch (id=14477) on my rc7.

I now have this line in my dmesg, the calltrace I was reporting had disapeared.

ACPI Exception (video-1726): AE_ERROR, Cant attach device [20070126]

How can we go further ?
Comment 7 Erwan Velu 2008-01-17 05:53:55 UTC
is there any plan to make this patch applied on 2.6.24 to avoid this ugly output on the console ?
Comment 8 Zhang Rui 2008-01-17 17:52:42 UTC
I think we can try to push it to 2.6.25.

re comment #6:
could you get the return value of acpi_video_bus_get_one_device?
a one line change may be helpful:
-ACPI_EXCEPTION((AE_INFO, status, "Cant attach device"));
+printk("acpi_video_bus_get_one_device failed, return value is %d\n", status));
Comment 9 Erwan Velu 2008-01-18 00:30:16 UTC
here's the result:
acpi_video_bus_get_one_device failed, return value is -2
Comment 10 Erwan Velu 2008-01-21 01:41:51 UTC
what does this error code really means ?
My keyboard keys for brightness doesn't works, could it be related to that acpi_video bug ?

Erwan
Comment 11 Zhang Rui 2008-01-21 22:38:51 UTC
Created attachment 14528 [details]
ACPI video debug patch

>could it be related to that acpi_video bug ?
Yes.

Please apply this patch on top of the previous one and attach the full dmesg output.
Comment 12 Erwan Velu 2008-01-28 11:10:44 UTC
Here come the results :
ACPI Exception (video-1461): AE_NOT_FOUND, Evaluating _ADR method failed [20070126]
acpi_video_bus_get_one_device failed, return value is -2
Comment 13 Zhang Rui 2008-01-28 17:44:14 UTC
Yes, here is the problem:
ACPI video extension requires a _ADR method for every video devices.
From the acpidump of your laptop, apparently device AMW0 violates
the ACPI spec and that's why we get this exception.
But this should has no impact on your laptop, right?
Comment 14 Erwan Velu 2008-01-29 00:30:42 UTC
yes, it seems it works. The brightness keys works in console, so everything is ok.
I now don't have anymore a oops in my console.

What does _ADR usually provides more ? Should I contact the manufacturer to make him fixing that ?
Comment 15 Zhang Rui 2008-01-30 17:26:16 UTC
Created attachment 14653 [details]
patch: don't throw out an exception
Comment 16 Zhang Rui 2008-01-30 17:27:08 UTC
Created attachment 14654 [details]
patch: don't throw out an exception
Comment 17 Zhang Rui 2008-01-30 17:28:42 UTC
Erwan, please try the patch in comment#16.
you should get a warn message if CONFIG_ACPI_DEBUG is set.
Comment 18 Erwan Velu 2008-02-04 02:34:41 UTC
thx
Comment 19 Erwan Velu 2008-03-05 00:14:17 UTC
is it available upstream now ?
Comment 20 Zhang Rui 2008-03-05 00:44:44 UTC
Not yet.

Len, I think the patch in comment #16 is ready for upstream. :)
Comment 21 Erwan Velu 2008-03-06 00:04:18 UTC
by the way, thanks for the time you spent on it.
Comment 22 Len Brown 2008-06-13 22:01:45 UTC
patch in comment #16 applied to acpi-test
Comment 23 Len Brown 2008-06-23 13:45:20 UTC
shipped in linux-2.6.26-rc7

commit d385c2a85877f0cb785070094edf9a624c090d68
Author: Zhang Rui <rui.zhang@intel.com>
Date:   Sat Jun 14 01:01:18 2008 -0400

    ACPI Exception (video-1721): UNKNOWN_STATUS_CODE, Cant attach device