Bug 14649

Summary: KMS not working as lid is always reported as closed
Product: Drivers Reporter: Martin Bammer (mrb74)
Component: Video(DRI - Intel)Assignee: ykzhao (yakui.zhao)
Severity: high CC: jbarnes, rjw
Priority: P1    
Hardware: All   
OS: Linux   
Kernel Version: 2.6.32-rc8-git3 Subsystem:
Regression: Yes Bisected commit-id:
Bug Depends on:    
Bug Blocks: 13615    
Attachments: dmesg output
kernel configuration
lspci output
dmesg output of 2.6.32-rc8-git3
Output of acpidump
output of dmidecode
try the patch that adds Insyde PC-81005 to ACPI LID quirk list

Description Martin Bammer 2009-11-20 23:00:57 UTC
Created attachment 23848 [details]
dmesg output

With this kernel KMS is not working. Last tested and working kernel is
This bug is similar to 14554.
Comment 1 Martin Bammer 2009-11-20 23:01:48 UTC
Created attachment 23849 [details]
kernel configuration
Comment 2 Martin Bammer 2009-11-20 23:02:57 UTC
Created attachment 23850 [details]
lspci output
Comment 3 Martin Bammer 2009-12-01 23:42:59 UTC
Created attachment 23989 [details]
dmesg output of 2.6.32-rc8-git3

I've compiled the latest kernel with some debugging options enabled for drm and
acpi. The log shows, that the kms problem comes from acpi. The lid is detected
as "closed" and no external vga monitor is connected. A closed lid leads to
"LVDS-1 is disconnected". "VGA-1 is disconnected" and "LVDS-1 is disconnected"
leads to "No connectors reported connected with modes" and then kms fails.
Comment 4 Martin Bammer 2009-12-02 16:22:18 UTC
I've commented out in file i915/intel_lvds.c in function intel_lvds_detect the following 2 lines:
    if (!acpi_lid_open() && !dmi_check_system(bad_lid_status))
        status = connector_status_disconnected;

KMS is now working again. lid problem in acpi is still present.
Comment 5 Jesse Barnes 2009-12-02 19:31:58 UTC
Is your lid always wrong?  We might need to add a quirk for your system...  Yakui will probably ask for a DSDT dump.
Comment 6 Jesse Barnes 2009-12-02 19:32:24 UTC
Yakui, can you take a look?
Comment 7 Martin Bammer 2009-12-04 05:45:46 UTC
Created attachment 24008 [details]
Output of acpidump

Yes, the lid problem is present with all kernels I used.
Currently I'm using kernel and the lid state is always closed.
Comment 8 ykzhao 2009-12-28 16:11:10 UTC
Hi, Martin
    Will you please attach the output of dmidecode on your box?
Comment 9 ykzhao 2009-12-28 16:14:12 UTC
Hi, Martin
    will you please add the boot option of "nomodeset" and attach the following output after the system is booted?
    > cat /proc/acpi/button/lid/LID/state

Comment 10 Martin Bammer 2010-01-15 10:09:03 UTC
I've currently tested it with kernel and "nomodeset".
The result ist the same. Always read as closed.
The strange thing is that an event is emmitted when I close the lid, but the state is always the same.
Comment 11 ykzhao 2010-01-17 12:47:02 UTC
Please attach the output of dmidecode on your box.

Comment 12 Martin Bammer 2010-01-29 23:47:14 UTC
Created attachment 24783 [details]
output of dmidecode
Comment 13 ykzhao 2010-02-22 08:22:09 UTC
Created attachment 25157 [details]
try the patch that adds Insyde PC-81005 to ACPI LID quirk list

will you please try the attached patch and see whether it can work for you?

Comment 14 Martin Bammer 2010-02-25 22:13:11 UTC
Yes this seems to fix the problem. Thnx. Tested with
Comment 15 ykzhao 2010-03-25 01:38:17 UTC
Now the mechanism of LVDS detection by using LID is abandoned in the following commit:
   >commit 6e6c822868f113dabe3c33bdd91e883cc28fa11b
Author: Eric Anholt <eric@anholt.net>
Date:   Wed Mar 17 13:48:06 2010 -0700

    drm/i915: Stop trying to use ACPI lid status to determine LVDS connection.

So the lid quirk is not needed any more. And this bug will be marked as resolved.