summaryrefslogtreecommitdiff
path: root/lib/igt_fb.c
diff options
context:
space:
mode:
authorMaarten Lankhorst <maarten.lankhorst@linux.intel.com>2017-02-09 10:42:01 +0100
committerMaarten Lankhorst <maarten.lankhorst@linux.intel.com>2017-02-27 11:17:25 +0100
commitd930b6493d93a6e6c2ca9a5ed468d360a9183586 (patch)
tree353049a57f2544c68f3e771f8bf84fbeedc3e39b /lib/igt_fb.c
parent8f3164ff51b7ceef87ebc285c5ba9874ceee767e (diff)
lib: Add basic support for valgrind annotations.
SIGRTMAX appears to be used by valgrind now for its internal tracking, so avoid it in the helpers. Also add some valgrind annotations in gem_mmap, to make sure that its accesses are tracked correctly. I've also added gem_munmap, but there are a lot of places that don't use it yet in tests/. Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Diffstat (limited to 'lib/igt_fb.c')
-rw-r--r--lib/igt_fb.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/igt_fb.c b/lib/igt_fb.c
index bb87869f..d2b7e9e3 100644
--- a/lib/igt_fb.c
+++ b/lib/igt_fb.c
@@ -237,7 +237,7 @@ static int create_bo_for_fb(int fd, int width, int height, uint32_t format,
/* Ensure the framebuffer is preallocated */
ptr = gem_mmap__gtt(fd, bo, size, PROT_READ);
igt_assert(*ptr == 0);
- munmap(ptr, size);
+ gem_munmap(ptr, size);
if (size_ret)
*size_ret = size;
@@ -988,7 +988,7 @@ static void destroy_cairo_surface__blit(void *arg)
struct igt_fb *fb = blit->fb;
unsigned int obj_tiling = igt_fb_mod_to_tiling(fb->tiling);
- munmap(blit->linear.map, blit->linear.size);
+ gem_munmap(blit->linear.map, blit->linear.size);
fb->cairo_surface = NULL;
gem_set_domain(blit->fd, blit->linear.handle,
@@ -1095,7 +1095,7 @@ static void destroy_cairo_surface__gtt(void *arg)
{
struct igt_fb *fb = arg;
- munmap(cairo_image_surface_get_data(fb->cairo_surface), fb->size);
+ gem_munmap(cairo_image_surface_get_data(fb->cairo_surface), fb->size);
fb->cairo_surface = NULL;
if (fb->is_dumb)