#768045 libdrm-intel1 2.4.58 prevent steam games to be launched on optimus system

Package:
libdrm-intel1
Source:
libdrm
Description:
Userspace interface to intel-specific kernel DRM services -- runtime
Submitter:
Hadrien DUSSUEL
Date:
2015-03-01 20:51:14 UTC
Severity:
normal
#768045#5
Date:
2014-11-04 13:31:16 UTC
From:
To:
Upgrading libdrm-intel1 from 2.4.56 to 2.4.58 broke the ability to launch steam games on optimus system (using bumblebee and primus). Most games does not start without any error message from steam console.

This thread (https://github.com/ValveSoftware/steam-for-linux/issues/3506) lead me to this package. Downgrading to 2.4.56 fix the problem.

Except this, bumblebee work as expected.
------------
lspci:
00:02.0 VGA compatible controller: Intel Corporation 2nd Generation Core Processor Family Integrated Graphics Controller (rev 09)
01:00.0 VGA compatible controller: NVIDIA Corporation GF108M [GeForce GT 540M] (rev ff)
------------ dpkg status: hadrien@hadrien-portable:~$ dpkg --status libdrm-intel1:amd64 Package: libdrm-intel1 Status: install ok installed Priority: optional Section: libs Installed-Size: 194 Maintainer: Debian X Strike Force <debian-x@lists.debian.org> Architecture: amd64 Multi-Arch: same Source: libdrm Version: 2.4.58-2 Depends: libc6 (>= 2.17), libdrm2 (>= 2.4.38), libpciaccess0 Pre-Depends: multiarch-support Description: Userspace interface to intel-specific kernel DRM services -- runtime This library implements the userspace interface to the kernel DRM services. DRM stands for "Direct Rendering Manager", which is the kernelspace portion of the "Direct Rendering Infrastructure" (DRI). The DRI is currently used on Linux to provide hardware-accelerated OpenGL drivers. hadrien@hadrien-portable:~$ dpkg --status libdrm-intel1:i386 Package: libdrm-intel1 Status: install ok installed Priority: optional Section: libs Installed-Size: 169 Maintainer: Debian X Strike Force <debian-x@lists.debian.org> Architecture: i386 Multi-Arch: same Source: libdrm Version: 2.4.58-2 Depends: libc6 (>= 2.17), libdrm2 (>= 2.4.38), libpciaccess0 Pre-Depends: multiarch-support Description: Userspace interface to intel-specific kernel DRM services -- runtime This library implements the userspace interface to the kernel DRM services. DRM stands for "Direct Rendering Manager", which is the kernelspace portion of the "Direct Rendering Infrastructure" (DRI). The DRI is currently used on Linux to provide hardware-accelerated OpenGL drivers.
------------ syslog: // starting steam then starting portal 2 with "primusrun %command%" as launch argument Nov 4 11:22:44 hadrien-portable steam.desktop[32058]: Running Steam on debian 64-bit Nov 4 11:22:44 hadrien-portable steam.desktop[32058]: STEAM_RUNTIME has been set by the user to: /home/hadrien/.steam/ubuntu12_32/steam-runtime Nov 4 11:22:49 hadrien-portable kernel: [ 4989.373023] bbswitch: enabling discrete graphics Nov 4 11:22:50 hadrien-portable systemd-udevd[219]: Network interface NamePolicy= disabled on kernel commandline, ignoring. Nov 4 11:22:50 hadrien-portable kernel: [ 4990.582807] vgaarb: device changed decodes: PCI:0000:01:00.0,olddecodes=none,decodes=none:owns=none Nov 4 11:22:50 hadrien-portable kernel: [ 4990.583041] [drm] Initialized nvidia-drm 0.0.0 20130102 for 0000:01:00.0 on minor 1 Nov 4 11:22:50 hadrien-portable kernel: [ 4990.583045] NVRM: loading NVIDIA UNIX x86_64 Kernel Module 340.46 Wed Sep 24 14:23:40 PDT 2014 Nov 4 11:22:50 hadrien-portable systemd-udevd[219]: unknown key 'BUS' in /etc/udev/rules.d/ft-rockey.rules:1 Nov 4 11:22:50 hadrien-portable systemd-udevd[219]: invalid rule '/etc/udev/rules.d/ft-rockey.rules:1' Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: removing GPU device /sys/devices/pci0000:00/0000:00:01.0/0000:01:00.0/drm/card1 /dev/dri/card1 Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: (II) config/udev: Adding drm device (/dev/dri/card1) Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: (II) xfree86: Adding drm device (/dev/dri/card1) Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: (II) LoadModule: "modesetting" Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: (II) Loading /usr/lib/xorg/modules/drivers/modesetting_drv.so Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: (II) Module modesetting: vendor="X.Org Foundation" Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: compiled for 1.15.99.904, module version = 0.9.0 Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: Module class: X.Org Video Driver Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: ABI class: X.Org Video Driver, version 18.0 Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: (II) UnloadModule: "modesetting" Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: (II) Unloading modesetting Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: (II) Failed to load module "modesetting" (already loaded, 32536) Nov 4 11:22:50 hadrien-portable gdm-Xorg-:0[789]: xf86: found device 1 Nov 4 11:22:55 hadrien-portable systemd-udevd[219]: Network interface NamePolicy= disabled on kernel commandline, ignoring. Nov 4 11:22:55 hadrien-portable kernel: [ 4995.398240] nvidia 0000:01:00.0: irq 53 for MSI/MSI-X Nov 4 11:22:55 hadrien-portable kernel: [ 4995.402988] ACPI Warning: \_SB_.PCI0.PEGR.GFX0._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20140424/nsarguments-95) Nov 4 11:22:55 hadrien-portable kernel: [ 4995.403063] ACPI Warning: \_SB_.PCI0.PEGR.GFX0._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20140424/nsarguments-95) Nov 4 11:22:55 hadrien-portable kernel: [ 4995.403100] ACPI Warning: \_SB_.PCI0.PEGR.GFX0._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20140424/nsarguments-95) Nov 4 11:22:55 hadrien-portable kernel: [ 4995.403132] ACPI Warning: \_SB_.PCI0.PEGR.GFX0._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20140424/nsarguments-95) Nov 4 11:22:55 hadrien-portable kernel: [ 4995.403164] ACPI Warning: \_SB_.PCI0.PEGR.GFX0._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20140424/nsarguments-95) Nov 4 11:22:55 hadrien-portable kernel: [ 4995.403195] ACPI Warning: \_SB_.PCI0.PEGR.GFX0._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20140424/nsarguments-95) Nov 4 11:22:55 hadrien-portable kernel: [ 4995.403312] ACPI Warning: \_SB_.PCI0.PEGR.GFX0._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20140424/nsarguments-95) Nov 4 11:22:55 hadrien-portable kernel: [ 4995.403345] ACPI Warning: \_SB_.PCI0.PEGR.GFX0._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20140424/nsarguments-95) Nov 4 11:22:55 hadrien-portable systemd-udevd[219]: unknown key 'BUS' in /etc/udev/rules.d/ft-rockey.rules:1 Nov 4 11:22:55 hadrien-portable systemd-udevd[219]: invalid rule '/etc/udev/rules.d/ft-rockey.rules:1' Nov 4 11:22:56 hadrien-portable kernel: [ 4996.582801] ACPI Warning: \_SB_.PCI0.PEGR.GFX0._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20140424/nsarguments-95) Nov 4 11:22:56 hadrien-portable systemd-udevd[219]: Network interface NamePolicy= disabled on kernel commandline, ignoring. Nov 4 11:22:56 hadrien-portable systemd-udevd[219]: unknown key 'BUS' in /etc/udev/rules.d/ft-rockey.rules:1 Nov 4 11:22:56 hadrien-portable systemd-udevd[219]: invalid rule '/etc/udev/rules.d/ft-rockey.rules:1' Nov 4 11:22:56 hadrien-portable acpid: client connected from 32286[0:999] Nov 4 11:22:56 hadrien-portable acpid: 1 client rule loaded Nov 4 11:22:59 hadrien-portable bumblebeed[665]: [ 4994.157922] [ERROR][XORG] (EE) /dev/dri/card0: failed to set DRM interface version 1.4: Permission denied Nov 4 11:22:59 hadrien-portable bumblebeed[665]: [ 4994.157969] [WARN][XORG] (WW) Unresolved symbol: fbGetGCPrivateKey Nov 4 11:22:59 hadrien-portable bumblebeed[665]: [ 4994.158002] [WARN][XORG] (WW) NVIDIA(0): Unable to get display device for DPI computation. Nov 4 11:22:59 hadrien-portable bumblebeed[665]: [ 4994.158040] [ERROR][XORG] (EE) /dev/dri/card0: failed to set DRM interface version 1.4: Permission denied Nov 4 11:22:59 hadrien-portable systemd-udevd[219]: Network interface NamePolicy= disabled on kernel commandline, ignoring. Nov 4 11:22:59 hadrien-portable kernel: [ 5000.077908] [drm] Module unloaded Nov 4 11:22:59 hadrien-portable kernel: [ 5000.079956] bbswitch: disabling discrete graphics Nov 4 11:22:59 hadrien-portable kernel: [ 5000.079971] ACPI Warning: \_SB_.PCI0.PEGR.GFX0._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20140424/nsarguments-95) Nov 4 11:22:59 hadrien-portable systemd-udevd[219]: unknown key 'BUS' in /etc/udev/rules.d/ft-rockey.rules:1 Nov 4 11:22:59 hadrien-portable systemd-udevd[219]: invalid rule '/etc/udev/rules.d/ft-rockey.rules:1' Nov 4 11:22:59 hadrien-portable gdm-Xorg-:0[789]: removing GPU device /sys/devices/pci0000:00/0000:00:01.0/0000:01:00.0/drm/card1 /dev/dri/card1 Nov 4 11:22:59 hadrien-portable kernel: [ 5000.092653] pci 0000:01:00.0: Refused to change power state, currently in D0 Nov 4 11:22:59 hadrien-portable bumblebeed[665]: [ 4994.869414] [ERROR][XORG] (EE) Server terminated successfully (0). Closing log file.
#768045#10
Date:
2014-11-25 20:08:09 UTC
From:
To:
I have exactly the same problem. Steam error log shows

  malloc: unknown:0: assertion botched
  free: called with unallocated block argument

for the games that do not running using "optirun steam" or editing the
launch settings for each game.

I've not tried downgrading to an older version of the libdrm intel
package however as editing the shell script for each game to run optirun
prior to the ${DEBUGGER} arg seems to also work. Not an ideal solution
but it saves downgrading a package.

I'm running Debian Jessie with a Geforce 850M and optimus using
bumblebee and either optirun or primusrun. I also have the same
libdrm-intel package version installed as the OP.

Regards,

Gary

#768045#15
Date:
2014-12-08 18:50:10 UTC
From:
To:
I also experience this issue. A workaround is to downgrade libdrm-intel1
to 2.4.56-1, plus the other related dependencies: libdrm2, libdrm-dev,
libdrm-nouveau2 and libdrm-radeon1. For people with this issue, you cand
find them here:
http://snapshot.debian.org/archive/debian/20140810T163814Z/pool/main/libd/libdrm/

I think that while this isn't fixed in 2.4.58, 2.4.56 should be
installed by defaut.

#768045#20
Date:
2014-12-26 14:06:52 UTC
From:
To:
Good news ! This bug has been fixed by the nvidia non-free driver update
340.65-1:
http://metadata.ftp-master.debian.org/changelogs//non-free/n/nvidia-graphics-drivers/nvidia-graphics-drivers_340.65-2_changelog
" - Fixed a regression that caused displays to be detected incorrectly
on some notebook systems.  (Closes: #770798, #765726)"

Obviously, the latest intel driver had incompatibilities with the nvidia
driver.

This bug could be closed.

#768045#25
Date:
2014-12-27 09:59:59 UTC
From:
To:
I upgraded nvidia-driver to 340.65-2 and reinstalled libdrm-intel1 2.4.58-2
and launching Steam games through optirun still doesn't work.

#768045#30
Date:
2015-03-01 20:49:46 UTC
From:
To:
I did a bisect and it came up to this commit:

ae8edc7544e566084f7b958eb93c9109b471ca30 is the first bad commit
commit ae8edc7544e566084f7b958eb93c9109b471ca30
Author: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Date:   Thu Jun 19 15:52:03 2014 +0100

    intel: Add support for userptr objects

    Allow userptr objects to be created and used via libdrm_intel.

    At the moment tiling and mapping to GTT aperture is not supported
    due hardware limitations across different generations and uncertainty
    about its usefulness.

    v2: Improved error handling in feature detection per review comments.

    v3: Rebase on top of the drm_public addition, minor whitespace addition.

    Reviewed-by: Damien Lespiau <damien.lespiau@intel.com>
    Signed-off-by: Damien Lespiau <damien.lespiau@intel.com> (v3)
    Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com> (v1,v2)

:040000 040000 5b1f4eecbdd1cf2c57d7da9388384c17e8448bee
b41b6afa071dc408dcaf7a4c6dcfecc2d7413c73 M intel