Re: Blank (disconnected) screen during boot with latest 2.6.35-rcX kernels

From: Alex Deucher
Date: Tue Jul 20 2010 - 03:10:10 EST


On Mon, Jul 19, 2010 at 5:50 PM, trapDoor <trapdoor6@xxxxxxxxx> wrote:
> Dear kernel Developers,
> I'd like to report a bug occurring on my machine with some of the
> latest 2.6.35-rcX and the '-next' kernels. As I'm not sure what is the
> problem related to I may have omitted relevant people among the
> recipients. If it is so I'll be thankful if someone could cc them.
> Also I must apologise for reporting this so late, when it's close to
> the end of development cycle for 2.6.35.
>
> I didn't try to bisect. I've never done it before and maybe someone
> will able to reproduce the problem or see straight what's going on by
> looking into attached log/config files. But if it is necessary I'll
> try my hand at bisecting.
>
> ******
> Description of the problem:
>
> Affected kernels tested by me: 2.6.35-rc5-git3, 2.6.35-rc4-git5 and
> 2.6.35-rc4-next-20100712.
> Kernel 2.6.34.1 works OK.
>
> Briefly what happens is that my graphics card seems to loose
> connection with the LCD screen (connected through DVI) during boot.
> Initially it does show something - a blank screen with blinking cursor
> but it lasts only for about 2-3 seconds and then the screen switches
> to stand-by mode giving message 'No signal detected !'. The booting
> process seems to continue though, and looking cursorily through
> related dmesg and Xorg logs I can't see any suspicious messages
> (comparing with the same logs produced when booting from working
> kernel). I'm attaching the following files with this e-mail:
>    dmesg, Xorg.0.log - produced during successful boot with 2.6.34.1
>    dmesg.0, Xorg.0.log.old - these are for the failed boot with 2.6.35-rc5-git3
>
> Also please find attached config files:
>     config-2.6.34.1 - for my current, working kernel
>     config-2.6.35-rc5-git3 - based on above, almost all new entries I
> left undefined/disabled during making 'oldconfig'; particularly I
> didn't touch any options related to PCI, graphics drivers, ACPI or
> power management - these should be all the same as in config-2.6.34.1
>
> All the kernels were compiled on the same PC and system, they have/had
> radeon-kms enabled by default and these firmware files compiled in:
> R600_rlc.bin, R700_rlc.bin
>
> ******
> A brief specification of my system:
>
> 1) OS/software:
>
> Ubuntu 10.04, amd64
>
> Xorg, xserver, drm, mesa, drm and ati/radeon drivers installed from
> the following Ubuntu PPA repository:
> https://edge.launchpad.net/~xorg-edgers/+archive/ppa/
>
> Current versions:
> xorg:  1:7.5+6ubuntu1~xorgedgers3~lucid
> xserver:  2:1.8.2+git20100705+server-1.8-branch.665aa7ce-0ubuntu0sarvatt2~lucid
> xserver-xorg-video-ati:  1:6.13.99+git20100716.cdeb1949-0ubuntu0sarvatt~lucid
> xserver-xorg-video-radeon:  1:6.13.99+git20100716.cdeb1949-0ubuntu0sarvatt~lucid
> drm:  1:2.4.20+git20100513.a3305b07-0ubuntu0sarvatt~lucid
> mesa:  7.9.0+git20100718.4eaf591d-0ubuntu0sarvatt~lucid
>
> 2) Hardvare:
> MB: Asus M4A79T Deluxe with chipsets AMD 790FX/SB750
> Processor: AMD Phenom II X4 810
> Graphics Card: Asus EAH3650 SILENT/HTDI/512M - based on chipset RV635
> PRO, port PCIEx2, connected with LCD through DVI
>
> ******
> Please let me know if anyone requires additional details and if there
> is any tracking/testing I could do on my end.

The driver is not able to detect any attached monitors with 2.6.35:

[ 1.980334] No connectors reported connected with modes
[ 1.980338] [drm] Cannot find any crtc or sizes - going 1024x768

[ 19.012] (II) RADEON(0): Output HDMI-0 disconnected
[ 19.012] (II) RADEON(0): Output VGA-0 disconnected
[ 19.012] (II) RADEON(0): Output DIN disconnected
[ 19.012] (II) RADEON(0): Output DVI-0 disconnected
[ 19.012] (WW) RADEON(0): Unable to find connected outputs -
setting 1024x768 initial framebuffer

