From 91669a47237cfdb3be7d13fd2484f5d92cb6ed84 Mon Sep 17 00:00:00 2001 From: Carl Zhang Date: Fri, 26 Jan 2024 02:07:57 -0500 Subject: [PATCH] va_trace:add return value trace for vaPutSurfaces Signed-off-by: Carl Zhang --- va/meson.build | 3 ++- va/va_trace.h | 1 - va/x11/va_x11.c | 10 ++++++---- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/va/meson.build b/va/meson.build index 372ae89ff..5e969eb83 100644 --- a/va/meson.build +++ b/va/meson.build @@ -151,10 +151,11 @@ if WITH_X11 libva_dri_headers = [ 'x11/va_dri2.h', + 'x11/va_dri3.h', 'x11/va_dricommon.h', ] - libva_x11_headers = ['va_x11.h'] + libva_dri_headers + libva_x11_headers = ['va_x11.h'] + libva_dri_headers + ['va_trace.h'] libva_headers_subproject += libva_dri_headers diff --git a/va/va_trace.h b/va/va_trace.h index 8b0b5a4cd..05637afac 100644 --- a/va/va_trace.h +++ b/va/va_trace.h @@ -475,7 +475,6 @@ void va_TracePutSurface( unsigned int flags /* de-interlacing flags */ ); -DLL_HIDDEN void va_TraceStatus(VADisplay dpy, const char * funcName, VAStatus status); /** \brief va_TraceEvent diff --git a/va/x11/va_x11.c b/va/x11/va_x11.c index 242e6e7c3..cd3bf9ee8 100644 --- a/va/x11/va_x11.c +++ b/va/x11/va_x11.c @@ -171,7 +171,7 @@ VAStatus vaPutSurface( ) { VADriverContextP ctx; - + VAStatus vaStatus = VA_STATUS_SUCCESS; CHECK_DISPLAY(dpy); ctx = CTX(dpy); @@ -179,7 +179,9 @@ VAStatus vaPutSurface( destx, desty, destw, desth, cliprects, number_cliprects, flags); - return ctx->vtable->vaPutSurface(ctx, surface, (void *)draw, srcx, srcy, srcw, srch, - destx, desty, destw, desth, - cliprects, number_cliprects, flags); + vaStatus = ctx->vtable->vaPutSurface(ctx, surface, (void *)draw, srcx, srcy, srcw, srch, + destx, desty, destw, desth, + cliprects, number_cliprects, flags); + VA_TRACE_RET(dpy, vaStatus); + return vaStatus; }