Bug 21417 - [G33][KMS] "Out of range signal" when changing to lower resolution
Summary: [G33][KMS] "Out of range signal" when changing to lower resolution
Status: CLOSED FIXED
Alias: None
Product: DRI
Classification: Unclassified
Component: DRM/Intel (show other bugs)
Version: XOrg git
Hardware: x86-64 (AMD64) Linux (All)
: high normal
Assignee: ykzhao
QA Contact:
URL:
Whiteboard:
Keywords: patch
: 23463 (view as bug list)
Depends on:
Blocks:
 
Reported: 2009-04-26 09:35 UTC by Sean Young
Modified: 2017-07-24 23:10 UTC (History)
3 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Xorg output with KMS (27.41 KB, application/octet-stream)
2009-04-26 09:36 UTC, Sean Young
no flags Details
Xorg output without KMS (22.45 KB, application/octet-stream)
2009-04-26 09:36 UTC, Sean Young
no flags Details
Xorg.log with Option "ModeDebug" "true" (42.95 KB, text/plain)
2009-07-29 01:11 UTC, Sean Young
no flags Details
vbios dump (DG33TL motherboard) (48.00 KB, application/octet-stream)
2009-07-29 01:12 UTC, Sean Young
no flags Details
intel_reg_dump output after switching to 640x480 with scummvm. DVI, KMS (9.65 KB, text/plain)
2009-07-30 04:00 UTC, Sean Young
no flags Details
intel_reg_dump output after switching to 640x480 with scummvm. DVI, UMS (9.65 KB, text/plain)
2009-07-30 04:00 UTC, Sean Young
no flags Details
Fixes DVI problem (668 bytes, patch)
2009-08-05 17:28 UTC, Sean Young
no flags Details | Splinter Review

Description Sean Young 2009-04-26 09:35:20 UTC
Ubuntu Jaunty with xserver-xorg-video-intel 2.6.3 recompiled with KMS support.

Linux 2.6.30-rc3. 
Intel DG33TL motherboard, x86_64.
Dell 2007WFP monitor connected through DVI with 1680x1050 native resolution.

If I change the resolution to a lower setting (1024x768, 640x480, etc) then the screen goes blank and the monitor reports "Out of range signal". If I boot with "i915.modeset=0" then this does work.

dmesg reports:
[  139.742393] [drm] TMDS-8: set mode 640x480 16
[  145.563191] [drm] TMDS-8: set mode 1680x1050 17

Booting into the native resolution works fine and gives a very cool/big console. xrandr does report:

sean@triffid:~$ xrandr -q
xrandr: output DVI1 cannot use rotation "normal" reflection "none"

Please ask if there is anything I can try or do to assist in debugging this.
Comment 1 Sean Young 2009-04-26 09:36:07 UTC
Created attachment 25153 [details]
Xorg output with KMS
Comment 2 Sean Young 2009-04-26 09:36:27 UTC
Created attachment 25154 [details]
Xorg output without KMS
Comment 3 Gordon Jin 2009-04-26 18:17:43 UTC
It's a known issue that only native resolution supported in KMS with current code.  	

*** This bug has been marked as a duplicate of bug 20801 ***
Comment 4 Sean Young 2009-07-26 09:46:18 UTC
Unfortunately bug 20801 did not resolve this issue. Now running:

kernel 2.6.31-rc2

Latest from http://ppa.launchpad.net/xorg-edgers/ppa/ubuntu , e.g.:

xserver-xorg-video-intel 2:2.8.0+git20090724.9a45ace2-0ubuntu0sarvatt~jaunty

Still getting "Out of range signal" when going to non-native mode.

xrandr still says:

sean@triffid:~$ xrandr 
xrandr: output DVI1 cannot use rotation "normal" reflection "none"
Comment 5 ykzhao 2009-07-28 18:00:13 UTC
Will you please attach the xorg.log with modedebug option enabled in xorg.conf?
Please also attach the output of vbios dump.
    the vbiso dump can be obtained by using the following commands:
     echo 1 > /sys/devices/pci0000:00/0000:00:02.0/rom
     cat /sys/devices/pci0000:00/0000:00:02.0/rom > vbios.dump
     echo 0 > /sys/devices/pci0000:00/0000:00:02.0/rom

Thanks.
Comment 6 Sean Young 2009-07-29 01:11:46 UTC
Created attachment 28141 [details]
Xorg.log with Option "ModeDebug" "true"
Comment 7 Sean Young 2009-07-29 01:12:35 UTC
Created attachment 28142 [details]
vbios dump (DG33TL motherboard)
Comment 8 Michael Fu 2009-07-29 18:21:25 UTC
would you please help to grab two register dumps? 

1) running KMS, after set mode to non-native mode, ssh/telnet to the machine and run intel_reg_dump and save its output

2) running UMS (with i915.modeset=0), after set mode to the same mode as above ( but should work), run intel_reg_dump and save the output.

the MB also have VGA port. Does it work well in KMS in non-native mode?

>sean@triffid:~$ xrandr 
>xrandr: output DVI1 cannot use rotation "normal" reflection "none"

does xrandr output more than that? if so, would you pls attach the whole output as well? thanks.
Comment 9 Sean Young 2009-07-30 03:54:40 UTC
When using the VGA output on the same monitor (disconnecting DVI) then non-native resolutions *do* work with KMS.

xrandr behaves strangely with KMS. When running xrandr before the first switch to non-native, the output is:

