Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 458946 - X fails to detect secondary monitor if laptop lid is closed during boot
Summary: X fails to detect secondary monitor if laptop lid is closed during boot
Status: RESOLVED DUPLICATE of bug 459016
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-02-24 07:49 UTC by Mikayel Grigoryan
Modified: 2013-05-20 06:24 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info (emginfo.txt,4.78 KB, text/plain)
2013-02-24 07:49 UTC, Mikayel Grigoryan
Details
lspci -vv (lspci.txt,23.33 KB, text/plain)
2013-02-24 07:51 UTC, Mikayel Grigoryan
Details
xorg.conf (xorg.conf,2.53 KB, text/plain)
2013-02-24 07:51 UTC, Mikayel Grigoryan
Details
dmesg when boots ok (dmesg.txt,51.09 KB, text/plain)
2013-02-26 17:20 UTC, Mikayel Grigoryan
Details
this is «bad dmesg» when it did not open external monitor (dmesg.txt,50.39 KB, text/plain)
2013-02-27 05:57 UTC, Mikayel Grigoryan
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mikayel Grigoryan 2013-02-24 07:49:38 UTC
Created attachment 339918 [details]
emerge --info

External monitor powers off at X startup if laptop lid remains closed during bootloader session.

Since upgrade from kernel 3.5.7 version I am seeing this error of weird nature. 

Whenever I start laptop pressing a button on the docking station following happens. GRUB menu appears on external monitor, timeout expires and kernel starts booting. All text mode stuff is on external monitor, showing ok till it's time to start X server. When X server starts laptop has KDM menu, but external monitor powers off (message is monitor going to sleep) and then there is no way to bring it back: xrandr, or start and stop kdm, unplugging laptop and plugging it back to docking station - external monitor remains switched off till I reboot the system. 

After some trials I've noticed that turning point is whether laptop lid is closed while GRUB did not kick off booting the kernel. If I have laptop lid open during GRUB counter, then X server boots ok on both laptop and external monitor. But when I have laptop lid closed and then open it only after kernel starts booting, X server will not start on the external monitor.

No matter whether xdm loads as service or loaded manually external monitor powers off till reboot.

# Linux gent 3.7.9-gentoo #1 Fri Feb 22 10:35:03 MSK 2013 x86_64 Intel(R) Core(TM) i5 CPU M 540 @ 2.53GHz GenuineIntel GNU/Linux
Comment 1 Mikayel Grigoryan 2013-02-24 07:51:04 UTC
Created attachment 339920 [details]
lspci -vv

Output of lspci command.
Comment 2 Mikayel Grigoryan 2013-02-24 07:51:27 UTC
platform amd64
Comment 3 Mikayel Grigoryan 2013-02-24 07:51:57 UTC
Created attachment 339922 [details]
xorg.conf

xorg.conf
Comment 4 Jeroen Roovers (RETIRED) gentoo-dev 2013-02-26 16:40:04 UTC
Your dmesg output might help here.
Comment 5 Jeroen Roovers (RETIRED) gentoo-dev 2013-02-26 17:10:36 UTC

*** This bug has been marked as a duplicate of bug 459016 ***
Comment 6 Mikayel Grigoryan 2013-02-26 17:20:05 UTC
Created attachment 340198 [details]
dmesg when boots ok

This is dmesg when X starts ok on both monitors
Comment 7 Andreas Sturmlechner gentoo-dev 2013-02-26 18:22:42 UTC
Jeroen: From the description I'm not sure this is related at all.

Mikayel: You can try the second patch ('disable shared panel fitter for pipe') from the upstream link in bug 459016 to see if that changes anything.
Comment 8 Andreas Sturmlechner gentoo-dev 2013-02-26 19:01:39 UTC
There was another patch to a looongstanding bug regarding panel lid handling that fixed the kernel to get external native display resolutions right, but that only landed in 3.8 and would not affect your 3.7 image.

That patch can be found in upstream bug https://bugzilla.kernel.org/show_bug.cgi?id=27622 ('resurrect panel lid status v2') and while I doubt that it brings a solution here, it enables you to play around with the i915.panel_ignore_lid boot parameters:

1  - disable autodetect, return unknown
0  - enable autodetect
-1 - force to disconnected/lid closed
-2 - force to connected/lid open
Comment 9 Mikayel Grigoryan 2013-02-27 05:57:36 UTC
Created attachment 340264 [details]
this is «bad dmesg» when it did not open external monitor

This is «bad dmesg» when it did not open external monitor, but since debug flags are not there can be same as «good dmesg» output.
Comment 10 Mikayel Grigoryan 2013-02-27 06:00:05 UTC
I'll try this patches on freedesktop and kernel upstream but since I am new to this not sure, if I should patch and compile just one file or the whole package.
Comment 11 Andreas Sturmlechner gentoo-dev 2013-02-27 10:37:43 UTC
(In reply to comment #10)
> I'll try this patches on freedesktop and kernel upstream but since I am new
> to this not sure, if I should patch and compile just one file or the whole
> package.

Both patches won't interfere with each other. Also, there's a good chance that the panel fitter patch will land in the next 3.{0,4,8} iterations.
Comment 12 Mikayel Grigoryan 2013-02-28 08:37:04 UTC
I think, bes to wait when this wfix ill go into main or gentoo kernel, and then upgrade.
Comment 13 Andreas Sturmlechner gentoo-dev 2013-02-28 21:49:38 UTC
kernel 3.8.1 will give you both patches, out now
Comment 14 Mikayel Grigoryan 2013-05-20 06:24:50 UTC
This issue is now fixed with kernel 3.8.13-gentoo having "i915.panel_ignore_lid=0" kernel in boot line.