Ubuntu

[i915] xserver freeze on switching VGA1/LVDS1

Reported by Max on 2012-05-01
24
This bug affects 4 people
Affects Status Importance Assigned to Milestone
xserver-xorg-video-intel (Fedora)
New
Undecided
Unassigned
xserver-xorg-video-intel (Ubuntu)
Undecided
Timo Aaltonen
Precise
Undecided
Timo Aaltonen

Bug Description

I can easily freeze xserver on my Asus F80L laptop
with just installed Ubuntu 12.04
when the external monitor (LG L2000CP) is connected:

xrandr --output LVDS1 --off --output VGA1 --auto
xrandr --output VGA1 --off --output LVDS1 --auto
xrandr --output LVDS1 --off --output VGA1 --auto

Here the both screens are dark, so I have to switch
to a console and back (Ctrl+Alt+F1, Ctrl-Alt+F7).
No errors in Xorg.0.log and /sys/kernel/debug/dri/0/i915_error_state,
but a new line in dmesg:
[ 1564.394016] [drm:drm_mode_getfb] *ERROR* invalid framebuffer id

Before the next command I run a script which collects some info a minute later

xrandr --output VGA1 --off --output LVDS1 --auto

The both screens become dark again, but now the keyboard does not work
(except magic SysRq keys).

i915_error_state:
no error state collected

Xorg.0.log last lines:
[ 199.873] (II) intel(0): Allocated new frame buffer 1280x800 stride 5120, tiled
[ 199.943] (WW) intel(0): I830DRI2ScheduleWaitMSC:1372 get vblank counter failed: Invalid argument
[ 199.951] (WW) intel(0): I830DRI2GetMSC:1305 get vblank counter failed: Invalid argument
[ 199.972] (WW) intel(0): I830DRI2GetMSC:1305 get vblank counter failed: Invalid argument
[ 200.227] (WW) intel(0): I830DRI2GetMSC:1305 get vblank counter failed: Invalid argument
[ 200.320] (WW) intel(0): I830DRI2GetMSC:1305 get vblank counter failed: Invalid argument
[ 200.320] (WW) intel(0): first get vblank counter failed: Invalid argument
[ 200.328] (WW) intel(0): I830DRI2GetMSC:1305 get vblank counter failed: Invalid argument
[ 200.328] (WW) intel(0): first get vblank counter failed: Invalid argument

dmesg last lines
[ 1564.394016] [drm:drm_mode_getfb] *ERROR* invalid framebuffer id
[ 1698.464156] [drm:i915_hangcheck_elapsed] *ERROR* Hangcheck timer elapsed... GPU hung
[ 1698.464167] [drm:kick_ring] *ERROR* Kicking stuck wait on render ring
[ 1699.968169] [drm:i915_hangcheck_elapsed] *ERROR* Hangcheck timer elapsed... GPU hung
[ 1699.968180] [drm:kick_ring] *ERROR* Kicking stuck wait on render ring
[ 1701.472155] [drm:i915_hangcheck_elapsed] *ERROR* Hangcheck timer elapsed... GPU hung
[ 1701.472163] [drm:kick_ring] *ERROR* Kicking stuck wait on render ring
(many times)

System info:
Asus F80L laptop

lsb_release -rd
Description: Ubuntu 12.04 LTS
Release: 12.04

uname -a
Linux dfb 3.2.0-24-generic-pae #37-Ubuntu SMP Wed Apr 25 10:47:59 UTC 2012 i686 i686 i386 GNU/Linux

lspci:
00:00.0 Host bridge: Intel Corporation Mobile PM965/GM965/GL960 Memory Controller Hub (rev 03)
00:02.0 VGA compatible controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (primary) (rev 03)
00:02.1 Display controller: Intel Corporation Mobile GM965/GL960 Integrated Graphics Controller (secondary) (rev 03)
00:1a.0 USB controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #4 (rev 04)
00:1a.1 USB controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #5 (rev 04)
00:1a.7 USB controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #2 (rev 04)
00:1b.0 Audio device: Intel Corporation 82801H (ICH8 Family) HD Audio Controller (rev 04)
00:1c.0 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 1 (rev 04)
00:1c.1 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 2 (rev 04)
00:1c.2 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 3 (rev 04)
00:1c.3 PCI bridge: Intel Corporation 82801H (ICH8 Family) PCI Express Port 4 (rev 04)
00:1d.0 USB controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #1 (rev 04)
00:1d.1 USB controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #2 (rev 04)
00:1d.2 USB controller: Intel Corporation 82801H (ICH8 Family) USB UHCI Controller #3 (rev 04)
00:1d.7 USB controller: Intel Corporation 82801H (ICH8 Family) USB2 EHCI Controller #1 (rev 04)
00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev f4)
00:1f.0 ISA bridge: Intel Corporation 82801HM (ICH8M) LPC Interface Controller (rev 04)
00:1f.1 IDE interface: Intel Corporation 82801HM/HEM (ICH8M/ICH8M-E) IDE Controller (rev 04)
00:1f.2 SATA controller: Intel Corporation 82801HM/HEM (ICH8M/ICH8M-E) SATA Controller [AHCI mode] (rev 04)
01:00.0 Ethernet controller: Realtek Semiconductor Co., Ltd. RTL8101E/RTL8102E PCI Express Fast Ethernet controller (rev 01)
02:00.0 Network controller: Atheros Communications Inc. AR928X Wireless Network Adapter (PCI-Express) (rev 01)