I think the attached patch should fix the issue. if not, can you try
reverting b2ea4aa67bfd084834edd070e0a4a47857d6db59 ?

Alex
From 5d0a23698f57f488532ee0489f8931ee79d6ea3f Mon Sep 17 00:00:00 2001
From: Alex Deucher <alexdeucher@xxxxxxxxx>
Date: Tue, 20 Jul 2010 03:01:14 -0400
Subject: [PATCH] drm/radeon/kms: fix shared ddc harder

This fixes a regression caused by b2ea4aa67bfd084834edd070e0a4a47857d6db59
due to the way shared ddc with multiple digital connectors was handled.

You generally have two cases where DDC lines are shared:
- HDMI + VGA
- HDMI + DVI-D

HDMI + VGA is easy to deal with because you can check the EDID for the
to see if the attached monitor is digital. A shared DDC line with two
digital connectors is more complex. You can't use the hdmi bits in the
EDID since they may not be there with DVI<->HDMI adapters. In this case
all we can do is check the HPD pins to see which is connected as we have
no way of knowing using the EDID.

Reported-by: trapdoor6@xxxxxxxxx
Signed-off-by: Alex Deucher <alexdeucher@xxxxxxxxx>
Cc: stable@xxxxxxxxxx
---
drivers/gpu/drm/radeon/radeon_connectors.c | 23 +++++++++--------------
1 files changed, 9 insertions(+), 14 deletions(-)

diff --git a/drivers/gpu/drm/radeon/radeon_connectors.c b/drivers/gpu/drm/radeon/radeon_connectors.c
index f58f8bd..adccbc2 100644
--- a/drivers/gpu/drm/radeon/radeon_connectors.c
+++ b/drivers/gpu/drm/radeon/radeon_connectors.c
@@ -771,14 +771,14 @@ static enum drm_connector_status radeon_dvi_detect(struct drm_connector *connect
} else
ret = connector_status_connected;

- /* multiple connectors on the same encoder with the same ddc line
- * This tends to be HDMI and DVI on the same encoder with the
- * same ddc line. If the edid says HDMI, consider the HDMI port
- * connected and the DVI port disconnected. If the edid doesn't
- * say HDMI, vice versa.
+ /* This gets complicated. We have boards with VGA + HDMI with a
+ * shared DDC line and we have boards with DVI-D + HDMI with a shared
+ * DDC line. The latter is more complex because with DVI<->HDMI adapters
+ * you don't really know what's connected to which port as both are digital.
*/
if (radeon_connector->shared_ddc && (ret == connector_status_connected)) {
struct drm_device *dev = connector->dev;
+ struct radeon_device *rdev = dev->dev_private;
struct drm_connector *list_connector;
struct radeon_connector *list_radeon_connector;
list_for_each_entry(list_connector, &dev->mode_config.connector_list, head) {
@@ -788,15 +788,10 @@ static enum drm_connector_status radeon_dvi_detect(struct drm_connector *connect
if (list_radeon_connector->shared_ddc &&
(list_radeon_connector->ddc_bus->rec.i2c_id ==
radeon_connector->ddc_bus->rec.i2c_id)) {
- if (drm_detect_hdmi_monitor(radeon_connector->edid)) {
- if (connector->connector_type == DRM_MODE_CONNECTOR_DVID) {
- kfree(radeon_connector->edid);
- radeon_connector->edid = NULL;
- ret = connector_status_disconnected;
- }
- } else {
- if ((connector->connector_type == DRM_MODE_CONNECTOR_HDMIA) ||
- (connector->connector_type == DRM_MODE_CONNECTOR_HDMIB)) {
+ /* cases where both connectors are digital */
+ if (list_connector->connector_type != DRM_MODE_CONNECTOR_VGA) {
+ /* hpd is our only option in this case */
+ if (!radeon_hpd_sense(rdev, radeon_connector->hpd.hpd)) {
kfree(radeon_connector->edid);
radeon_connector->edid = NULL;
ret = connector_status_disconnected;
--
1.7.1.1