Bug 103354 - LVDS-1 output only turns on with sleep 1s workaround
Summary: LVDS-1 output only turns on with sleep 1s workaround
Status: RESOLVED MOVED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/AMDgpu (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Default DRI bug account
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-10-18 22:17 UTC by Peter Stuge
Modified: 2019-11-19 08:24 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
dmesg drm snippet (3.26 KB, text/plain)
2017-10-18 22:17 UTC, Peter Stuge
no flags Details

Description Peter Stuge 2017-10-18 22:17:38 UTC
Created attachment 134915 [details]
dmesg drm snippet

I've got a TFT screen unit with an integrated AMD G-T56N mainboard used for signage. I build kernel and xorg myself.

I have this problem on kernels 4.9.29, 4.9.52, 4.13.4 and git.freedesktop.org/~airlied/linux.git drm-next commit baf7c1f7e from Oct 6th.

I am using the xorg modeset video driver.

I want to lock FHD resolution so on the kernel cmdline I have:
drm_kms_helper.edid_firmware=edid/1920x1080.bin

This works well. X reports the LNX EDID as expected.

systemd starts X with xinit and a simple client script of mine which runs xrandr to set rotation, make all outputs same-as the primary output and then exec the signage application.

The built-in TFT panel is on connector 0, which drm and X both call LVDS-1.

The unit also has an external HDMI connector, that's connector 1, which drm calls HDMI-A-1 but X calls HDMI-1.

During boot, BIOS and mode 03h with MBR bootloader are visible on the internal TFT.

When drm takes over and switches from mode 03h all connected panels turn off and remain off, I guess because there's no kmscon. That's OK.


The problem:

When X has started (with or without my script) xrandr always reports the internal panel (connector 0 AKA LVDS-1) as connected primary and on with FHD resolution *but* the panel stays off.

Connector 0 seems to have a DP->HDMI encoder connected to it, internally in the unit. I'm not sure - no docs on that level and it's not very easy to investigate inside the unit. There is a BIOS setting to disable the encoder, choosing "Disabled" causes there to be no output at all on the internal panel, not even mode 03h BIOS/MBR.

I guess that there is a timing issue between amdgpu and that encoder?

Connector 1 AKA HDMI-A-1 AKA HDMI-1 works reliably. If a screen is connected, it turns on and shows the expected contents, as set by xrandr. Whether a screen is connected to HDMI-1 has no effect on the internal panel.


I've found a workaround for the problem. Adding this to the xinit client script makes the internal panel turn on:

--8<--
xrandr --output LVDS-1 --off
sleep 1s
xrandr --output LVDS-1 --auto
-->8--

The sleep is required. If I remove it then the internal panel does *not* turn on.


Questions:

Can I help find the cause of my problem and make the internal panel turn on without the workaround? What additional information is needed?

What is the relationship between drm connector names and X output names? More specifically, how could I find out that drm HDMI-A-1 is called HDMI-1 by X?

What is "ib test on ring 5" ? It currently takes 500 ms. How to optimize that?
Comment 1 Martin Peres 2019-11-19 08:24:58 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/drm/amd/issues/247.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.