Bug 353637 - Cannot enable second monitor in Display Configuration
Summary: Cannot enable second monitor in Display Configuration
Status: RESOLVED UNMAINTAINED
Alias: None
Product: KScreen
Classification: Plasma
Component: common (show other bugs)
Version: 5.4.3
Platform: openSUSE Linux
: NOR major
Target Milestone: ---
Assignee: Daniel Vrátil
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-10-07 06:24 UTC by Robby Engelmann
Modified: 2022-05-12 11:12 UTC (History)
8 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Screenshot with outdated KCM information (compare with xrandr output) (46.03 KB, image/png)
2015-10-09 12:33 UTC, Maciej Mrozowski
Details
xrandr output (11.63 KB, text/plain)
2015-10-09 12:34 UTC, Maciej Mrozowski
Details
.local/share/kscreen/81c0a2e36c78e995413d6ae4edf828be (1.48 KB, text/plain)
2015-10-09 12:37 UTC, Maciej Mrozowski
Details
.local/share/kscreen/e662a3070e33d8d4e76edd1f889acddf (1.29 KB, text/plain)
2015-10-09 12:40 UTC, Maciej Mrozowski
Details
kscreen-console output (11.94 KB, text/plain)
2015-10-09 12:51 UTC, Maciej Mrozowski
Details
dmesg log (4.02 KB, text/plain)
2016-04-12 07:46 UTC, yan
Details
syslog (53.42 KB, text/plain)
2016-04-12 07:47 UTC, yan
Details
Syslog output when plugging in the HDMI cable (89.00 KB, text/plain)
2017-04-05 07:48 UTC, yan
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Robby Engelmann 2015-10-07 06:24:39 UTC
When I plug in a DisplayPort to HDMI cable to link notebook to the TV nothing happens automatically.
When I open the Display Configuration, I can see the second screen. When I try to enable it, the checkmark from the enable point is removed automatically after 1-2 sec. Thus, it is not possible to activate the second screen.
After a restart with the plugged in cable, KDE comes up with black screen and mouse cursor only.
My notebook is an Lenovo X220 with Sandybridge architecture. I am using openSUSE Tumbleweed with Mesa 11 and Kernel 4.2.1.

Reproducible: Always
Comment 1 Maciej Mrozowski 2015-10-09 12:32:12 UTC
I can confirm this and other weird behaviour of kscreen, with VGA output in my case.
It seeems kscreen keeps some cached information of connected monitors, ignoring (at least partially) what xrandr returns.

Procedure to reproduce in my case:
1. Login (new plasma/kscreen session started) with just single output connected (for instance built-in laptop screen)
2. Plug-in some monitor A to VGA connector (in my case it was Sony TV in some conference room).
3. This will usually work - new empty screen is assigned, plasmashell is aware of screen, output is enabled.
In my case I had screens already defined (.local/share/kscreen) so this new VGA output will display next screen. All fine so far.
4. Now, unplug monitor A and plug different monitor B, monitor with different parameters, EDID, resolutions , etc.
Kscreen KCM will still show monitor A and its resolutions, completely ignoring xrandr information. Like it cached some information and didn't think hot-plug event should invalidate it.
In my case, in step 4, I'm plugging laptop to docking station with two monitors - one via DVI (let's call it monitor C - HP in my case), one via VGA (monitor B - in my case some Dell).

Then, when I want to manually enable monitor B via kscreen KCM, checkbox goes 'disabled' automatically, probably because selected moitor parameters (resolution likely) is not supported by actually connected monitor B (since KCM did not update that info).

I consider this a regression, I remember, a month or two ago, it was still working well.
Comment 2 Maciej Mrozowski 2015-10-09 12:33:09 UTC
Created attachment 94909 [details]
Screenshot with outdated KCM information (compare with xrandr output)
Comment 3 Maciej Mrozowski 2015-10-09 12:34:07 UTC
Created attachment 94910 [details]
xrandr output
Comment 4 Maciej Mrozowski 2015-10-09 12:37:14 UTC
Created attachment 94911 [details]
.local/share/kscreen/81c0a2e36c78e995413d6ae4edf828be

One of kscreen config files
Comment 5 Maciej Mrozowski 2015-10-09 12:40:43 UTC
Created attachment 94913 [details]
.local/share/kscreen/e662a3070e33d8d4e76edd1f889acddf

