[uxa] assertion failure: drm_intel_gem_bo_purge_vma_cache: bo_gem->map_count == 0
Submitted by Modestas Vainius
Assigned to Chris Wilson @ickle
Description
Hello,
since upgrade to 2.18.0 (from 2.17.0), I have been experiencing random X crashes. I can't tell what exactly triggers X server crash but it always happens pretty soon after KDE startup. I'm using libdrm 2.4.30 though the crash is reproducible with libdrm 2.4.31 as well.
Below you will find a backtrace and lspci output. Nothing interesting gets written to Xorg.0.log. If you need more information, feel free to ask.
P.S. I'm aware that crash is in libdrm. However, 2.17.0 used to work fine with the same libdrm. So I'm not sure where the actual bug is.
(gdb) bt<br>
#0 0x00007f8b75312475 in *__GI_raise (sig=<optimized out>) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64<br>
#1 0x00007f8b753156f0 in *__GI_abort () at abort.c:92<br>
#2 0x00007f8b7530b621 in *__GI___assert_fail (assertion=0x7f8b730d2f61 "bo_gem->map_count == 0", <br>
file=<optimized out>, line=960, function=0x7f8b730d3160 "drm_intel_gem_bo_purge_vma_cache") at assert.c:81<br>
#3 0x00007f8b730ceb6f in drm_intel_gem_bo_purge_vma_cache (bufmgr_gem=0x7f8b785c3310)<br>
at intel_bufmgr_gem.c:960<br>
#4 0x00007f8b730d10d3 in drm_intel_gem_bo_map_gtt (bo=0x7f8b7c93b4e0) at intel_bufmgr_gem.c:1160<br>
#5 0x00007f8b732e79a4 in intel_uxa_pixmap_put_image (pixmap=<optimized out>, <br>
src=0x7f8b7c93d450 '"' <repeats 122 times>, src_pitch=124, x=0, y=<optimized out>, w=122, h=19)<br>
at ../../src/intel_uxa.c:772<br>
#6 0x00007f8b732e96c7 in intel_uxa_put_image (pixmap=0x7f8b7c93d3c0, x=0, y=0, w=<optimized out>, h=19, <br>
src=0x7f8b7c93d450 '"' <repeats 122 times>, src_pitch=124) at ../../src/intel_uxa.c:837<br>
#7 0x00007f8b733108a2 in uxa_picture_from_pixman_image (format=PIXMAN_a8, image=0x7f8b7c938680, <br>
screen=0x7f8b785ca580) at ../../uxa/uxa-render.c:534<br>
#8 uxa_trapezoids (op=3 '\003', src=0x7f8b7a4038d0, dst=0x7f8b7c6d99d0, maskFormat=<optimized out>, <br>
xSrc=1017, ySrc=160, ntrap=<optimized out>, traps=<optimized out>) at ../../uxa/uxa-render.c:2001<br>
#9 0x00007f8b773bbba1 in ProcRenderTrapezoids (client=0x7f8b7c616210) at ../../render/render.c:783<br>
#10 0x00007f8b772fff81 in Dispatch () at ../../dix/dispatch.c:437<br>
#11 0x00007f8b772ef1aa in main (argc=8, argv=<optimized out>, envp=<optimized out>) at ../../dix/main.c:287<br>
(gdb) bt full<br>
#0 0x00007f8b75312475 in *__GI_raise (sig=<optimized out>) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64<br>
pid = <optimized out><br>
selftid = <optimized out><br>
#1 0x00007f8b753156f0 in *__GI_abort () at abort.c:92<br>
act = {__sigaction_handler = {sa_handler = 0x7f8b730d2f61, sa_sigaction = 0x7f8b730d2f61}, sa_mask = {<br>
__val = {140236944484584, 140734302203024, 960, 140734302203264, 140236943548550, 206158430232, <br>
140734302203280, 140734302203056, 140236943447112, 206158430256, 140734302203304, <br>
140237067225312, 263376, 4480357486596943714, 7959390389040865645, 140734302210458}}, <br>
sa_flags = 1967294783, sa_restorer = 0x7f8b730d2f4e}<br>
sigs = {__val = {32, 0 <repeats 15 times>}}<br>
#2 0x00007f8b7530b621 in *__GI___assert_fail (assertion=0x7f8b730d2f61 "bo_gem->map_count == 0", <br>
file=<optimized out>, line=960, function=0x7f8b730d3160 "drm_intel_gem_bo_purge_vma_cache") at assert.c:81<br>
buf = 0x7f8b7c9388e0 "X: intel_bufmgr_gem.c:960: drm_intel_gem_bo_purge_vma_cache: Assertion `bo_gem->map_count == 0' failed.\n"<br>
#3 0x00007f8b730ceb6f in drm_intel_gem_bo_purge_vma_cache (bufmgr_gem=0x7f8b785c3310)<br>
at intel_bufmgr_gem.c:960<br>
bo_gem = 0x7f8b785c38f8<br>
limit = 508<br>
__FUNCTION__ = "drm_intel_gem_bo_purge_vma_cache"<br>
__PRETTY_FUNCTION__ = "drm_intel_gem_bo_purge_vma_cache"<br>
---Type <return> to continue, or q <return> to quit---<br>
#4 0x00007f8b730d10d3 in drm_intel_gem_bo_map_gtt (bo=0x7f8b7c93b4e0) at intel_bufmgr_gem.c:1160<br>
bufmgr_gem = 0x7f8b785c3310<br>
bo_gem = 0x7f8b7c93b4e0<br>
set_domain = {handle = 2019125584, read_domains = 32651, write_domain = 1108815584}<br>
ret = <optimized out><br>
__PRETTY_FUNCTION__ = "drm_intel_gem_bo_map_gtt"<br>
#5 0x00007f8b732e79a4 in intel_uxa_pixmap_put_image (pixmap=<optimized out>, <br>
src=0x7f8b7c93d450 '"' <repeats 122 times>, src_pitch=124, x=0, y=<optimized out>, w=122, h=19)<br>
at ../../src/intel_uxa.c:772<br>
priv = 0x7f8b7c93a560<br>
stride = 128<br>
cpp = <optimized out><br>
ret = 0<br>
#6 0x00007f8b732e96c7 in intel_uxa_put_image (pixmap=0x7f8b7c93d3c0, x=0, y=0, w=<optimized out>, h=19, <br>
src=0x7f8b7c93d450 '"' <repeats 122 times>, src_pitch=124) at ../../src/intel_uxa.c:837<br>
intel = 0x3206<br>
tiling = 1983298042<br>
size = <optimized out><br>
stride = 32651<br>
bo = <optimized out><br>
screen = <optimized out><br>
priv = 0x7f8b7c93a560<br>
---Type <return> to continue, or q <return> to quit---<br>
#7 0x00007f8b733108a2 in uxa_picture_from_pixman_image (format=PIXMAN_a8, image=0x7f8b7c938680, <br>
screen=0x7f8b785ca580) at ../../uxa/uxa-render.c:534<br>
uxa_screen = 0x7f8b732e9420<br>
picture = 0x7f8b7c938100<br>
pixmap = <optimized out><br>
width = 122<br>
height = 19<br>
#8 uxa_trapezoids (op=3 '\003', src=0x7f8b7a4038d0, dst=0x7f8b7c6d99d0, maskFormat=<optimized out>, <br>
xSrc=1017, ySrc=160, ntrap=<optimized out>, traps=<optimized out>) at ../../uxa/uxa-render.c:2001<br>
scratch = 0x0<br>
yDst = 160<br>
xRel = <optimized out><br>
width = 122<br>
height = 19<br>
mask = <optimized out><br>
yRel = <optimized out><br>
xDst = 1017<br>
image = 0x7f8b7c938680<br>
format = PIXMAN_a8<br>
screen = 0x7f8b785ca580<br>
uxa_screen = 0x0<br>
bounds = {x1 = 1017, y1 = 160, x2 = 1139, y2 = 179}<br>
---Type <return> to continue, or q <return> to quit---<br>
direct = <optimized out><br>
#9 0x00007f8b773bbba1 in ProcRenderTrapezoids (client=0x7f8b7c616210) at ../../render/render.c:783<br>
rc = <optimized out><br>
ntraps = <optimized out><br>
pSrc = 0x7f8b7a4038d0<br>
pDst = 0x7f8b7c6d99d0<br>
pFormat = 0x7f8b7a120f28<br>
stuff = 0x7f8b7a375e04<br>
#10 0x00007f8b772fff81 in Dispatch () at ../../dix/dispatch.c:437<br>
clientReady = 0x7f8b7a34b7c0<br>
result = <optimized out><br>
client = 0x7f8b7c616210<br>
nready = 0<br>
icheck = 0x7f8b776b4ad0<br>
start_tick = 400<br>
#11 0x00007f8b772ef1aa in main (argc=8, argv=<optimized out>, envp=<optimized out>) at ../../dix/main.c:287<br>
i = <optimized out><br>
alwaysCheckForInput = {0, 1}<br>
(gdb)<br>
```<br>
<br>
00:02.0 VGA compatible controller: Intel Corporation Core Processor Integrated Graphics Controller (rev 12) (prog-if 00 [VGA controller])<br>
Subsystem: Giga-byte Technology Device d000<br>
Control: I/O+ Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+<br>
Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-<br>
Latency: 0<br>
Interrupt: pin A routed to IRQ 48<br>
Region 0: Memory at fb400000 (64-bit, non-prefetchable) [size=4M]<br>
Region 2: Memory at e0000000 (64-bit, prefetchable) [size=256M]<br>
Region 4: I/O ports at ff00 [size=8]<br>
Expansion ROM at <unassigned> [disabled]<br>
Capabilities: [90] MSI: Enable+ Count=1/1 Maskable- 64bit-<br>
Address: fee0f00c Data: 41a1<br>
Capabilities: [d0] Power Management version 2<br>
Flags: PMEClk- DSI+ D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)<br>
Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-<br>
Capabilities: [a4] PCI Advanced Features<br>
AFCap: TP+ FLR+<br>
AFCtrl: FLR-<br>
AFStatus: TP-<br>
Kernel driver in use: i915