Bug 610352

Summary: Black screen during installation due to enabled (broken) KMS and native driver being the default
Product: [openSUSE] openSUSE 11.3 Reporter: Jan Engelhardt <jengelh>
Component: X.OrgAssignee: Stefan Dirsch <sndirsch>
Status: RESOLVED FIXED QA Contact: E-mail List <xorg-maintainer-bugs>
Severity: Critical    
Priority: P1 - Urgent CC: eich, snwint
Version: Factory   
Target Milestone: ---   
Hardware: x86   
OS: Linux   
Whiteboard:
Found By: Beta-Customer Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: System description
/var/log/Xorg.0.log from the factory installer
Log from boot with KMS enabled, and defective Xorg

Description Jan Engelhardt 2010-05-31 11:24:22 UTC
I have here a machine where Xorg works without a problem - as evidenced by getting the graphical installer with openSUSE 11.2/Kernel 2.6.31.

In current Factory however with kernel 2.6.34 (it also affects openSUSE 11.2's Xorg 7.4 with 2.6.33), Xorg generates no picture anymore. Disabling KMS by using the "i915.modeset=0" boot parameter yields no improvement.

Please advise.
Comment 1 Jan Engelhardt 2010-05-31 11:25:20 UTC
Created attachment 365794 [details]
System description

/var/log/boot.msg with kernel bootup log
dmidecode
hwinfo
/proc/cpuinfo
/proc/interrupts
Comment 2 Jan Engelhardt 2010-05-31 11:25:55 UTC
Created attachment 365796 [details]
/var/log/Xorg.0.log from the factory installer
Comment 3 Jan Engelhardt 2010-05-31 11:29:37 UTC
Minor correction, with i915.modeset=0 factory works, but that's really a hack, isn't it.
Comment 4 Jan Engelhardt 2010-05-31 11:33:32 UTC
Created attachment 365802 [details]
Log from boot with KMS enabled, and defective Xorg

Optional comment: I was expecting the optional criss-cross pattern to show up, but it looks like Xorg is configured to use a black background these days. Anyway, I started xterm on the same $DISPLAY to confirm that Xorg outputs a picture - or not.
Comment 5 Stefan Dirsch 2010-05-31 12:48:52 UTC
So apparently at least fbdev driver works. Could you try with 'nomodeset' and "intellegacy" driver in /etc/X11/xorg.conf.d/50-device.conf?
Comment 6 Jan Engelhardt 2010-05-31 13:16:01 UTC
Factory Net-Installer:

nomodeset + intel: same as i915.modeset=0 (works)

modeset + intellegacy: there is no 50-device.conf inside the image of /factory/repo/oss/boot/i386/root.


openSUSE 11.2 Xorg 7.5_1.8.0 + xorg-x11-driver-video-intel-legacy-2.9.1-1.1.i586:

nomodeset + intel: works

nomodeset + intellegacy: kills the machine (hard lockup, no interrupts enabled)

modeset + intellegacy: screen remains without graphics
Comment 7 Stefan Dirsch 2010-05-31 13:30:58 UTC
(In reply to comment #6)
> Factory Net-Installer:
> 
> nomodeset + intel: same as i915.modeset=0 (works)

You mean nomodeset + fbedev (nomodeset + intel is not possible since intel
requires KMS).

> modeset + intellegacy: there is no 50-device.conf inside the image of
> /factory/repo/oss/boot/i386/root.

No idea what you're talking about. I'm talking about an installed system. During installation fbdev is used anyway. You don't talk about a LiveCD here, do you? At least I didn't see it mentioned anywhere.

> openSUSE 11.2 Xorg 7.5_1.8.0 +
> xorg-x11-driver-video-intel-legacy-2.9.1-1.1.i586:

There is no need to run intellegacy on openSUSE 11.2, since the intel driver
on 11.2 doesn't required KMS yet.
Comment 8 Jan Engelhardt 2010-05-31 13:39:12 UTC
>You mean nomodeset + fbedev

Yes. Or actually VESA(2), since that's what shows up in Xorg.0.log a lot.

>I'm talking about an installed system.
>During installation fbdev is used anyway.

All attached logs here are from the installer _only_. (I didn't get to install it yet because I ran into this issue.) No LiveCD.

* This is /factory/repo/oss/boot/i386/{linux,initrd} PXE-booted
* selecting Settings > "Shell Enabled Before YaST"
* either continue with yast, or manually start X from sh to trigger.
Comment 9 Stefan Dirsch 2010-05-31 13:42:00 UTC
So you disabled kernel framebuffer and stumble across a not-working vesa driver?
Comment 10 Stefan Dirsch 2010-05-31 13:42:53 UTC
Does installation work with fbdev driver (by adding kernel framebuffer)?
Comment 11 Jan Engelhardt 2010-05-31 13:56:51 UTC
By default, the system boots in 80x25 text mode. I suppose this is because only the CD-ROM bootloader defaults to passing vga=0x31X behind my back.

1. With KMS, the kernel switches to graphics mode once udev gets to load the kernel module. The mode looks like 1280x1024, but text is confined to an 80x25/80x30 area in the upper left. The installer uses the "intel" driver, as evidenced by attachment to comment #4. This fails to produce a picture.

2. With i915.modeset=0 or nomodeset, boot proceeds in 80x25 mode until yast2, where the Factory installer/Xorg chooses VESA (with an appropriate resolution; was either 1024x768 or 1280), as seen in attachment to comment #2. This works.

3. Booting with vga=0x317 nomodeset: kernel switches to graphics mode on early boot. /var/log/Xorg.0.log indicates Xorg is using FBDEV(0). Looks like 1024x768. This works too.

4. Booting with vga=0x317: kernel switches to graphics mode on early boot (vesafb) 1024x768. Once udev loads, everything goes exactly like (1). Fails.
Comment 12 Stefan Dirsch 2010-05-31 15:05:42 UTC
(In reply to comment #11)
> By default, the system boots in 80x25 text mode. I suppose this is because 
> only the CD-ROM bootloader defaults to passing vga=0x31X behind my back.

Sure, if you configure PXE boot way ...

> 1. With KMS, the kernel switches to graphics mode once udev gets to load the
> kernel module. The mode looks like 1280x1024, but text is confined to an
> 80x25/80x30 area in the upper left. The installer uses the "intel" driver, as
> evidenced by attachment to comment #4. This fails to produce a picture.

No idea why we now have KMS during installation active. We didn't want this.
Also apparently the /etc/X11/xorg.conf is not available during installation,
which should make sure that fbdev driver is used instead of the native driver.
Not your fault, of course ...
 
> 2. With i915.modeset=0 or nomodeset, boot proceeds in 80x25 mode until yast2,
> where the Factory installer/Xorg chooses VESA (with an appropriate resolution;
> was either 1024x768 or 1280), as seen in attachment to comment #2. This works.

Ok. So vesa driver does work.
 
> 3. Booting with vga=0x317 nomodeset: kernel switches to graphics mode on early
> boot. /var/log/Xorg.0.log indicates Xorg is using FBDEV(0). Looks like
> 1024x768. This works too.

So fbdev driver does work as well.

> 4. Booting with vga=0x317: kernel switches to graphics mode on early boot
> (vesafb) 1024x768. Once udev loads, everything goes exactly like (1). Fails.

KMS already break the graphics. fbdev driver cannot work any longer after
KMS is initialized.

I see 3 issues here:

1) KMS doesn't work on Intel 855GM.
2) KMS during installation is our default.
3) /etc/X11/xorg.conf is no longer available during installation.

I'll try to verify these issues here.
Comment 13 Stefan Dirsch 2010-05-31 16:29:01 UTC
Mixed results here. Indeed KMS gets enabled on intel, i.e. intel-agp, i915, drm, drm_kms_helper gets loaded, but as driver "fbdev" is used (/etc/X11/xorg.conf exists and specifies fbdev as first driver option). Same applies to NVIDIA (nouveau, see also http://en.opensuse.org/Bugs:Most_Annoying_Bugs_11.3_dev) and ATI (radeon).

I asked Steffen to remove the modules below kernel/drivers/gpu/drm (apart from drm, which is apparently required by vboxvideo).
Comment 14 Stefan Dirsch 2010-05-31 16:39:36 UTC
Hmm. /lib/udev/rules.d/79-kms.rules should already make sure that no DRM modules
are loaded.
Comment 15 Stefan Dirsch 2010-05-31 16:40:23 UTC
(In reply to comment #14)
> Hmm. /lib/udev/rules.d/79-kms.rules should already make sure that no DRM
> modules are loaded.

(which is part of initrd from installation)
Comment 17 Steffen Winterfeldt 2010-05-31 16:44:37 UTC
From which package is this rule?
Comment 18 Stefan Dirsch 2010-05-31 16:55:20 UTC
(In reply to comment #17)
> From which package is this rule?

--> udev (it's already available during installation)
Comment 20 Stefan Dirsch 2010-05-31 19:10:17 UTC
(In reply to comment #13)
> I asked Steffen to remove the modules below kernel/drivers/gpu/drm (apart from
> drm, which is apparently required by vboxvideo).

That's now submitted to openSUSE:Factory.

40928  State:new     By:snwint       When:2010-05-31T18:41:20
        submit: system:install:head/installation-images -> 
                openSUSE:Factory       
        Descr:  - libopenssl moved to /lib*
                - sndirsch: remove kms support (bnc #610352)

I cannot reproduce the bug that the native driver is used during
installation. fbdev is always used (verified with intel, nvidia, and radeon
graphics).