Bug 11598 - [845] X fail to start with "No valid modes"
Summary: [845] X fail to start with "No valid modes"
Status: RESOLVED FIXED
Alias: None
Product: xorg
Classification: Unclassified
Component: Driver/intel (show other bugs)
Version: 7.2 (2007.02)
Hardware: x86 (IA32) Linux (All)
: medium normal
Assignee: Hong Liu
QA Contact: Xorg Project Team
URL:
Whiteboard:
Keywords: NEEDINFO
Depends on:
Blocks:
 
Reported: 2007-07-14 01:42 UTC by Michael Eschweiler
Modified: 2008-02-12 19:36 UTC (History)
5 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Xorg.0.log with new Intel driver (20.22 KB, text/plain)
2007-11-03 09:45 UTC, unggnu
no flags Details
lspci -vvnn (7.63 KB, text/plain)
2007-11-03 09:46 UTC, unggnu
no flags Details
xorg.conf (3.61 KB, text/plain)
2007-11-03 09:46 UTC, unggnu
no flags Details
Xorg.0.log witch patched Ubuntu Gutsy Gibbon Intel driver after xorg.conf removal (58.88 KB, text/plain)
2007-11-22 03:29 UTC, unggnu
no flags Details
Xorg.0.log with patched Ubuntu Intel driver (19.75 KB, text/plain)
2007-11-23 02:02 UTC, unggnu
no flags Details
xorg.conf (2.69 KB, text/plain)
2007-11-23 02:03 UTC, unggnu
no flags Details
Xorg.0.log with i810 driver (HorizSync have to been activated in xorg.conf to get 1024x768) (53.68 KB, text/plain)
2007-11-23 02:04 UTC, unggnu
no flags Details
2nd try (1.62 KB, patch)
2007-11-27 00:18 UTC, Hong Liu
no flags Details | Splinter Review
Xorg.0.log.old with 2nd try patched Ubuntu Intel driver (19.75 KB, text/plain)
2007-11-27 23:25 UTC, unggnu
no flags Details
Testcase with MODE DEBUG (16.69 KB, application/tarfile)
2007-12-29 10:57 UTC, Shofi Islam
no flags Details
xorg.0.log with modedebug turned on. (41.44 KB, text/plain)
2008-01-07 01:34 UTC, Michael Fu
no flags Details
Xorg.conf used for MODEDEBUG test (2.88 KB, application/octet-stream)
2008-01-27 11:03 UTC, Shofi Islam
no flags Details
Xorg log with MODEBUG and xorg.conf above (41.44 KB, text/x-log)
2008-01-27 11:04 UTC, Shofi Islam
no flags Details
13972: Xorg.conf used for MODEDEBUG test (2.88 KB, application/octet-stream)
2008-01-27 11:08 UTC, Shofi Islam
no flags Details
13972: Xorg.conf used for MODEDEBUG test (2.88 KB, text/plain)
2008-01-27 11:10 UTC, Shofi Islam
no flags Details
Xorg log with MODEBUG and xorg.conf above (41.44 KB, text/plain)
2008-01-27 11:13 UTC, Shofi Islam
no flags Details
lspci output from above test (7.96 KB, text/plain)
2008-01-27 11:17 UTC, Shofi Islam
no flags Details
ddcprobe (538 bytes, text/plain)
2008-01-27 11:19 UTC, Shofi Islam
no flags Details
Updated Xorg.0.log with MODEDEBUG and xorg.conf (27.94 KB, text/plain)
2008-02-01 11:38 UTC, Shofi Islam
no flags Details
dmesg log as requested (21.91 KB, text/plain)
2008-02-03 09:01 UTC, Shofi Islam
no flags Details
location of module ch7017 (40 bytes, text/plain)
2008-02-03 09:04 UTC, Shofi Islam
no flags Details
i830_drv.c from ubntu Gutsy (2:2.1.1-0ubuntu9) (14.85 KB, text/plain)
2008-02-04 12:15 UTC, Shofi Islam
no flags Details
Xorg.0.log using recompiled driver (58.63 KB, text/plain)
2008-02-06 12:23 UTC, Shofi Islam
no flags Details
glxinfo (5.08 KB, text/plain)
2008-02-06 12:30 UTC, Shofi Islam
no flags Details

