Since the update of libdrm to 2.4.102 my graphics device is no longer recognized by mesa. The mesa-libs then fall back on the i915-dri-driver on my system. But there is an Intel i965GM in my system. If an OpenGL application is started now, I get a black screen and can only reset the laptop to get a display again. The following error is logged in messages. error: [drm:pid12:i915_hangcheck_hung] *ERROR* Hangcheck timer elapsed... GPU hung This is of course due to the wrong driver. If I force the correct driver using the environment variable MESA_LOADER_DRIVER_OVERRIDE=i965, the OpenGL applications work again.
Can you check that it actually is getting to use any driver when you try to force a driver, and doesn't just fall back to software rendering? From a kernel perspective, there is just the i915kms.ko driver, which provides support for all Intel GPUs. mesa has both i915_dri.so and i965_dri.so. Are there any error messages from libdrm, or any hints at all on what has changed? libdrm does not in itself pick a driver iirc, it is mesa which decides on i915 or i965 (or any other).
If I set the environment variable or use the old libdrm again, mesa uses the i965_dri.so. With the new libdrm and without the environment variable set, mesa uses the i915_dri.so, which then leads to the error. In my opinion, libdrm is used to recognize the dri device and that doesn't work for me with the new version. But with the new libdrm I cannot find any error messages directly from libdrm anywhere.
Oh, I still have one more important hint. I loaded the kernel module from the drm-legacy-kmod package because the module from the drm-fbsd12.0-kmod package cannot be loaded on my laptop.
Can you give your pci id please ? (pciconf -vl vgapci0) Thanks.
There has been almost the same problem before. https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=217585 Here then libdrm was patched (patch-xf86drm.c). This patch has been removed with the version change to 2.4.102.
(In reply to Emmanuel Vadot from comment #4) Unfortunately I can't do that until tonight.
Here the output of pciconf: vgapci0@pci0:0:2:0: class=0x030000 card=0x011f1025 chip=0x2a028086 rev=0x03 hdr=0x00 vendor = 'Intel Corporation' device = 'Mobile GM965/GL960 Integrated Graphics Controller (primary)' class = display subclass = VGA
I have now got the kernel module from the drm-fbsd12.0-kmod package running. Therefore I can now say that the problem only occurs with the legacy module. But since the current mesa-dri drivers no longer work with the legacy module anyway (at least not without reactivating an old patch), I'll close the bugreport here.