xrandr
Screen 0: minimum 320 x 200, current 2880 x 1200, maximum 8192 x 8192
LVDS1 connected 1280x800+0+0 (normal left inverted right x axis y axis) 304mm x 190mm
   1280x800 60.0*+
   1024x768 60.0
   800x600 60.3 56.2
   640x480 59.9
VGA1 connected 1600x1200+1280+0 (normal left inverted right x axis y axis) 408mm x 306mm
   1600x1200 59.8*+
   1280x1024 75.0 60.0
   1152x864 75.0
   1024x768 85.0 75.1 60.0
   832x624 74.6
   800x600 85.1 75.0 60.3
   640x480 75.0 60.0 59.9
   720x400 70.1

Full dmesg and Xorg logs are attached.

Max (m-gorodok) wrote :
Max (m-gorodok) wrote :
bugbot (bugbot) on 2012-05-03
tags: added: freeze
Max (m-gorodok) wrote :

I can add more info.

1. I can not reproduce freeze if I stop lightdm and launch just xterm

startx /usr/bin/startx

Although when I switch between LVDS1 and VGA1

xrandr --output LVDS1 --off --output VGA1 --auto
xrandr --output VGA1 --off --output LVDS1 --auto

approximately in a half of cases I get blank screen. I can restore the image by switching to a console [Ctrl+Alt+F1] and back.
I do not see any errors in dmesg or Xorg.0.log

2. I have not managed to reproduce freeze in unity-2d when only xterm is running. The problem with blank screen persists. After several switching I have noticed

[drm:drm_mode_getfb] *ERROR* invalid framebuffer id

in dmesg output. More switching leads to more such lines.
At certain moment

xrandr --output VGA1 --off --output LVDS1 --auto

failed with the following error:
xrandr: cannot find crtc for output LVDS1

Nothing unusual in xrandr output:

xrandr
Screen 0: minimum 320 x 200, current 1600 x 1200, maximum 8192 x 8192
LVDS1 connected (normal left inverted right x axis y axis)
   1280x800 60.0 +
   1024x768 60.0
   800x600 60.3 56.2
   640x480 59.9
VGA1 connected 1600x1200+0+0 (normal left inverted right x axis y axis) 408mm x 306mm
   1600x1200 59.8*+
   1280x1024 75.0 60.0
   1152x864 75.0
   1024x768 85.0 75.1 60.0
   832x624 74.6
   800x600 85.1 75.0 60.3
   640x480 75.0 60.0 59.9
   720x400 70.1

Surprisingly [Fn+F6] switched image to internal screen and xrandr started to work again.

I am afraid that some applications will be able to freeze X server even when unity-2d is running.

Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in xserver-xorg-video-intel (Ubuntu):
status: New → Confirmed
Pawel Stolowski (stolowski) wrote :

I've similar problem when using xrandr to setup my laptop screen and external LG monitor (HDMI):
xrandr --output HDMI1 --primary --mode 1920x1080 --right-of LVDS1 --output LVDS1 --mode 1600x900

However in my case I'm experiencing hard freeze and am not able to switch to VT.

Max (m-gorodok) wrote :

The story with the latest kernel and xserver-xorg-video-intel:
https://bugs.freedesktop.org/show_bug.cgi?id=50010

bugbot (bugbot) on 2012-05-31
tags: added: precise
naut (naut) wrote :