Description Michael Eschweiler 2007-07-14 01:42:37 UTC
I installed openSUSE 10.2 on a Fujitsu Siemens PC (the manual says: Mainboard D1382) with an integrated intel 845 graphic chip (sax2 -p says: Chip 0 is -> Intel i845 00:02:0 0x8086 0x2562 PCI intel). Then I did a complete update to the latest packages. After this I restarted the computer but when changing to runlevel 5 the computer crashed - black screen, no way to a console. I tried several times to reconfigure the x-server with sax2 but only after having replaced driver "intel" by driver "i810" in Device section of the xorg.conf i get the x-server to work properly.
Comment 1 Gordon Jin 2007-10-08 22:53:51 UTC
Are you still seeing this problem with the latest driver? Please attach xorg.conf and Xorg.0.log.
Comment 2 unggnu 2007-10-28 13:27:53 UTC
I can confirm this with Gutsy and -intel driver 2:2.1.1-0ubuntu9.
Comment 3 unggnu 2007-11-03 09:45:59 UTC
Created attachment 12331 [details]
Xorg.0.log with new Intel driver
Comment 4 unggnu 2007-11-03 09:46:29 UTC
Created attachment 12332 [details]
lspci -vvnn
Comment 5 unggnu 2007-11-03 09:46:50 UTC
Created attachment 12333 [details]
xorg.conf
Comment 6 Hong Liu 2007-11-21 01:16:11 UTC
Would you please try the following patch to see if the problem is fixed?

Thanks,
Hong

diff --git a/src/i830_crt.c b/src/i830_crt.c
index d7762a0..7def610 100644
--- a/src/i830_crt.c
+++ b/src/i830_crt.c
@@ -162,9 +162,12 @@ i830_crt_detect_hotplug(xf86OutputPtr output)
     const int  timeout_ms = 1000;
     int                starttime, curtime;
 
-    temp = INREG(PORT_HOTPLUG_EN);
+    /* clear the CRT hotplug status bits first */
+    OUTREG(PORT_HOTPLUG_STAT, CRT_HOTPLUG_MONITOR_MASK);
 
-    OUTREG(PORT_HOTPLUG_EN, temp | CRT_HOTPLUG_FORCE_DETECT | (1 << 5));
+    temp = INREG(PORT_HOTPLUG_EN);
+    OUTREG(PORT_HOTPLUG_EN,
+       temp | CRT_HOTPLUG_FORCE_DETECT | (1 << 5) | CRT_HOTPLUG_INT_EN);
 
     for (curtime = starttime = GetTimeInMillis();
         (curtime - starttime) < timeout_ms; curtime = GetTimeInMillis())
Comment 7 unggnu 2007-11-22 03:29:25 UTC
Created attachment 12687 [details]
Xorg.0.log witch patched Ubuntu Gutsy Gibbon Intel driver after xorg.conf removal