sean@triffid:~$ xrandr
Screen 0: minimum 320 x 200, current 1680 x 1050, maximum 2048 x 2048
VGA1 connected 1680x1050+0+0 (normal left inverted right x axis y axis) 434mm x 270mm
   1680x1050      60.0*+
   1280x1024      75.0
   1024x768       75.1     60.0
   800x600        75.0     60.3
   640x480        75.0     60.0
   720x400        70.1
DVI1 disconnected (normal left inverted right x axis y axis)

As soon as I switch to 640x480 (and before switching back), the output is:
sean@triffid:~$ xrandr
xrandr: output VGA1 cannot use rotation "normal" reflection "none"

When I then switch back to native resolution, xrandr keeps on giving the same broken result. It does not seem to work until the next reboot.

Same ouput for KMS with DVI. However, in this case, non-native resolutions do *not* work. After reboot with DVI connected:

sean@triffid:~$ xrandr
Screen 0: minimum 320 x 200, current 1680 x 1050, maximum 2048 x 2048
VGA1 disconnected (normal left inverted right x axis y axis)
DVI1 connected 1680x1050+0+0 (normal left inverted right x axis y axis) 434mm x 270mm
   1680x1050      59.9*+
   1280x1024      75.0
   1024x768       75.1     60.0
   800x600        75.0     60.3
   640x480        75.0     60.0
   720x400        70.1

After first mode switch:
sean@triffid:~$ xrandr
xrandr: output DVI1 cannot use rotation "normal" reflection "none"

and then the same until the next reboot..
Comment 10 Sean Young 2009-07-30 04:00:22 UTC
Created attachment 28186 [details]
intel_reg_dump output after switching to 640x480 with scummvm. DVI, KMS
Comment 11 Sean Young 2009-07-30 04:00:43 UTC
Created attachment 28187 [details]
intel_reg_dump output after switching to 640x480 with scummvm. DVI, UMS
Comment 12 MaLing 2009-07-30 19:40:27 UTC
From comparison we can see only two difference, vgactrl and dpll_a register setting, the difference from dpll_register seem to be trival. So please try the patch http://lists.freedesktop.org/archives/intel-gfx/2009-July/003564.html in KMS mode, then upload the register dump with the same enviroment with that in comments #10.

Thanks
Ma Ling
Comment 13 Sean Young 2009-07-31 01:26:00 UTC
Running here with:

$ dpkg -l xserver-xorg-video-intel | cat
xserver-xorg-video-intel 2:2.8.0+git20090728.50e2a673-0ubuntu0sarvatt~jaunty

In /etc/apt/sources.list I have:

deb http://ppa.launchpad.net/xorg-edgers/ppa/ubuntu jaunty main

That version includes the commit mentioned in comment #12.
Comment 14 Sean Young 2009-07-31 02:11:54 UTC
Based on the diff of the register dump, I tried setting the registers in KMS mode according to what they are in UMS mode.

Steps to reproduce:
 - Monitor connected via DVI
 - KMS kernel
 - Go to a resolution of 640x480 (using scummvm)
 - "Out of Range Signal" on monitor
 - Login remotely using ssh
$ sudo intel_reg_write 0x6014 0xd4020030
Value before: 0xD4020000
Value after: 0xD4020030

And the screen appears! Note this motherboard only has DVI and VGA. I have no idea what SDVO means, which is mentioned in the output of intel_reg_dumper.

While in native mode, this register seems to be 0xd4020000. If I set it to 0xD4020030 while in native resolution the screen goes blank.
Comment 15 Sean Young 2009-08-04 13:57:52 UTC
Verified again on latest:

linux-2.6 a33a052f19a21d727847391c8c1aff3fb221c472
xserver-xorg-video-intel 2:2.8.0+git20090804.af45482a-0ubuntu0sarvatt~jaunty 

Using VGA all is ok. With DVI, screen goes blank after switching to 640x480, but does work if I login with ssh and execute:

$ sudo intel_reg_write 0x6014 0xd4020030

Also upgraded bios to latest version on DG33TL, released on the 15th of July.

No problems using UMS.
Comment 16 Sean Young 2009-08-05 17:28:13 UTC
Created attachment 28389 [details] [review]
Fixes DVI problem

After comparing the UMS code and KMS code, I found that there was a missing condition in the kernel code for the G33 chipset.

With this patch, switching to 640x480 in KMS mode does work on my G33.
Comment 17 Michael Fu 2009-08-05 17:46:22 UTC
nice work! thanks, Sean.
Comment 18 ykzhao 2009-08-06 02:23:14 UTC
(In reply to comment #16)
> Created an attachment (id=28389) [details]
> Fixes DVI problem
> 
> After comparing the UMS code and KMS code, I found that there was a missing
> condition in the kernel code for the G33 chipset.
> 
> With this patch, switching to 640x480 in KMS mode does work on my G33.
> 
Great job.
Will you please send the patch to intel-gfx mailing list?
Thanks.

Comment 19 ykzhao 2009-08-24 01:26:54 UTC
This is a sync issue about SDVO device between UMS and KMS.
The patch is already sent to the intel-gfx mailing list.
   >http://lists.freedesktop.org/archives/intel-gfx/2009-August/003950.html

Thanks.
Comment 20 ykzhao 2009-08-24 19:02:09 UTC
The patch is already shipped in Eric's drm-intel-next tree.
   commit 942642a412454c3365f0abc8399c8ef2944f4eac
Author: Sean Young <sean@mess.org>
Date:   Thu Aug 6 17:35:50 2009 +0800

    drm/i915: Set the multiplier for SDVO on G33 platform

So this bug will be marked as resolved.
Thanks.
Comment 21 ykzhao 2009-08-30 23:36:18 UTC
*** Bug 23463 has been marked as a duplicate of this bug. ***


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.