I have experienced this bug on my laptop with every version of Ubuntu since 11.04 at least (I'm not certain if it occurred in 10.10). For this reason I am still running 10.04 where it does not occur. It also happens in Kubuntu and in Fedora 17.

I have my laptop lugged into an external monitor via HDMI most of the time. The problem usually starts when I switch to just the external display, with the laptop screen off. Behaviour appears normal for a few second to a couple of minutes. Then the mouse and keyboard stop responding, and eventuall y the screen will flash and go dark.

Sometimes I am able to switch to a non-X terminal and do a soft restart. Other times I will not be able to do that and have to just power down.

My Xorg log is attached.

My background is Java not C, but I'm more than happy to try to provide extra info or run tests if that would be helpful.

        *-display:0
             description: VGA compatible controller
             product: Mobile GM965/GL960 Integrated Graphics Controller
             vendor: Intel Corporation
             physical id: 2
             bus info: pci@0000:00:02.0
             version: 0c
             width: 64 bits
             clock: 33MHz
             capabilities: bus_master cap_list rom
             configuration: driver=i915 latency=0
             resources: irq:29 memory:fea00000-feafffff memory:e0000000-efffffff(prefetchable) ioport:eff8(size=8)
        *-display:1 UNCLAIMED
             description: Display controller
             product: Mobile GM965/GL960 Integrated Graphics Controller
             vendor: Intel Corporation
             physical id: 2.1
             bus info: pci@0000:00:02.1
             version: 0c
             width: 64 bits
             clock: 33MHz
             capabilities: bus_master cap_list
             configuration: latency=0
             resources: memory:feb00000-febfffff

agpgart 31724 2 drm,intel_agp
drm 163779 3 i915,drm_kms_helper
drm_kms_helper 29329 1 i915
i2c_algo_bit 5028 1 i915
i915 290035 2
intel_agp 24375 2 i915
output 1871 1 video
vga16fb 11385 0
vgastate 8961 1 vga16fb
video 17375 1 i915

bruce@mars:~$ uname -a
Linux mars 2.6.32-41-generic #91-Ubuntu SMP Wed Jun 13 11:44:43 UTC 2012 i686 GNU/Linux

naut (naut) wrote :
Timo Aaltonen (tjaalton) wrote :

The commit referenced in upstream bug 50078 has been included in an upload to precise-proposed, so once it's accepted there, please enable -proposed and test the package. Thanks!

Changed in xserver-xorg-video-intel (Ubuntu):
assignee: nobody → Timo Aaltonen (tjaalton)
status: Confirmed → In Progress

Hello Max, or anyone else affected,

Accepted xserver-xorg-video-intel into precise-proposed. The package will build now and be available at http://launchpad.net/ubuntu/+source/xserver-xorg-video-intel/2:2.17.0-1ubuntu4.2 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please change the bug tag from verification-needed to verification-done. If it does not, change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

tags: added: verification-needed
Changed in xserver-xorg-video-intel (Ubuntu Precise):
status: New → Fix Committed
assignee: nobody → Timo Aaltonen (tjaalton)
Timo Aaltonen (tjaalton) wrote :

closing for quantal, should be fixed there

Changed in xserver-xorg-video-intel (Ubuntu):
status: In Progress → Fix Released
Timo Aaltonen (tjaalton) wrote :

Hey, if you won't test the package from -proposed, the fix will have to be dropped, since there's another bug waiting for this one (bug 966744) that needs to get to -updates soon.

naut (naut) wrote :

This fix works for me

Timo Aaltonen (tjaalton) on 2012-10-16
tags: added: verification-done
removed: verification-needed

The verification of this Stable Release Update has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regresssions.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package xserver-xorg-video-intel - 2:2.17.0-1ubuntu4.2

---------------
xserver-xorg-video-intel (2:2.17.0-1ubuntu4.2) precise-proposed; urgency=low

  * Add 106-uxa-only-consider-attached-outputs-valid.patch, two upstream
    commits merged together that fix GPU hangs on resume, due to outputs
    getting marked valid before the kernel reports them attached.
    (LP: #992391)
  * Replace 101_copy-fb.patch with the patch that went upstream, backported
    to build against the older xserver. Needed for other backports.
    - refreshed patch 104 to apply.
  * Add 107-uxa-fix-pageflip-race.patch, fixes a race with pageflip and
    dpms, resulting in for instance compiz hanging. (LP: #966744)
    - consists of five upstream commits merged as one and backported to
      build against the xserver in precise
 -- Timo Aaltonen <email address hidden> Fri, 05 Oct 2012 22:40:38 +0300

Changed in xserver-xorg-video-intel (Ubuntu Precise):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.