mirror of
https://gitlab.freedesktop.org/mesa/drm.git
synced 2026-05-09 03:58:05 +02:00
While I've closed off most races in a previous patch, a small race still existed where importing then unreffing cound cause an invalid bo. Add a test for this case. Racing sequence fixed: - thread 1 releases bo, refcount drops to zero, blocks on acquiring nvdev->lock. - thread 2 increases refcount to 1. - thread 2 decreases refcount to zero, blocks on acquiring nvdev->lock. At this point the 2 threads will clean up the same bo. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@ubuntu.com> Reviewed-By: Emil Velikov <emil.l.velikov@gmail.com>
16 lines
246 B
Makefile
16 lines
246 B
Makefile
AM_CPPFLAGS = \
|
|
-I$(top_srcdir)/include/drm \
|
|
-I$(top_srcdir)/nouveau \
|
|
-I$(top_srcdir)
|
|
|
|
AM_CFLAGS = $(WARN_CFLAGS)
|
|
|
|
LDADD = \
|
|
../../nouveau/libdrm_nouveau.la \
|
|
../../libdrm.la \
|
|
-ldl -lpthread
|
|
|
|
TESTS = threaded
|
|
|
|
check_PROGRAMS = $(TESTS)
|
|
|