Many thanks for your patch but problem still appears.
Still gdm starts with 640x480 instead of 1024x768.
If I use my normal xorg.conf and replace i810 with intel X crashes. I am going to attach a gdb report soon.
Comment 8 Hong Liu 2007-11-22 17:03:49 UTC
(In reply to comment #7)
> Created an attachment (id=12687) [details]
> Xorg.0.log witch patched Ubuntu Gutsy Gibbon Intel driver after xorg.conf
> removal
> 
> Many thanks for your patch but problem still appears.

Sorry, the patch only works on new chips (945 and 965..).
It seems we can't detect the connected monitors, will work on this to see if we can find any solution...

> Still gdm starts with 640x480 instead of 1024x768.
> If I use my normal xorg.conf and replace i810 with intel X crashes. I am going
> to attach a gdb report soon.
>

For i810 driver, it filters out the 1024x768 mode because of the hysnc range:

(II) I810(0): Builtin Default Monitor: Using default hsync range of 31.50-37.90 kHz

You can try to add HorizSync to your monitor section to enlarge the hysnc range.

Thanks,
Hong
Comment 9 unggnu 2007-11-23 02:02:38 UTC
Created attachment 12696 [details]
Xorg.0.log with patched Ubuntu Intel driver
Comment 10 unggnu 2007-11-23 02:03:34 UTC
Created attachment 12697 [details]
xorg.conf
Comment 11 unggnu 2007-11-23 02:04:58 UTC
Created attachment 12698 [details]
Xorg.0.log with i810 driver (HorizSync have to been activated in xorg.conf to get 1024x768)
Comment 12 unggnu 2007-11-23 02:36:31 UTC
How it is possible to get a gdb backtrace of Xorg which crashes directly after start so it is not possible to get a pid and attach it?
But according to log it only seems to be a ddc/resolution since it shutdown normally.
Comment 13 unggnu 2007-11-23 05:07:53 UTC
Thanks for your reply. Manual adding of HorizSync only works with i810 driver. The Intel driver seems to ignore these because of modesetting I guess.
Comment 14 Hong Liu 2007-11-25 17:43:49 UTC
(In reply to comment #13)
> Thanks for your reply. Manual adding of HorizSync only works with i810 driver.
> The Intel driver seems to ignore these because of modesetting I guess.
> 

Yes, you have to stick with the i810 driver currently :(

With the Intel driver, we can't detect the connected CRT monitor:
(II) intel(0): Output VGA disconnected
(II) intel(0): EDID for output VGA
(II) intel(0): Output VGA disconnected
(EE) intel(0): No valid modes.

So X server exits without success. We need to figure out a better solution for monitor detection for this chipset.
Comment 15 Hong Liu 2007-11-27 00:18:16 UTC
Created attachment 12731 [details] [review]
2nd try

Please have a try on the attached patch.

Thanks,
Hong
Comment 16 unggnu 2007-11-27 23:25:50 UTC
Created attachment 12763 [details]
Xorg.0.log.old with 2nd try patched Ubuntu Intel driver
Comment 17 unggnu 2007-11-27 23:26:59 UTC
Many thanks for your patch but I got still the same or a similar error.
Comment 18 unggnu 2007-11-29 00:30:48 UTC
Btw. is HorizSync needed with your 2nd try Patch?
Comment 19 Hong Liu 2007-11-29 01:30:17 UTC
(In reply to comment #18)
> Btw. is HorizSync needed with your 2nd try Patch?
> 

Should not, I am not sure why we can't correctly detect your VGA connection status. This caused your problem.

Thanks,
Hong
Comment 20 unggnu 2007-11-29 01:52:42 UTC
It seems to be a general problem with the 845 chipset since there are some duplicates for and posts under the Ubuntu bug report https://bugs.launchpad.net/bugs/135093 .
Comment 21 unggnu 2007-11-29 01:56:11 UTC
I don't know if there are more but all of the reporters seem to have the Brookdale-G version.
Comment 22 Bryce Harrington 2007-12-05 14:24:29 UTC
Matthew Garrett reports that -intel does not support chipsets older than 855.  "Before 855, it's possible to attach basically arbitrary LVDS encoders to the chipset - the BIOS knows how to talk to them, but -intel doesn't use the BIOS so needs to have code for each of them individually. As far as I know, the entire set isn't currently supported."

So if this is the case, we need to know if -i810 should be retained permanently for use with older chipsets, or if there are any plans/efforts to incorporate the code into -intel.
Comment 23 Eric Anholt 2007-12-06 08:39:21 UTC
No, Bryce.  The released packages have supported the ivch which is in every 830 laptop we've seen so far.  The 845 laptops almost all have ch7017, which is also supported at least upstream (not sure if it was in 2.1 or not).  The remaining chip, which we've seen one instance of, is a natsemi device which we can't find specs for.  And the bug you're commenting on appears to be about a desktop anyway.

unggnu: please open your own bug for your own issue, and include Option "ModeDebug" "YES" in your device section.  No additional patches.

Original submitter: Could we get your log with option "ModeDebug" "YES"?
Comment 24 Shofi Islam 2007-12-29 10:57:13 UTC
Created attachment 13414 [details]
Testcase with MODE DEBUG

Test case with the MODE DEBUG option.
Comment 25 Michael Fu 2008-01-07 01:34:52 UTC
Created attachment 13564 [details]
xorg.0.log with modedebug turned on.

extracted from comment# 24.
Comment 26 Hong Liu 2008-01-23 17:38:24 UTC
(In reply to comment #24)
> Created an attachment (id=13414) [details]
> Testcase with MODE DEBUG
> 
> Test case with the MODE DEBUG option.
> 

Would you please use the intel driver instead of the vesa driver?

Thanks,
Hong
Comment 27 Shofi Islam 2008-01-27 11:03:27 UTC
Created attachment 13972 [details]
Xorg.conf used for MODEDEBUG test

In response to comment 25.  Test case is with Intel driver, not VESA.  However Xorg is reporting VESA for some reason. Will repeat test and publish results
Comment 28 Shofi Islam 2008-01-27 11:04:22 UTC
Created attachment 13973 [details]
Xorg log with MODEBUG and  xorg.conf above
Comment 29 Shofi Islam 2008-01-27 11:08:56 UTC
Created attachment 13974 [details]
13972: Xorg.conf used for MODEDEBUG test
Comment 30 Shofi Islam 2008-01-27 11:10:11 UTC
Created attachment 13975 [details]
13972: Xorg.conf used for MODEDEBUG test
Comment 31 Shofi Islam 2008-01-27 11:13:05 UTC
Created attachment 13976 [details]
Xorg log with MODEBUG and  xorg.conf above

In response to comment 26, the Intel driver is being used despite the VESA messages shown. I have attached the xorg.conf and xorg.0.log.
Comment 32 Shofi Islam 2008-01-27 11:17:59 UTC
Created attachment 13977 [details]
lspci output from above test 

Note Unknown device mentioned at line 9
Comment 33 Shofi Islam 2008-01-27 11:19:54 UTC
Created attachment 13978 [details]
ddcprobe
Comment 34 Michael Fu 2008-01-27 16:47:35 UTC
(In reply to comment #31)
> Created an attachment (id=13976) [details]
> Xorg log with MODEBUG and  xorg.conf above
> 
> In response to comment 26, the Intel driver is being used despite the VESA
> messages shown. I have attached the xorg.conf and xorg.0.log.
> 

Weird... it shouldn't be...
Comment 35 Shofi Islam 2008-02-01 11:38:24 UTC
Created attachment 14076 [details]
Updated Xorg.0.log with MODEDEBUG and xorg.conf

Refreshed Xorg.conf, no changes made but VESA messages gone replaced with intel error messages.
Comment 36 Michael Fu 2008-02-01 16:44:34 UTC
Shofi, would you please also attach you kernel dmesg?
Comment 37 Hong Liu 2008-02-02 00:22:47 UTC
For all who have problem with 845G, you are saying a 845G laptop?
If so, it seems I have made a big mistake for I am trying to find out why VGA can't be detected while it is not connected.

For all who have i810 work on your machine, would you please try to dump the registers when it is working. The tool is in the xf86-video-intel/src/reg_dump, you will need libpciaccess to compile this tool.

Thanks,
Hong
Comment 38 Hong Liu 2008-02-02 00:32:18 UTC
It seems 845G laptop uses ch7017 module to drive the LVDS output.
But I didn't see any ch7017 related info in your xorg log.

Would you please ensure that ch7017 module is existed in your distribution (usually it is on /usr/lib/xorg/modules/drivers/)?


Thanks,
Hong
Comment 39 Shofi Islam 2008-02-03 09:01:55 UTC
Created attachment 14116 [details]
dmesg log as requested

dmesg log as requested
Comment 40 Shofi Islam 2008-02-03 09:04:37 UTC
Created attachment 14117 [details]
location of module ch7017

Module ch7017 present within filesystem, but is not visible using lsmod.  I cannot insert it using modprobe or insmod, but I assume that is because I cannot use these commands.
Comment 41 Hong Liu 2008-02-03 17:52:59 UTC
(In reply to comment #40)
> Created an attachment (id=14117) [details]
> location of module ch7017
> 
> Module ch7017 present within filesystem, but is not visible using lsmod.  I
> cannot insert it using modprobe or insmod, but I assume that is because I
> cannot use these commands.
> 

Sorry for the confusion, ch7017 is a module for X server (not for kernel).
Our drive will try all the compiled modules one by one to try to detect which 
output is active.

f.e this is when we are trying the sil164 module (in xorg log).
(II) Loading sub module "sil164"
(II) LoadModule: "sil164"
(II) Loading /usr/lib/xorg/modules/drivers//sil164.so
(II) Module sil164: vendor="X.Org Foundation"
	compiled for 1.3.0, module version = 1.0.0
	ABI class: X.Org Video Driver, version 1.2
(II) intel(0): I2C bus "DVOI2C_E" initialized.
(EE) intel(0): detecting sil164
(EE) intel(0): Unable to read from DVOI2C_E Slave 112.

We have an array in i830_dvo.c file (i830_dvo_drivers[]), and we will try one by one until we find one active output.
The problem is in your log, the last module we tried is tfp410 (which is not active), but the driver didn't try ch7017 module which is after the tfp410.

Which driver version are you using? Would you please give the latest driver a try?

Or would you please try to move the following block in i830_dvo_drivers[] to a front position to have a try.
   {
        .type = I830_OUTPUT_DVO_LVDS,
        .modulename = "ch7017",
        .fntablename = "ch7017_methods",
        .dvo_reg = DVOC,
        .address = 0xea,
        .symbols = ch7017_symbols,
        .gpio = GPIOE,
    }

Thanks,
Hong
Comment 42 Shofi Islam 2008-02-04 12:15:17 UTC
Created attachment 14140 [details]
i830_drv.c from ubntu Gutsy (2:2.1.1-0ubuntu9)

Am using Ubuntu Gutsy with driver version 2:2.1.1-0ubuntu9(gutsy).  This has been raised as a downstream bug in https://bugs.launchpad.net/ubuntu/+source/xserver-xorg-video-intel/+bug/135093

The code block mentioned previously does not appear in the file; it only references a module called ch7xxx.  Would you review the module source (attached) and comment if this is correct.
Comment 43 Hong Liu 2008-02-04 17:51:41 UTC
(In reply to comment #42)
> Created an attachment (id=14140) [details]
> i830_drv.c from ubntu Gutsy (2:2.1.1-0ubuntu9)
> 
The ch7017 related code has been commented out. Would you please try the upstream driver. You can get it by
$ git-clone git://anongit.freedesktop.org/git/xorg/driver/xf86-video-intel

Thanks,
Hong
Comment 44 Shofi Islam 2008-02-06 12:23:05 UTC
Created attachment 14179 [details]
Xorg.0.log using recompiled driver

The latest driver works, but all 3D ability is now gone. glxinfo reports no direct rendering.
Comment 45 Shofi Islam 2008-02-06 12:30:51 UTC
Created attachment 14180 [details]
glxinfo

libGL error: drmMap of framebuffer failed (Invalid argument)
libGL error: reverting to (slow) indirect rendering

Apologies if it seems I'm spamming this bug.  I'm keen to help fix this.
Comment 46 Shofi Islam 2008-02-09 11:23:45 UTC
Tested liveCD of Ubuntu Hardy alpha 4 with the latest drivers.  Intel driver now working with ch7017 chipset and acceleration. 
Comment 47 Gordon Jin 2008-02-12 19:36:17 UTC
Good to know this works now. So I'm closing this one.


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.