Bug 112040 - __kgem_bo_map__cpu:697 assertion 'err != -EINVAL || bo->prime' failed
Summary: __kgem_bo_map__cpu:697 assertion 'err != -EINVAL || bo->prime' failed
Status: RESOLVED MOVED
Alias: None
Product: xorg
Classification: Unclassified
Component: Driver/intel (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) OpenBSD
: not set not set
Assignee: Chris Wilson
QA Contact: Intel GFX Bugs mailing list
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-10-17 13:10 UTC by Mikolaj
Modified: 2019-11-27 13:51 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
Xorg.0.log after the crash (842.45 KB, application/x-xz)
2019-10-17 13:12 UTC, Mikolaj
no flags Details

Description Mikolaj 2019-10-17 13:10:31 UTC
I'm failing random Xorg crashes where I suspect intel_drv.so as the culprit. It happens on the Xorg start or often triggered by GIMP start or open file dialog in GIMP.

My system is Huawei MateBook X with Intel HD Graphics 620 running on OpenBSD:

OpenBSD 6.6-current (GENERIC.MP) #378: Wed Oct 16 23:06:01 MDT 2019
    deraadt@amd64.openbsd.org:/usr/src/sys/arch/amd64/compile/GENERIC.MP

I've compiled commit bff5eca49b27cb47673123222a714d2a6f56287f from https://gitlab.freedesktop.org/xorg/driver/xf86-video-intel.git with --enable-debug=full option and during crash I see following in Xorg.0.log:

...
[   137.310] sna_screen_init
[   137.310] sna_accel_init
[   137.310] sna_picture_init
[   137.310] gen9_render_setup: gt=3
[   137.310] uploaded 41600 bytes of static state
[   137.310] kgem_create_linear(41600)
[   137.310] search_linear_cache: num_pages=11, flags=2, use_active? 0, use_large=0 [max=65536]
[   137.310] search_linear_cache: inactive and cache bucket empty
[   137.310] search_linear_cache: active cache bucket empty
[   137.310] kgem_create_linear: new handle=4, num_pages=11
[   137.310] __kgem_bo_init(handle=4, num_pages=11)
[   137.310] __kgem_bo_map__cpu: failed -22, throttling/cleaning caches
[   137.310] (EE) 
Fatal server error:
[   137.310] (EE) __kgem_bo_map__cpu:697 assertion 'err != -EINVAL || bo->prime' failed
[   137.310] (EE) 
[   137.310] (EE) 
Please consult the The X.Org Foundation support 
         at http://wiki.x.org
 for help. 
[   137.310] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
[   137.310] (EE) 
[   137.311] (EE) Server terminated with error (1). Closing log file.


I have couple of logs like that. I've compressed them with xz(1) however there are max 10MB each.
Comment 1 Mikolaj 2019-10-17 13:12:43 UTC
Created attachment 145765 [details]
Xorg.0.log after the crash

This is one of the log files which I have when Xorg dies. All of them have following line:

...
[   137.129] __kgem_bo_init(handle=23, num_pages=64)
[   137.129] create_snoopable_buffer: created CPU (LLC) handle=23 for buffer, size 64
[   137.129] kgem_bo_map__cpu(handle=23, size=262144, map=0x0:0x0)
[   137.129] kgem_trim_vma_cache: type=1, count=-32764 (bucket: 6)
[   137.129] __kgem_bo_map__cpu: failed -22, throttling/cleaning caches
[   137.129] (EE) 
Fatal server error:
[   137.129] (EE) __kgem_bo_map__cpu:697 assertion 'err != -EINVAL || bo->prime' failed
[   137.129] (EE) 
[   137.129] (EE) 
Please consult the The X.Org Foundation support 
         at http://wiki.x.org
 for help. 
[   137.129] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
Comment 2 Chris Wilson 2019-10-17 13:17:01 UTC
Looks like the BSD kernel driver does not conform to the uABI of i915.ko.
Comment 3 Mikolaj 2019-10-17 18:22:17 UTC
I've also reported this on OpenBSD side:

https://marc.info/?l=openbsd-bugs&m=157131907725600&w=2
Comment 4 Martin Peres 2019-11-27 13:51:21 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/xorg/driver/xf86-video-intel/issues/169.


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.