Second kscreen config file.
What is logic that rules creating those files? When does kscreen decide this is new configuration or just perhaps degraded (missing output) existing configuration.
When can I find the algorithm in kscreen related to outputs detection, primary screen detection, screen to outoput assignment etc?
Comment 6 Maciej Mrozowski 2015-10-09 12:51:28 UTC
Created attachment 94914 [details]
kscreen-console output
Comment 7 Robby Engelmann 2015-10-28 06:05:09 UTC
I removed ./local/share/kscreen, since then it seems to work. However, I am not sure whether it could also be an update of the openSUSE TW channel.
Comment 8 Robby Engelmann 2015-11-16 09:08:40 UTC
I observed the issue again, and again, removal of  ./local/share/kscreen helped here
Comment 9 raphead 2015-12-04 11:46:21 UTC
I can confirm this. I was not able to enable an external screen until I deleted aforementioned folder.
 I'm running kscreen 5.4.3 with everything latest on Gentoo.
Comment 10 Alexey Shildyakov 2016-03-21 10:12:58 UTC
It may be partially connected with bug 360563
Comment 11 yan 2016-04-12 07:45:22 UTC
I'm having a similar problem. I can't get my monitor to work using HDMI from a ThinkPad t460s and using Kubuntu 16.04 (beta2). When I change the settings, the screen turns black for a moment and then returns to what it was before. Deleting ./local/share/kscreen doesn't make a difference.

dmesg and syslog contain the following:

snd_hda_codec_hdmi hdaudioC0D2: HDMI: ELD buf size is 0, force 128
snd_hda_codec_hdmi hdaudioC0D2: HDMI: invalid ELD data byte 0

I'll attach the logs.
Comment 12 yan 2016-04-12 07:46:56 UTC
Created attachment 98349 [details]
dmesg log
Comment 13 yan 2016-04-12 07:47:25 UTC
Created attachment 98350 [details]
syslog
Comment 14 yan 2016-05-16 07:28:38 UTC
Any thoughts on this issue? I still can't use an external monitor, now running the official 16.04 release.
Comment 15 spam 2016-07-13 18:42:26 UTC
I'm affected by this bug too, on PC after enabling HDMI sometimes DP monitor cannot be enabled; on Laptop (macbook), built-in display cannot be enabled after connecting external display (DVI-thunderbolt connector but shown as HDMI)
Comment 16 yan 2017-04-05 07:47:08 UTC
It's been a year and a half now. Any thoughts? I still can't manage to connect my monitor through HDMI. I'll attach the latest syslog (when pluggin in).
Comment 17 yan 2017-04-05 07:48:02 UTC
Created attachment 104889 [details]
Syslog output when plugging in the HDMI cable
Comment 18 raphead 2017-04-05 09:06:29 UTC
For me it has improved a lot in last 12 months, there are only rare cases when external monitors are not detected. What helps in 100% of the cases is to reboot the machine. Is it detected for you when you do this?
Comment 19 yan 2017-04-05 12:04:46 UTC
No, unfortunately not. After reboot, I can see a monitor in the display settings (although it doesn't show the correct name, I have a LG Flatron W2261VP, but it says "Goldstar" or something like that in the settings). When I activate it, everything goes wild until I unplu the HDMI cable, but the external monitor remains black.
Comment 20 yan 2017-12-04 07:38:17 UTC
For some months the external monitor worked fine. Now the problem is back. Syslog contains the following:

HPD interrupt storm detected on connector DP-2: switching from hotplug detection to polling

Any more ideas?

I'm running Kubuntu 16.04 (LTS) with Kernel 4.10.40 currently.
Comment 21 yan 2019-09-22 13:28:42 UTC
I'm now running Kubuntu 18.04 LTS and the problem is still the same (after two more years). I just tried with a Live USB both with Kubuntu and Ubuntu 18.04. Both act the same: When I plug in the HDMI cable, the screen turns black, comes back, turns black etc. The syslog is filled with Kscreen message (in the KDE case) and something similar in the Ubuntu case.

A current syslog from right after plugging in the monitor can be found here:
https://paste.ubuntu.com/p/qtJJ8tzQ4K/

Any more ideas?